Page 87 - Touchpad_Plus_V3.2_Class4
P. 87

Step 5  Next click on Control blocks category                .
                                                   repeat  10
                 Step 6  Click and drag the                     block to the script area. Snap it to the script.


                 Step 7  Click on Looks blocks category                 .

                 Step 8  Click and drag the  hide  block to the script area and snap it inside the
                           repeat block.


                 Step 9  Click and drag the            pen down  block to the script area and snap it to the
                           script.
                 Step 10    Click on the block         set pen color to   and drag it to the script area. Snap it

                            to the script. Click on the colour dot and choose a colour of your choice.
                 Step 11  Now we will have to click on Motion blocks category                    .

                 Step 12   Next drag the  move       10 steps  and  turn     15  degrees  blocks and snap them
                            inside the repeat block. When you position any block inside the repeat

                            block, it expands to fit the blocks. Change the steps from 10 to 100 mention
                            to change the degree from 15 to 90.
                 Step 13   In the repeat block, click and change the number of repeats from 10 to 4.
                            Why are we doing this? We know that a square has 4 sides.

                 Step 14   If you do not want the sprite to appear over the figure, you can end the
                            code here. But if you want to see both the shape and the sprite, snap the
                             show  block at the end of the code.





























                                   What if you could code your own superpower in Scratch? What would your
                                   superpower be, and how would you use it to help others?






                                                                                       Programming in Scratch        85
   82   83   84   85   86   87   88   89   90   91   92