Basic HTML Version

|  | Table of Contents |  | View Full Version

Page 158 - 2615_KEC
P. 158

    Example:

                         When player car touches enemy car, restart.
                         If player  car successfully moves  forward,

                        increase score.

                      IMPLEMENTING DYNAMIC GAME PROGRESSION

                      A racing game becomes more engaging when it has increasing difficulty and score tracking.

                      Increasing Difficulty

                      The diffuclty  of the gamecan be increased by:

                          Increase the speed of enemy cars over time.

                      As the score increases, enemy cars will move faster. We use an If condition to check if
                      the score reaches a certain value and then increase speed.

                          Introduce new obstacles at higher levels.
                      When the player reaches a score milestone, a new obstacle appears on the track.  The
                      obstacle moves downward, like enemy cars, to make the game harder.

                      Scoring System
                      We can use scoring system to make game more engaging by:

                          Award points for successfully dodging obstacles.

                      The player moves forward (upward) to avoid obstacles. If the player reaches the top,
                      they get +1 point. The player's car resets to the bottom for the next round.

                          Display the score on the screen.

                      When the score increases, update the text label on the screen. The text label always
                      displays the current score.

                             REVISIT

                           ▶ Sprite Lab is a great tool in Code.org for creating games using sprites, animations and
                           interactions.
                           ▶ Sprite Lab offers tools to create and manipulate sprites, detect collisions and implement
                           game logic easily.
                           ▶ Event handling enables the game to respond to player inputs.

                           ▶ Collision detection is essential to check if the player’s car crashes into an obstacle.
                           ▶ A racing game becomes more engaging when it has increasing difficulty and score tracking.

                      156   Premium Edition-V

| 153 154 155 156 157 158 159 160 161 162 163 |