Can scratch save your progress so next time you play/view it, your info is where it is? If yes, can it work anywhere, or you have to download it? Also, if yes, how can you make scratch save?
Offline
You'll need to have a password system in you game.. heres a tutorial http://scratch.mit.edu/projects/Dave911/18421
Offline
techy wrote:
You'll need to have a password system in you game.. heres a tutorial http://scratch.mit.edu/projects/Dave911/18421
Even though thats not ACTUALLY saving, its the closest you can get =P
Offline
It's a good way, but people can change the code by downloading to find out the pattern and then they will cheat on the game.
Offline
thegamemaker5000 wrote:
It's a good way, but people can change the code by downloading to find out the pattern and then they will cheat on the game.
But you can also make it very confusing adding all sorts of functions such as
(( <+> (( <-> (( </> )))) ))
which can make it a good deal harder to figure out.
You could also have someone save it upon download, so that the variables that were recorded are also saved.
Offline
Sorry, I'm afraid it can't manipulate the file system.
Offline
shadow_7283 wrote:
You could also have someone save it upon download, so that the variables that were recorded are also saved.
How can I do that?
Offline
thegamemaker5000 wrote:
shadow_7283 wrote:
You could also have someone save it upon download, so that the variables that were recorded are also saved.
How can I do that?
If variables have all the information stored (ex. 100 coins) then someone would have to just save it to their computer, and start up the program again (it won't work online) then the information would be loaded because the variables wouldn't have been set to 0.
Offline
shadow_7283 wrote:
If variables have all the information stored (ex. 100 coins) then someone would have to just save it to their computer, and start up the program again (it won't work online) then the information would be loaded because the variables wouldn't have been set to 0.
But then I need to destroy all the reset scripts and then it will be harder and slower to make projects because I have to reset the variables every time manually.
Offline
thegamemaker5000 wrote:
shadow_7283 wrote:
If variables have all the information stored (ex. 100 coins) then someone would have to just save it to their computer, and start up the program again (it won't work online) then the information would be loaded because the variables wouldn't have been set to 0.
But then I need to destroy all the reset scripts and then it will be harder and slower to make projects because I have to reset the variables every time manually.
This might work...
make another variable (called something like coinsSaved) and while you're playing the game, it always sets coinsSaved to the coins variable, but ONLY while you're playing the game. So when you reset it, it gives you an option to start a new game or continue your current game. Then it still resets the coins variable when you press the green flag but coinsSaved is still the same, and if you restart the game it resets coinsSaved and coins, and if you continue it sets coins to coinsSaved. See if that works, I've never tried it.
Offline
hmnwilson wrote:
This might work...
make another variable (called something like coinsSaved) and while you're playing the game, it always sets coinsSaved to the coins variable, but ONLY while you're playing the game. So when you reset it, it gives you an option to start a new game or continue your current game. Then it still resets the coins variable when you press the green flag but coinsSaved is still the same, and if you restart the game it resets coinsSaved and coins, and if you continue it sets coins to coinsSaved. See if that works, I've never tried it.
But how can make it so that the save variables are the same as the main variables?
Offline
Save the game's data to a list, and if you're playing offline, you can export the list (right-click on the list, then "Export", on Windows), and then import it.
Offline
thegamemaker5000 wrote:
hmnwilson wrote:
This might work...
make another variable (called something like coinsSaved) and while you're playing the game, it always sets coinsSaved to the coins variable, but ONLY while you're playing the game. So when you reset it, it gives you an option to start a new game or continue your current game. Then it still resets the coins variable when you press the green flag but coinsSaved is still the same, and if you restart the game it resets coinsSaved and coins, and if you continue it sets coins to coinsSaved. See if that works, I've never tried it.But how can make it so that the save variables are the same as the main variables?
When you start a new game:
<when I receive[ new game
<forever>
<set{ coinsSaved }to( <{ coins }>
<end>
[/blocks]
But if you choose to continue (note that this will delete the saved game once you load it):
[blocks]<when I receive[ continue
<set{ coins }to( <{ coinsSaved }>
<forever>
<set{ coinsSaved }to( <{ coins }>
<end>
[/blocks](you can use variables to make this into one script to save space)
But you're probably better off using the method technoguyx described because it holds more.
Offline
Just to remind you, there is no way to save data to projects to your hard drive. If you refresh the project page in your browser there is no way that you can use data and make it reappear.
Offline
archmage wrote:
Just to remind you, there is no way to save data to projects to your hard drive. If you refresh the project page in your browser there is no way that you can use data and make it reappear.
I think we're talking about when you play the project offline, but yeah, you can't make it work online without using passwords.
Offline
technoguyx wrote:
Save the game's data to a list, and if you're playing offline, you can export the list (right-click on the list, then "Export", on Windows), and then import it.
But then, the load/save thing will be a press a button to save/load. How can I make it so it can read and render the info to the variables?
Offline
thegamemaker5000 wrote:
technoguyx wrote:
Save the game's data to a list, and if you're playing offline, you can export the list (right-click on the list, then "Export", on Windows), and then import it.
But then, the load/save thing will be a press a button to save/load. How can I make it so it can read and render the info to the variables?
I don't think that you can. You can use the:
-Save/ Open button
-Import/ Export button
-And you can always have the program have a system for codes (your code is F46 the program might read that as fighting points = 46)
But other then these Scratch doesn't have a way for direct saving and loading.
Offline