private void OnCellPressed(string point) { var gamePoint = GamePoint.Parse(point); Move(gamePoint); var winnerLine = _game.WinnerLine(); if (winnerLine != null && winnerLine.Length > 0) { foreach (GameLinePoint linePoint in winnerLine) { GetCell(linePoint.Point).IsWinner = true; } var winner = winnerLine[0].MoveType; _dialogService.Show(string.Format("{0} WIN!", winner)); _gameOver = true; } }
private bool OnCanCellPressed(string point) { var gamePoint = GamePoint.Parse(point); return(!_gameOver && _game.CanMove(gamePoint)); }