Game Development Reference
In-Depth Information
5. Set up the staring posiion using the go to x: () y: () and point in direcion () blocks.
6. The x value will be 240 , the right edge of the stage. The y value will be a random
value between -180 and 180 , the full y range of the stage.
7. The basic direcion of the sprite will be to the let or -90 . We will modify that
value with a random range. The direcion may deviate 30 degrees both ways.
So we replace the ixed direcion using the pick random () to () block; enter the
values -60 and -120 respecively.
8. We also need to change the sprites rotaion style to let to right (the bi-direcional
arrow) in the sprite Properies panel. This makes sure the starish isn't swimming
upside down.
9. Next, repeat the creaion of the clone ive imes by entering the value 5 in the
repeat() block.
10. We will obviously include a create clone of <myself> block.
11. We will enter the value 0.2 in the wait () secs block and wait between each
cloning process to put some space between the clones.
12. Ater the cloning process, wait for a random ime between 1 and 3 seconds by
entering the value 1 and 3 in the wait pick random () to () secs block respecively.
13. Put all steps of the cloning process inside the forever loop to make it run endlessly.
The following screenshot shows the final script:
Search WWH ::

Custom Search