Discuss Scratch

LacyGirls
New Scratcher
3 posts

Tennis Trouble

Hi!

We're new to Scratch, and having a little trouble with our first project, which is a tennis game. It is still a work in progress, but we can't stop the game once the time limit has finished. Instead of the stage switching at zero, our timer variable continues on to minus numbers and the game keeps going. Any ideas? We've tried scripting next background and blocks to select the background we want, but to no avail.

Thanks,
LacyGirls
andre_rifaut
Scratcher
100+ posts

Tennis Trouble

There is a “stop” block. You can stop everything, with stop all
You can stop some script by testing if the end_of_game is “on” and then use “stop this script”.
JEMA2311
Scratcher
65 posts

Tennis Trouble

Also, the timer variable, you should try to stop it by using something like this:

if <(timer < 0)> then
set timer to 0
broadcast (stop)

or something like that, so your players can stop with “stop this script”. And even start a new round/set/whatever

Last edited by JEMA2311 (May 13, 2013 19:15:21)

LacyGirls
New Scratcher
3 posts

Tennis Trouble

Thanks Guys!

We think we've just figured it out…

LacyGirls
Duchisan
Scratcher
52 posts

Tennis Trouble

This is getting old…

Last edited by Duchisan (March 15, 2021 18:38:10)

Nezon
Scratcher
1000+ posts

Tennis Trouble

Duchisan wrote:

This is getting old…
Which is why you request them to be closed and not post on them, please.

Necropost

Last edited by Nezon (March 15, 2021 19:09:33)

Powered by DjangoBB