GMX Bug?
#1

I've been through this over and over again, can't seem to make it work. I have a command for admins to restart the server while in-game and it executes the RCON command "gmx" - it restarts fine, but when the player spawns it goes to the 0.0 position with skin ID 0 and continuously dies but all of the other stats were loaded. I'm not sure if it's a bug for 0.3x or if there's another way of doing it since it worked the last time I coded the same thing.

I hope someone could resolve or help me with this. Below is what I have coded. Thanks!

GMX command:
pawn Код:
command(gmrestart, playerid, params[])
{
    if(IsPlayerConnected(playerid))
    {
        if(Player[playerid][pAdmin] >= 5)
        {
            OnGMX();
        }
    }
    return 1;
}
OnGMX():
pawn Код:
public OnGMX()
{
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
            OnPlayerSave(i);
            DisablePlayerCheckpoint(i);
            SetPlayerInterior(i, 0);
            SetPlayerVirtualWorld(i, 0);
            SetPlayerCameraPos(i, 1460.0, -1324.0, 287.2);
            SetPlayerCameraLookAt(i, 1374.5, -1291.1, 239.0);
        }
    }
   
    GameTextForAll("~w~Server Restarting...", 20000, 5);
    SetTimer("OnServerRestart", 10000, 0);
    return 1;
}
OnServerRestart():
pawn Код:
public OnServerRestart()
{
    SendRconCommand("gmx");
    return 1;
}
Reply


Messages In This Thread
GMX Bug? - by Skribblez - 12.03.2013, 15:09
Re: GMX Bug? - by Glad2BeHere - 12.03.2013, 15:15
Re: GMX Bug? - by Skribblez - 12.03.2013, 15:17
Re: GMX Bug? - by Glad2BeHere - 12.03.2013, 15:35
Re: GMX Bug? - by Patrick - 12.03.2013, 15:41
Re: GMX Bug? - by Skribblez - 12.03.2013, 15:41
Re: GMX Bug? - by Glad2BeHere - 12.03.2013, 15:50
Re: GMX Bug? - by Skribblez - 12.03.2013, 15:57
Re: GMX Bug? - by Glad2BeHere - 12.03.2013, 16:03
Re: GMX Bug? - by Skribblez - 12.03.2013, 16:07

Forum Jump:


Users browsing this thread: 2 Guest(s)