GIGA-uwindsor/Spider-Fish.js — Issue #13: Develop a Stage Class
Author: Salbris
Created: 2011-12-01 21:17:34+00:00
State: open

A stage is a level of the game, the player completes it and transitions to another. Each stage contains:

* a list of spawns that begin at a time relative to the start of the stage. So a start time of 2 is 2 seconds from the start of the stage.
* a number of secs the stage lasts for. After that point it ends and either
* a) goes to the next stage
* b) ends the game

* the next stage that it transitions to when it's finished
* if null then it's the end of the game

Keep in mind that this will need to be set by being read in from a file not in the code so it does not need to be a "kind and convenient" class to work with in code. For example, the constructor can take a dictionary/array of spawns.

I'd also recommend splitting the Stage logic into a data carrying class and the game class. So one that stores the number of spawns and can be incrementally built, and then the stage for the game that figures out how to spawn things and when to transition.