Page 92 - TrackpadV1.0_C2_Flipbook
P. 92

Drawing A Square

                  Create the given Script and observe the sprite moving and turning only four times to draw
                  a square.




                                 when  clicked
                                      pen down
                                 repeat  4
                                   move 100   steps
                                   turn   90  degrees





                  Drawing A Circle

                  To draw a circle, create the given script in Scratch.


                                      when  clicked
                                          pen down
                                          set to pen size 5
                                      repeat 360
                                       move 1  steps
                                       turn   1  degrees
                                           Change pen color  by  5







                                                                                                        PURE
                        In Scratch, each number is equal to 1 step  of the sprite on the stage. In the
                        turn block, change the degree from 15 to 90.                                     FACT




                  FOREVER BLOCK

                  Forever block is used to make the sprite do something infinitely (nonstop) until a command
                  is passed over it by the user. To use the Forever block, replace the repeat block with a forever
                  block. Create the following Script and Run to watch your Sprite go round and round!


                         when    clicked
                               pen down
                                                                         Subject: Deleting a block
                          forever
                            move 100      steps                         We can delete any block from the script
                                                                        by right-clicking on it and choosing the
                            turn     90  degrees                        Delete  Block  option  from the  context
                                                                        menu.





                   90   Trackpad (Version 1.0)-IV
   87   88   89   90   91   92   93   94   95   96   97