private static void Postfix(ref bool __result, PrivateMatchDataMessage pmd, ref int ___m_num_players_to_start_match)
 {
     ApplyMatchOLModData();
     if (___m_num_players_to_start_match == 2) // always allow start with 1
     {
         ___m_num_players_to_start_match = 1;
     }
     if (!__result && !Config.NoDownload && !string.IsNullOrEmpty(pmd.m_addon_level_name_hash)) // unknown level?
     {
         MPDownloadLevel.StartGetLevel(pmd.m_addon_level_name_hash);
         __result = true;
     }
 }
示例#2
0
        static void Postfix()
        {
            if (Config.NoDownload)
            {
                return;
            }
            string level = NetworkMatch.m_last_lobby_status.m_match_playlist_addon_idstringhash;

            if (level != null && level != "" && GameManager.MultiplayerMission.FindAddOnLevelNumByIdStringHash(level) < 0)
            {
                MPDownloadLevel.StartGetLevel(level);
            }
        }
示例#3
0
 static bool Prefix(string name)
 {
     if (!name.Contains(":") || Config.NoDownload)
     {
         return(true);
     }
     if (!MPDownloadLevel.DownloadBusy && GameManager.MultiplayerMission.FindAddOnLevelNumByIdStringHash(name) < 0)
     {
         MPDownloadLevel.StartGetLevel(name);
     }
     if (MPDownloadLevel.DownloadBusy)
     {
         Debug.Log("Level still downloading when loading match scene, delay scene load " + name);
         GameManager.m_gm.StartCoroutine(WaitLevel(name));
         return(false);
     }
     return(true);
 }