Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » Making a Save / Load System
- SkullZNTH
-
Scratcher
92 posts
Making a Save / Load System
I have absolutely no idea where to start when it comes to saving and loading. Besides it being pretty essential to the type of game I'm making, it would also speed up my development process as I won't need to replay the game whenever I want to reach to a certain point. Btw here's my project: https://scratch.mit.edu/projects/274856081/
- Kismat12
-
Scratcher
100+ posts
Making a Save / Load System
Okay so what you should do is make a complicated code and when some types in the code it would decode the code and if it matches the standards of where the characters is supposed to be then it would put a broadcast to that level, and then the players would be taken to that level!
- Vicream_Creator
-
Scratcher
100+ posts
Making a Save / Load System
Okay so what you should do is make a complicated code and when some types in the code it would decode the code and if it matches the standards of where the characters is supposed to be then it would put a broadcast to that level, and then the players would be taken to that level!…or he use cloud variables
- SkullZNTH
-
Scratcher
92 posts
Making a Save / Load System
Okay so what you should do is make a complicated code and when some types in the code it would decode the code and if it matches the standards of where the characters is supposed to be then it would put a broadcast to that level, and then the players would be taken to that level!I have no idea how to do that.
- SkullZNTH
-
Scratcher
92 posts
Making a Save / Load System
I haven't touched Scratch in 2 years, what are cloud variables exactly?Okay so what you should do is make a complicated code and when some types in the code it would decode the code and if it matches the standards of where the characters is supposed to be then it would put a broadcast to that level, and then the players would be taken to that level!…or he use cloud variables
- JACsterandOlibob
-
Scratcher
1000+ posts
Making a Save / Load System
Variables with a value that's stored, you guessed it, in the cloud. It's usually used for world highscores and the likes.I haven't touched Scratch in 2 years, what are cloud variables exactly?Okay so what you should do is make a complicated code and when some types in the code it would decode the code and if it matches the standards of where the characters is supposed to be then it would put a broadcast to that level, and then the players would be taken to that level!…or he use cloud variables
- JACsterandOlibob
-
Scratcher
1000+ posts
Making a Save / Load System
As Kismat12 said, the best way would be to use encoding and decoding. For example, saving and loading an X and Y coordinate.
When you save it, you'd save first the X coord and then the Y:
(This is a really simple version)
Then loading
When you save it, you'd save first the X coord and then the Y:
(This is a really simple version)
set [SaveX v] to (x position)
set [SaveY v] to (y position)
say [Your X code is (SaveX)] for (2) secs
say [Your Y code is (SaveY)] for (2) secs
Then loading
ask [What is the X value?] and wait
set x to (answer)
ask [What is the Y value?] and wait
set y to (answer)
- SkullZNTH
-
Scratcher
92 posts
Making a Save / Load System
As Kismat12 said, the best way would be to use encoding and decoding. For example, saving and loading an X and Y coordinate.Thanks! (sorry for the late reply) I thought of doing it this way, but because my game will also have items, parterners gadgets, ect. I'll to make a variable of each one of those things. It'll take a lot of time, but I guess this is the best way to do it.
When you save it, you'd save first the X coord and then the Y:
(This is a really simple version)set [SaveX v] to (x position)
set [SaveY v] to (y position)
say [Your X code is (SaveX)] for (2) secs
say [Your Y code is (SaveY)] for (2) secs
Then loadingask [What is the X value?] and wait
set x to (answer)
ask [What is the Y value?] and wait
set y to (answer)
Last edited by SkullZNTH (Dec. 29, 2018 11:52:29)
- sippingcider
-
Scratcher
500+ posts
Making a Save / Load System
Hello, I just finished making a tutorial on this! You can check it out Here
This will show you how to save all your information in one code! Also, there is a sprite you can backpack in the project if you don't want to do all the coding yourself.
This will show you how to save all your information in one code! Also, there is a sprite you can backpack in the project if you don't want to do all the coding yourself.
- SkullZNTH
-
Scratcher
92 posts
Making a Save / Load System
Hello, I just finished making a tutorial on this! You can check it out HereThanks!
This will show you how to save all your information in one code! Also, there is a sprite you can backpack in the project if you don't want to do all the coding yourself.
- YanYanTiger17143
-
Scratcher
13 posts
Making a Save / Load System
Easiest way to make a save and load system in to first make the buttons, (One named Load the other named Save). Then make a list called save. Then make this script in the sprite save:
For the load button make this code:
when this sprite clicked
add (Points) to [Save List]
say (Points) for (2) secs
For the load button make this code:
when this sprite clicked
ask [Code?] and wait
if <[Save] contains (answer) then
set [ Points ] to (answer)
Last edited by YanYanTiger17143 (July 22, 2021 14:03:19)
- bobisonscratch
-
Scratcher
1 post
Making a Save / Load System
my brain had a malfunction when i tried ;-;
- 09878901234321
-
Scratcher
500+ posts
Making a Save / Load System
my brain had a malfunction when i tried ;-;This topic is over a year old! Try to avoid posting on old topics, especially with no new information or questions. It’s called necroposting which is a form of spam.
- Discussion Forums
- » Help with Scripts
-
» Making a Save / Load System
