PRoConEvents.MULTIbalancer.OnLevelLoaded C# (CSharp) Method

OnLevelLoaded() public method

public OnLevelLoaded ( String mapFileName, String Gamemode, int roundsPlayed, int roundsTotal ) : void
mapFileName String
Gamemode String
roundsPlayed int
roundsTotal int
return void
        public override void OnLevelLoaded(String mapFileName, String Gamemode, int roundsPlayed, int roundsTotal)
        {
            if (!fIsEnabled) return;

            DebugWrite("^9^bGot OnLevelLoaded^n: " + mapFileName + " " + Gamemode + " " + roundsPlayed + "/" + roundsTotal, 7);

            try {
            DebugWrite(":::::::::::::::::::::::::::::::::::: ^b^1Level loaded detected^0^n ::::::::::::::::::::::::::::::::::::", 3);

            if (fGameState == GameState.RoundEnding || (fGameState == GameState.Warmup && TotalPlayerCount() >= 4) || fGameState == GameState.Unknown) {
            fGameState = GameState.RoundStarting;
            DebugWrite("OnLevelLoaded: ^b^3Game state = " + fGameState, 6);

            CheckRoundEndingDuration();
            }

            fMaxTickets = -1; // flag to pay attention to next serverInfo
            ServerCommand("serverInfo");

            UpdateRoundTimeLimit();
            if (fGameVersion == GameVersion.BF4) UpdateFactions();
            } catch (Exception e) {
            ConsoleException(e);
            }
        }
MULTIbalancer