swe_suffer
New Member
- Reaction score
- 20
... Just take a look. Can any1 see whats wrong? ...
And this:
The problem is when you load you dont get a hero... and yes:
I hope is isnt "name of triggering player"...
It makes me MAD!
Code:
save
Events
Player - Player 1 (Red) types a chat message containing -save as A substring
Conditions
Actions
For each (Integer A) from 1 to 8, do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Triggering player) Equal to (Player((Integer A)))
Then - Actions
Game Cache - Store Hero[(Integer A)] as (Substring((Entered chat string), 7, 8)) of (Name of (Triggering player)) in Save_game_cache
Set current_gold[(Integer A)] = ((Player((Integer A))) Current gold)
Game Cache - Store current_gold[(Integer A)] as ((Substring((Entered chat string), 7, 8)) + GOLD) of (Name of (Triggering player)) in Save_game_cache
Game Cache - Save Save_game_cache
Game - Display to (Player group((Player((Integer A))))) for 20.00 seconds the text: (|cff00FF00Game Saved!|r + (Hero (Level |cffFFFF00 + ((String((Level of Hero[(Integer A)]))) + (|r) + ( and + ((String(current_gold[(Integer A)])) + (was saved in slot: |cffFFFF00 + ((Substring((Entered chat string), 7, 8)) + |r. Please take a print scree
Else - Actions
Do nothing
And this:
Code:
load
Events
Player - Player 1 (Red) types a chat message containing -load as A substring
Conditions
Actions
For each (Integer A) from 1 to 8, do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
hassaved[(Integer A)] Equal to 0
(Triggering player) Equal to (Player((Integer A)))
Then - Actions
Game Cache - Restore (Substring((Matched chat string), 7, 8)) of (Name of (Triggering player)) from Save_game_cache for (Player((Integer A))) at (Center of Check Race <gen>) facing 0.00
Set current_gold[(Integer A)] = (Load ((Substring((Entered chat string), 7, 8)) + GOLD) of (Name of (Triggering player)) from Save_game_cache)
Player - Set (Player((Integer A))) Current gold to current_gold[(Integer A)]
Game - Display to (Player group((Player((Integer A))))) for 10.00 seconds the text: (|cff00FF00Hero Loaded!|r A level |cffFFFF00 + ((String((Hero level of (Last restored unit)))) + (|r together with |cffFFFF00 + ((String(current_gold[(Integer A)])) + |r gold!))))
Set hassaved[(Integer A)] = 1
Else - Actions
Game - Display to (Player group((Player((Integer A))))) for 5.00 seconds the text: |cffFF0000ALREADY L...
The problem is when you load you dont get a hero... and yes:
Code:
Game Cache - Create a game cache from THE_NAME_OF_THE_CACHE.w3v
I hope is isnt "name of triggering player"...
It makes me MAD!