This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2009-04-15 10:49:50

Masterdan
Scratcher
Registered: 2009-03-28
Posts: 58

Save buttons

How do you make save buttons? I really need one for my game. Thanks.


http://img145.imageshack.us/img145/7089/puzzleadvert.pnghttp://www.neopets.com/refer.phtml?username=dan_84_dan Click there for fun stuff and to get me free stuff!

Offline

 

#3 2009-04-16 04:59:23

ikuehne
Scratcher
Registered: 2009-04-15
Posts: 15

Re: Save buttons

you could make a lot of variables for positions of different sprites and set them to the real positions of the sprites if you pressed a button (another sprite).
For instance:
[blocks]
<when[ sprite1 ]clicked>
<broadcast[ save
[/blocks]

and for another sprite:

[blocks]
<when I receive[ save
<set{ savex }to( <x position>
<set{ savey }to( <y position>
<end>
[/blocks]

Offline

 

#4 2009-04-16 07:21:24

Masterdan
Scratcher
Registered: 2009-03-28
Posts: 58

Re: Save buttons

Thanks. That will be alot of help  big_smile


http://img145.imageshack.us/img145/7089/puzzleadvert.pnghttp://www.neopets.com/refer.phtml?username=dan_84_dan Click there for fun stuff and to get me free stuff!

Offline

 

#5 2009-04-16 08:39:39

archmage
Scratcher
Registered: 2007-05-18
Posts: 1000+

Re: Save buttons

There is the save button in the scratch program you can use. But online there is no way.


Hi, I am Archmage coder extraordinaire. I do Scratch,pascal,java,php,html, AS2 and AS3. Leave me a message if you want coding advice. Also check out my personal website, lots of good stuff about web development, Flash, and Scratch (v1 and v2) !

Offline

 

#6 2009-04-16 08:52:04

technoguyx
Scratcher
Registered: 2008-10-18
Posts: 1000+

Re: Save buttons

ikuehne wrote:

you could make a lot of variables for positions of different sprites and set them to the real positions of the sprites if you pressed a button (another sprite).
For instance:
[blocks]
<when[ sprite1 ]clicked>
<broadcast[ save
[/blocks]

and for another sprite:

[blocks]
<when I receive[ save
<set{ savex }to( <x position>
<set{ savey }to( <y position>
<end>
[/blocks]

I remember having a old game, which was never published. It used a save system which used lists, each item for a stat (Ex: ScrollX, ScrollY, Health, XP, Color Effect [my game used it for the custom character creation], etc...)


http://getgnulinux.org/links/en/linuxliberated_4_78x116.png

Offline

 

Board footer