Esempio n. 1
0
 public PlayerAI(AI gameAI)
 {
     this.GameAI = gameAI;
     Rectangle runRoom = new Rectangle(new Point(1, 1), new Size(GameAI.FieldCell.GetLength(0) - 3, GameAI.FieldCell.GetLength(1) - 3));
     LeftSideRunRoom = runRoom;
     RightSideRunRoom = runRoom;
     DistanceToEnemy = 3;
 }
Esempio n. 2
0
        public GameEventHandler(Game game)
        {
            currentGame = game;
            gameAI = currentGame.GameAI;
            currentGame.CurrentAction = game.CurrentAction;
            lastPlayersInOffside = new List<Player>();

            columns = currentGame.FieldCell.GetLength(0);
            rows = currentGame.FieldCell.GetLength(1);
        }
Esempio n. 3
0
 /* Saves AllPlayers and FieldCell. */
 public static void SetData(AI gameAI, Player[] allPlayers, Rectangle[,] fieldCell)
 {
     AllPlayers = allPlayers;
     FieldCell = fieldCell;
     GameAI = gameAI;
 }