Page 79 - iPlus_Ver_2.0_class_5
P. 79

Let’s program your sprites with some code.


                 Click on the block in the Script area  to see your  sprite, move 50 pixels to the right
                 (towards the face of the sprite).


                 More Motion




                                                        1  Drag and drop the “turn 15 degrees”
                                                        block to the previous block of code when you
                                                        see a grey bar between the 2 blocks of code.



































                                          2  Click on the    to play the
                                         animation and see your sprite move.




                 Events Blocks

                 They are colour-coded yellow and are used to sense events,

                 which run the scripts. The first block present in control is the
                 “when flag clicked” block.

                 Drag the “when flag clicked” block out and snap it on top

                 of the blocks you already have in your script. Now, instead of
                 having to double click on your block of code, you can just click
                 on the flag icon to play your animation.





                                                                                                                  77
                                                                          An Introduction to Scratch Programming
   74   75   76   77   78   79   80   81   82   83   84