• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

script help!

Status
Not open for further replies.
Level 1
Joined
Feb 16, 2005
Messages
4
umm i need help, how can i make a saving thing in my map, i've tried one but it wont let me load the game cache... heres the script so far:
selected
Events
Dialog - A dialog button is clicked for bank_dialog
Conditions
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Clicked dialog button) Equal to yes
Then - Actions
Game Cache - Store ((Triggering player) Current gold) as ((Name of (Triggering player)) + gold) of players_money in playersmoney
Game - Display to (Triggering player), at offset (0.00, 0.00) the text: ((String(((Triggering player) Current gold))) + stored.)
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Clicked dialog button) Equal to no
Then - Actions
Game - Display to (Triggering player), at offset (0.00, 0.00) the text: Alright, see you ar...
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Clicked dialog button) Equal to load
Then - Actions
Game - Display to (Triggering player), at offset (0.00, 0.00) the text: Alright, let me get...
Else - Actions
Do nothing
i dont think it's right though... :?
 
Level 4
Joined
Jan 9, 2005
Messages
106
comon people, 14 reviews and only my post... geez.

anyways, what are the variables you are using? i can see them but i dont know if they are integer, player, boolean, any of them arrays? if so what's the array number?

seeing as you are at least trying this I'm very much so more than willing to assist you in issues you are having with it.

also, are you trying to impliment this into a save code for game startup, or just saving the gold from the player for use later in a game?

check out my profile I'm bout to turn on my YIM and MSNM so feel free to contact me on there if you like, would be easier than playing forum tag.
 
Level 7
Joined
Jul 30, 2004
Messages
451
benjy355 said:
umm i need help, how can i make a saving thing in my map, i've tried one but it wont let me load the game cache... heres the script so far:
selected
Code:
Events
        Dialog - A dialog button is clicked for bank_dialog
    Conditions
    Actions
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Clicked dialog button) Equal to yes
            Then - Actions
                Game Cache - Store ((Triggering player) Current gold) as ((Name of (Triggering player)) + gold) of players_money in playersmoney
                Game - Display to (Triggering player), at offset (0.00, 0.00) the text: ((String(((Triggering player) Current gold))) +  stored.)
            Else - Actions
                Do nothing
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Clicked dialog button) Equal to no
            Then - Actions
                Game - Display to (Triggering player), at offset (0.00, 0.00) the text: Alright, see you ar...
            Else - Actions
                Do nothing
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Clicked dialog button) Equal to load
            Then - Actions
                Game - Display to (Triggering player), at offset (0.00, 0.00) the text: Alright, let me get...
            Else - Actions
                Do nothing
i dont think it's right though... :?


umm, i don't actually see the action where you set the players gold = load gamecache ((Triggering player's name) + gold) from playersmoney
thats kind of an important action for loading

also did you use the trigger to create a gamecache before you do this?

also, are you trying this for multiplayer? it doesn't work for multiplayer
 
Status
Not open for further replies.
Top