コード例 #1
0
 public override void OnLobbyLeft(GalaxyID lobbyID, LobbyLeaveReason leaveReason)
 {
     if (leaveReason != LobbyLeaveReason.LOBBY_LEAVE_REASON_USER_LEFT)
     {
         GameObject.Find("PopUps").GetComponent <PopUps>().PopUpWithLoadSceneButton("Connection to lobby lost\nReason: " +
                                                                                    leaveReason, "Back");
     }
     matchmaking.CurrentLobbyID        = null;
     matchmaking.LobbyOwnerID          = null;
     GameManager.Instance.GameFinished = true;
     GalaxyManager.Instance.ShutdownNetworking();
     matchmaking.LobbyManagmentInGameListenersDispose();
     matchmaking.LobbyChatListenersDispose();
 }
コード例 #2
0
 public override void OnLobbyLeft(GalaxyID lobbyID, LobbyLeaveReason leaveReason)
 {
     if (leaveReason != LobbyLeaveReason.LOBBY_LEAVE_REASON_USER_LEFT)
     {
         GameObject.Find("PopUps").GetComponent <PopUps>().PopUpWithClosePopUpsButton("Host left the lobby", "Back");
     }
     matchmaking.CurrentLobbyID = null;
     matchmaking.LobbyOwnerID   = null;
     matchmaking.lobbyName      = "";
     friends.SetRichPresence("connect", null);
     GameObject.Find("OnlineChat").GetComponent <ChatController>().DisposeEntries();
     GameObject.Find("MainMenu").GetComponent <MainMenuController>().SwitchMenu(MainMenuController.MenuEnum.Online);
     matchmaking.LobbyManagmentMainMenuListenersDispose();
     matchmaking.LobbyChatListenersDispose();
 }