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

#1 2008-11-22 00:32:06

112digdoggies
Scratcher
Registered: 2008-11-20
Posts: 7

How do I make another script?

Im working on a game for school and I am wondering how I can have more than one script per game? Also, how to make you loose the if my timer hits x ammount of time?

Offline

 

#2 2008-11-22 03:02:21

djm111
Scratcher
Registered: 2008-10-29
Posts: 1000+

Re: How do I make another script?

Just start another one with <when green flag clicked> or when a key is pressed. To get a timer, Make a variable called time left, and put in a script to say that when you start, it is set to a certain amount, like this[blocks]<when green flag clicked><set{ time left }to( 60[/blocks]
Then put in a timer that repeats itself, which waits 1 second then changes the amount of the variable by -1. Then have a script on your stage like this:
WHEN GREEN FLAG CLICKED
FOREVER
IF (TIME LEFT) <(LESS THAN) 1
Now put whatever happens when you lose.
Hope it helps{:>)

Last edited by djm111 (2008-11-22 03:02:58)


http://i627.photobucket.com/albums/tt358/Dazzamcgazza/sig.png

Offline

 

Board footer