コード例 #1
0
 // Use this for initialization
 void Start()
 {
     int turnNumber = 0;
     GameState state = Grid.gameState; //hopefull gamestate and turnMangager initialize in the right order.
     //factions = state.factions;
     //factions[0] = new PlayerFaction(); //TODO make the factions not be initialized by the GameState class
     //sfactions[1] = new AIFaction();
     active = factions[0];
     player = (PlayerFaction)factions[0];
 }
コード例 #2
0
ファイル: GameState.cs プロジェクト: urgamedev/TurnBasedGame
 // Use this for initialization
 void Start()
 {
     currentAction = Grid.controller.currentAction;
     map = Grid.map;
     factions = new Faction[NUMFACTIONS];
     factions[0] = new PlayerFaction();
     factions[1] = new AIFaction();
     TurnManager manager = Grid.turnManager;
     manager.factions = factions;
     manager.active = factions[0];
 }