private async void frmTicTacToe_Click(object sender, EventArgs e) { if (!_gameStated) { MessageBox.Show("Plese wait for other player to join", "TicTacToe", MessageBoxButtons.OK, MessageBoxIcon.Information); return; } if (_isYourTurn) { MouseEventArgs eargs = e as MouseEventArgs; Point clickedPoint = new Point(eargs.X, eargs.Y); if (!HasValueInCell(clickedPoint)) { MoveMetadata moveMetadata = new MoveMetadata(PlayerChoice.Value, GetCellNumber(clickedPoint)); await ActorProxy.Move(moveMetadata); } else { MessageBox.Show("Click on a blank region.", "TicTacToe", MessageBoxButtons.OK, MessageBoxIcon.Information); } } else { MessageBox.Show("Not your turn.", "TicTacToe", MessageBoxButtons.OK, MessageBoxIcon.Information); } }