Session 5 of 5 · 60 minutes
Game Design: Cave Surfing
Finish with an action game: obstacles, lives and a game over. Then test it, improve it and show it.
Goals
By the end of this session you can:
- Build the parts of an action game: a player, obstacles and a score
- Use lives and game over to end a game
- Test a game, find a problem and fix it
- Remix the Cave Surfing Game or the Launcher Game and make it your own
Words to know
- obstacle
- Something the player must avoid, like a rock in a cave.
- lives
- A variable that counts how many chances the player has left.
- playtest
- Playing your own game, and letting others play it, to find problems.
The lesson
Step 1: Cave Surfing Game
Today’s main project is Game Design - Cave Surfing Game. Open the starter, play it, and use See inside to look at how the player and the obstacles work.
- Cave Surfing Game: Starter project
Step 2: The parts of an action game
Look inside the game and find each of these:
- A player sprite that you control.
- Obstacles that move toward the player.
- A variable for the score or the lives.
- A script that decides when the game is over.
Step 3: Lives and game over
A lives variable counts the player’s chances. When the player touches an obstacle, change lives by -1. A second check, if lives = 0 then stop all, ends the game.
Step 4: Test and improve
Professional game designers playtest. Play your own game, then ask someone else to play without any help from you. Watch where they get stuck. Fix one thing at a time and test again.
Step 5: Project to remix
If your class finishes the main project early, try this one.
- Game Design - Launcher Game: Starter project
Exercise
Lives and game over
- Make a variable called
livesand use set lives to 3 under when green flag clicked. - On an obstacle sprite: forever, then if touching Player then, change lives by -1, and go to its start position.
- Add a second if inside the loop: if lives = 0 then, stop all.
- Play it. Do you lose after three hits? Change 3 to a different number and try again.
Need a hint?
The = block is in Operators. Drag the lives variable into its left side and type 0 on the right.
Small project
My finished game
Remix the Cave Surfing Game and make it yours. Then playtest it and improve it before you show it.
- Open Cave Surfing Game and click Remix.
- Play it once. Find the player, the obstacles and how the game ends.
- Change the look and feel: new sprites, backdrops and colors.
- Change one rule: how fast things move, how many lives you have, or how points are scored.
- Playtest: ask a classmate to play without your help, and write down one thing that confused them.
- Fix that one thing, and show your finished game.
Stretch it: Remix the Launcher Game instead, or add a second level.
Quiz
Check your understanding
Pick one answer for each question. Your score appears right in the page; nothing is sent anywhere.
Feedback on this lesson
Teachers and students: tell us what worked and what didn't. We read this to improve the curriculum.
Received
Thank you for the feedback.
The Education team reviews lesson feedback to improve the curriculum.
Preview mode: this form is not connected to a destination yet, so nothing was sent. Set its web address in src/data/config.json.