Beispiel #1
0
 public override void OnPlayerLeftRoom(Player otherPlayer)
 {
     if (_gameController.IsGameStart)
     {
         OnNetworkErrorEvent?.Invoke("A player left the game.", "A player left the game while the game was in progress. ");
     }
     OnPlayerLeftEvent?.Invoke();
 }
Beispiel #2
0
 public void JoinRoom(string roomName)
 {
     if (roomName != "")
     {
         PhotonNetwork.JoinRoom(roomName);
     }
     else
     {
         OnNetworkErrorEvent?.Invoke("An error occured while joining a room.", "You must specify an Id to connect to room.");
     }
 }
Beispiel #3
0
 public override void OnCreateRoomFailed(short returnCode, string message)
 {
     OnNetworkErrorEvent?.Invoke("An error occured while creating a room.", message);
 }