public void ActiveState(string name) { for(int i = 0; i < maxStates; i++) { if (names[i] == name) activeState = states[i]; } }
public GameStateManager(Tortoise2d game, int max) { maxStates = max; states = new GameState[max]; names = new string[max]; dummyState = new GameState(game, this); this.game = game; }
public void AddState(string name, GameState state) { names[count] = name; states[count] = state; count++; }