Discuss Scratch
- Discussion Forums
- » Questions about Scratch
- » Question about stopping scripts
- learnegy
-
100+ posts
Question about stopping scripts
I'm looking for a way to stop a say block that has been set to a fixed duration. For example, if one Sprite is instructed to say “blah blah blah ……..” for 10 seconds, but the user initiates a key press after about 5 seconds that switches to another scene; if that sprite is still visible on the next scene, it continues the say block.
Since the say block is located in a different sprite would I need to setup additional broadcast, listeners to stop the scripts? The keyboard event scripts are currently located in the stage.
Thank you for any assistance.
Since the say block is located in a different sprite would I need to setup additional broadcast, listeners to stop the scripts? The keyboard event scripts are currently located in the stage.
Thank you for any assistance.
Last edited by learnegy (Dec. 20, 2012 10:59:01)
- LS97
-
100+ posts
Question about stopping scripts
Use
say (blah)
wait (10)
say ()
instead of say (blah) for (10)
and then you can use say () whenever you want to stop it before 10 secs.
say (blah)
wait (10)
say ()
instead of say (blah) for (10)
and then you can use say () whenever you want to stop it before 10 secs.
Last edited by LS97 (Dec. 20, 2012 12:20:17)
- Discussion Forums
- » Questions about Scratch
-
» Question about stopping scripts