public void MouseClick(Point mouseposition) { Point MousePositionOnBoard = mouseposition - Board.Origin; int SelectedColumn = MousePositionOnBoard.X / Board.TileWidth; int SelectedRow = MousePositionOnBoard.Y / Board.TileHeight; if (Board.CurrentState.ValidTile(SelectedRow, SelectedColumn)) { Tile SelectedTile = Board.CurrentState[SelectedRow, SelectedColumn]; PartialTurnTracker.SelectTile(SelectedTile); if (PartialTurnTracker.PartialTurn != null) { PartialTurnTracker = TurnManager.AddPartialTurn(PartialTurnTracker.PartialTurn); } } }
public void Start() { Started = true; PartialTurnTracker = new PartialTurnTracker(WhitePlayer, ClockManager.GetCurrentClock(), Board.CurrentState); }