Page 91 - 2501_KVS_C-3
P. 91

Step 2:  Choose a background from “Choose a Backdrop icon”, e.g. “Underwater 2”
                               from the “Underwater” tab in the “Choose background” window. (Shown in

                               Fig. 9.1)

































                                             Fig. 9.1: A glimpse of Fish floating in water.
                   Step 3:  Click on the “Events” block and drag “when flag clicked” block into the
                               script area.

                   Step 4:  From “Looks” block choose “switch costume to…” block in the script
                               area  and  select  the  value  “fish-c”.  (You  can  choose  any  other  fish

                               costume of your choice.)
                   Step 5:  From the “Control” block choose “forever” block in the script area, to
                               repeat the fish’s floating action continuously (i.e., forever).

                   Step 6:  From the “Motion” block, choose “glide... secs to random position” block
                               in the script area. Change the value 1

                               to any other number (e.g., 10) to make
                               the  fish  float  slowly  and  naturally  in
                               the water to a random position. Also,
                               there is no need to wait now, as  we

                               don’t need to stop fish now.
                   Step 7:  When  we  click  on  the  flag  now,  fish

                               will  floats  continuously  or  forever  in
                               water. (See the code in Fig. 9.2).                             Fig. 9.2





                                                                                    Scratch-4                       89
   86   87   88   89   90   91   92   93   94   95   96