Scott The PolterGeist


Scott the poltergeist was a video game project in just 6 weeks! This project was in teams of three and my main responsibilities was programming and game/level design.

Game description:

You play as a ghost named Scott whose job is to protect intruders from stealing his treasures that are spread around the mansion. Use the environment to fill up the intruders fear meter to scare them out! There are three type of props: Light, Sound and movement(Intruders faint if they see you possess a prop). Intruders have specific phobias that you can relate depending on their hat color. Use that to your advantage to survive as many nights possible and get the highest score possible.







Programming AI Logic:

Programming AI was a challenge for me since this was actually the first time coding a complex AI. All intruders in this game follow the same logic which is as follow:

  1. Pick a random room from the possible destination list(All rooms at the beginning)
  2. Once entered any room, the AI goes into the clearing state
  3. The AI moves to every clearing point in the room that is set by the level designer
  4. Once an AI reaches a clearing point he looks in the rotation of the point set and pauses there for a bit, to give the illusion that they are searching the room
  5. If treasure was found at the clearing point then the AI will steal it
  6. Once all points are cleared, the room is removed from the possible destination list
  7. Repeat step 1

Of course the point of the game is to scare the intruders away, so as a ghost you will be interrupting the AI logic above. The following are the AI reactions to different interruptions:

  1. Light: AI looks at the light that has been turned off for a while, trying to look at who turned off the lights
  2. Sound: AI gets scared of sound running away from the opposite direction of the sound source
  3. Movement: AI gets scared and faints to the ground for a duration of time

After interruption the AI returns to his normal routine.