Game Mode change Bug help![rep+]
#1

I have a TDM server , My script restart's the server/change's the GM after every 30 mins! It give's BattleWin message's and save score's! Everything use to work well. But now if noone logs into the server when a Round start's of 30 minutes. The server doesnt restart automatically! It works when i go InGame and check everything. But when there is noone in the server it doesnt do anything! I've set lot of timers to Change the game mode after 30 Minutes if one timer doesnt change it. But no helps nothing works if no one in the server.
I've used both SendRconCommand("changemode CWLS") as well as GameModeExit() , I dont know what is wrong. This function use to work well! Please help


pawn Код:
// Under OnGameModeInit()
SetTimer("GameModeChanger", 30 * 60 * 1000, 0);

forward GameModeChanger();
public GameModeChanger()
{
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
            DisablePlayerCheckpoint(i);
            OnPlayerDataSave(i);
            BattleWin();
            SendClientMessage(i, 0x66a2ff97,"* The Next Battle will start soon, dont keep your weapons away!");
            TogglePlayerControllable(i, 0);
            new Float:B,Float:C,Float:D;
            GetPlayerCameraPos(i,B,C,D);
            SetPlayerCameraPos(i,B-2,C-1,D+3);
            SetTimer("Changemode", 10 * 1000 , 0);
            dini_IntSet("CW/Scores.txt", "IndiaScore", IndiaScore);
            dini_IntSet("CW/Scores.txt", "USScore", USScore);
            dini_IntSet("CW/Scores.txt", "RusScore", RusScore);
            dini_IntSet("CW/Scores.txt", "PakScore", PakScore);
            dini_IntSet("CW/Scores.txt", "UKScore", UKScore);
        }
    }
}
forward Changemode();
public Changemode()
{
    SendRconCommand("changemode CWLS");
    return 1;
}
Reply


Messages In This Thread
Game Mode change Bug help![rep+] - by Ballu Miaa - 20.12.2011, 03:25
Re: Game Mode change Bug help![rep+] - by JamesC - 20.12.2011, 03:44
Re: Game Mode change Bug help![rep+] - by suhrab_mujeeb - 20.12.2011, 05:36

Forum Jump:


Users browsing this thread: 1 Guest(s)