Пример #1
0
        public PlayerBoard(PlayerPosition playerPosition, Color playerColor, MovesArrayAllocator arrayAllocator)
        {
            this.position  = playerPosition;
            this.color     = playerColor;
            this.allocator = arrayAllocator;

            this.ResetAll();
        }
Пример #2
0
        public GameProvider(MovesArrayAllocator arrayAllocator)
        {
            this.allocator    = arrayAllocator;
            this.PlayerBoard1 = new PlayerBoard(PlayerPosition.Down, Color.White, arrayAllocator);
            this.PlayerBoard2 = new PlayerBoard(PlayerPosition.Up, Color.Black, arrayAllocator);

            this.History = new MovesHistory();

            this.playerBoards = new PlayerBoard[2];
            this.playerBoards[(int)Color.White] = this.PlayerBoard1;
            this.playerBoards[(int)Color.Black] = this.PlayerBoard2;
        }