Page 117 - KEC Khaitan C4 Flipbook
P. 117

To create and use variables, follow the given steps:

                 Step  1   Create a Score variable.
                 Step  2   To increase score use                          block.


                 Step  3   Create a Level variable to track progress.






















                 Step  4   To change level use                         block after a certain score is reached.



                           ADDING INCREASING DIFFICULTY WITH LEVELS

                 Games become more exciting when the difficulty increases as the player progresses. This

                 can be done by speeding up enemies, adding  obstacles, or making tasks harder in
                 higher levels.

                 To increase difficulty with levels, follow the given steps:

                 Step  1   Use                        block to adjust speed as the levels increase.


                 Step  2   Add more obstacles by introduce new challenges as higher levels.

                 Step  3   Use a          block to make levels more challenging by giving players less time to
                           complete tasks.

                 Step  4   Play the game multiple times to check if the difficulty increases smoothly.



                        REVISIT



                      Every game has different stages: Starting, Playing and Ending.
                      The start stage is the first screen that appears when the game begins.
                      The play stage is where the actual game happens.
                      The end stage appears when the game is over, either when the player wins or loses.
                      A variable stores information.





                                                                              Creating an Advanced Game in Scratch  115
   112   113   114   115   116   117   118   119   120   121   122