public void Input(LilyAcolasia.GameRound round, LilyAcolasia.GameInput input) { if (this.user != null && round.Current.Turn == 1) { this.user.send(input.ToString()); } }
public void CmdEnd(LilyAcolasia.GameRound round) { if (round.Current.Status == LilyAcolasia.GameStatus.Status.WaitSpecialInput) { } IsCmdSuccess = true; this.master.UpdateStatus(); }
public void RoundEnd(LilyAcolasia.GameRound round) { Debug.Log(round.Current.ToString()); int winner = round.Current.Winner; string mesage; if (winner == 2) { mesage = "Round" + round.Round + " Even."; } else { mesage = "Round" + round.Round + " " + round.Current.Players[winner].Name + " won!"; } Debug.Log(mesage); this.master.UpdateStatus(); }
public void CmdError(LilyAcolasia.GameRound round, LilyAcolasia.GameException ex) { IsCmdSuccess = false; Debug.Log("Error: " + ErrorMessages[ex.Type]); this.master.UpdateStatus(); }
public void TurnEnd(LilyAcolasia.GameRound round) { Debug.Log("============ Turn End ============"); this.master.UpdateStatus(); }
public void GameEnd(LilyAcolasia.GameRound round) { Debug.Log("Result: " + round.Point1 + ":" + round.Point2); this.master.UpdateStatus(); }
public void GameStart(LilyAcolasia.GameRound round) { Debug.Log("Game start!"); this.master.UpdateStatus(); }
public void RoundStart(LilyAcolasia.GameRound round) { Debug.Log("Round" + round.Round + " start!"); this.master.UpdateStatus(); }
/// <summary> /// Constructor. /// </summary> /// <param name="name1">Player1 name.</param> /// <param name="name2">Player2 name.</param> /// <param name="observer">Observer.</param> public GameOperator(IGameObserver observer, string name1, string name2, long seed, bool rev) { this.round = new GameRound(ROUND, name1, name2, new GameRandom(seed), rev); this.observer = observer; }