Esempio n. 1
0
 /// <summary>
 /// Constructor for the player manager. Creates all four engine players.
 /// </summary>
 /// <param name="engine"></param>
 public PlayerManager(GameEngine engine)
     : base(engine)
 {
     players = new GamePlayer[4];
     players[0] = new GamePlayer(PlayerIndex.One);
     players[1] = new GamePlayer(PlayerIndex.Two);
     players[2] = new GamePlayer(PlayerIndex.Three);
     players[3] = new GamePlayer(PlayerIndex.Four);
 }
Esempio n. 2
0
 /// <summary>
 /// Sets the current player to the engine player described by the index provided.
 /// </summary>
 /// <param name="index">The player index to become the current player.</param>
 public void SetCurrent(PlayerIndex index)
 {
     currentPlayer = Get(index);
 }