10 Planning the Game

Table of Contents

  1. Introduction
  2. Initializing Allegro
  3. Keyboard Input
  4. Drawing Graphics
  5. Playing Sound
  6. Drawing Text
  7. Regulating FPS
  8. Enumerations and Random Numbers
  9. Bounding Box Collision Detection
  10. Planning the Game
  11. Super Basic Game Structure
  12. Wrapping up


Download entire guide as ODT


Part 10 – Planning the Game

Now you know the basic building blocks of writing the game.

Even though this game is going to be very basic, it’s good to get into the habit of planning various elements of the game, from general ideas you want to keep in mind, what graphics you’ll need, and how you want to structure it. I like to write design documents with google docs because I can access them anywhere, too. Google docs are also share-able, so that multiple people can work on a design doc together.

Also keep in mind that your game doesn’t have to be Pickin’ Sticks. This game just has a character collecting objects. Your game can have a cat collecting fish, or a peanut butter sandwich collecting shoe stores. It’s up to you!

Sample Pickin’ Sticks Design Document

Pickin’ Sticks

(Or whatever you want to call it)

Design Document

[Table of Contents]

General ideas for features and goals
(Sort of a brain-storming section that you flesh out later on)

  • A basic graphical game with collision detection
  • After you pick up certain amounts of sticks, you ”rank up”

Story Elements
Game Setting

  • The game is set in a grassy field. Maybe after the grass is implemented, a fence perimeter will be added, and after that the back of a house, so that you feel like you’re in somebody’s backyard picking up sticks.

Game Characters

  • Your character name


  • Grass backgroudn – either tiled grass or one big image
  • Main character
    • Left, Right, Up, Down directions, each with 3 frames of animation.
  • A stick
  • Title screen

Sound Effects

  • Noise when stick is picked up
  • Walking noise when character is moved
  • ”Thud” noise when player tries to walk off the side of the screen


  • Title screen song
  • Gameplay song

Coding Specifics
Game Objects

  • Rectangle class
  • Player class
    • Holds (x, y) coordinates and width and height dimensions
    • Holds direction the player is facing
    • Holds frame of animation it’s currently on
    • Has a Rectangle Object for collision region
    • Has a Points integer to store player’s score
    • Has IncrementScore() function, and appropriate get-set functions
    • A Rank() function that will return a string of what the player’s current rank is based on points / amount of sticks picked up
  • Stick class
    • Holds (x, y) coordinates and width and height dimensions
    • Has a function to randomly generate coordinates
    • Has a Rectangle Object for the collision region
  • System class
    • Handles Allegro initialization, fullscreen toggle, and game state
  • ImageManager class (optional)
    • Holds all of the images in the game. Instead of keeping them in main and passing them to different functions, we will pass the instance of imageManager instead
  • SoundManager class (optional)
    • Similar to ImageManager

Al Lowe, creator of Leisure Suit Larry, Torin’s Passage and Freddy Pharkas also has his old design docs for those games on his website (www.allowe.com). You may check them out for ideas and inspiration.

© Rachel J. Morris, 2009

Print Friendly