private void LobbyListRetrieved(uint count) { Debug.Log(count + " lobbies OnLobbyList"); if (count == 0) { GameObject.Find("OnlineBrowserScreen").GetComponent <OnlineBrowserController>().DisplayLobbyList(lobbyList); } else { for (uint i = 0; i < count; i++) { GalaxyID lobbyID = GalaxyInstance.Matchmaking().GetLobbyByIndex(i); lobbyList.Add(lobbyID); Debug.Log("Requesting lobby data for lobby " + i + " with lobbyID " + lobbyID.ToString()); matchmaking.RequestLobbyData(lobbyID); } } }
public override void OnLobbyList(uint count, LobbyListResult result) { if (result != LobbyListResult.LOBBY_LIST_RESULT_SUCCESS) { Debug.LogWarning("OnLobbyList failure reason: " + result); return; } Debug.Log(count + " lobbies OnLobbyList"); matchmaking.lobbyCount = count; if (count == 0) { GameObject.Find("OnlineBrowserScreen").GetComponent <OnlineBrowserController>().DisplayLobbyList(null); return; } for (uint i = 0; i < count; i++) { GalaxyID lobbyID = GalaxyInstance.Matchmaking().GetLobbyByIndex(i); Debug.Log("Requesting lobby data for lobby " + i + " with lobbyID " + lobbyID.ToString()); matchmaking.RequestLobbyData(lobbyID); } }