Beispiel #1
0
 public GameContext(ServerRouter sr, string rn)
 {
     serverRouter = sr;
     mjModel = new GameModel();
     serverController = new GameController(sr, mjModel);
     roomName = rn;
     serverState = new AfterInitialiseState(serverController);
 }     
Beispiel #2
0
 public AfterStartKyokuState(GameState ss)
 {
     this.serverController = ss.serverController;
 }
Beispiel #3
0
 public EndState(GameState ss)
 {
     this.serverController = ss.serverController;
 }
Beispiel #4
0
 public AfterHoraState(GameState ss)
 {
     this.serverController = ss.serverController;
 }
Beispiel #5
0
 public AfterReachAccceptState(GameState ss, BlockingCollection<MjsonMessageAll> getMsgList)
 {
     this.serverController = ss.serverController;
     this.prevMsgList = getMsgList;
 }
Beispiel #6
0
 public AfterReachDahaiState(GameState ss)
 {
     this.serverController = ss.serverController;
 }
Beispiel #7
0
 public AfterInitialiseState(GameState ss)
 {
     this.serverController = ss.serverController;
 }
Beispiel #8
0
 public AfterTsumoState(GameState ss)
 {
     this.serverController = ss.serverController;
 }
Beispiel #9
0
 //ここからメッセージを受け取った際の状態遷移関数
 public void GetMessage(MjsonMessageAll msgobj)
 {
     serverState = serverState.GetMessage(msgobj);
 }
Beispiel #10
0
 public void GetJoin(MjsonMessageAll msgobj)
 {
     serverController.Join(msgobj.name);
     serverState = serverState.GetMessage(msgobj);
 }