Пример #1
0
 public static ServerToClientMessage PiecePromotedMessage(PiecePromotion promotion)
 {
     ServerToClientMessage message = new ServerToClientMessage(ServerToClientMessageType.PiecePromoted);
     message.Promotion = promotion;
     return message;
 }
Пример #2
0
 public static ServerToClientMessage PieceMovedMessage(PieceMove move)
 {
     ServerToClientMessage message = new ServerToClientMessage(ServerToClientMessageType.PieceMoved);
     message.Move = move;
     return message;
 }
Пример #3
0
 public static ServerToClientMessage NewTurnMessage(NewTurn newTurn)
 {
     ServerToClientMessage message = new ServerToClientMessage(ServerToClientMessageType.NewTurn);
     message.NewTurn = newTurn;
     return message;
 }
Пример #4
0
 public static ServerToClientMessage GameStartedMessage(GameStart gameStart)
 {
     ServerToClientMessage message = new ServerToClientMessage(ServerToClientMessageType.GameStarted);
     message.GameStart = gameStart;
     return message;
 }
Пример #5
0
 public static ServerToClientMessage GameEndedMessage(GameOutcome outcome)
 {
     ServerToClientMessage message = new ServerToClientMessage(ServerToClientMessageType.GameEnded);
     message.Outcome = outcome;
     return message;
 }
Пример #6
0
 public static ServerToClientMessage ErrorMessage(Error error)
 {
     ServerToClientMessage message = new ServerToClientMessage(ServerToClientMessageType.Error);
     message.Error = error;
     return message;
 }