GMX command issue
#1

Hello everyone,

I'm trying to solve the GMX issue but I just cant. I need your help.
There is no Errors or something. Only issue I'll show you the code and bring you some small desc.

The Public:

pawn Код:
public OnGameModeExit()
{
    foreach (Player,i)
    {
        OnPlayerDataSave(i);
        DeletePVar(i, "PlayerLogged");
    }
    SaveBizz();
    SaveProperty();
    SaveCars();
    SaveFactions();
    SaveInts();
    SaveTags();
    SaveNormalCars();
    SaveCars2();
    printf("Gamemode has been restarted successfully.");
    return 1;
}




The Command:


pawn Код:
COMMAND:gmx(playerid, params[])
{
    if (GetPVarInt(playerid, "PlayerLogged") == 0) return SendClientMessage(playerid, COLOR_WHITE, "SERVER: You must be logged in to use this.");
    if(!AdminUser(playerid)) return SendClientMessage(playerid, COLOR_GREY, "SERVER: You need to create a admin user, /admincreate.");
    if(GetPVarInt(playerid, "AdminLogged") == 0) return SendClientMessage(playerid, COLOR_GREY, "SERVER: You need to login into your admin account, /adminlogin.");
    if(GetPVarInt(playerid, "Admin") >= 10)
    GameModeExit();
    else SendClientMessage(playerid, COLOR_LIGHTRED, "You do not have access to this command !");
    return 1;
}
When I'm typing this command the server is being restarted and my account stay like I logged in before and not like I left him after the reset. I just dont know what is the issue here in the script I just Its aint working.

Thanks for everyones support.
Reply


Messages In This Thread
GMX command issue - by wakeuptomer - 27.07.2014, 11:35
Re: GMX command issue - by Marcoes - 27.07.2014, 11:45
Re: GMX command issue - by wakeuptomer - 27.07.2014, 13:12
Re: GMX command issue - by wakeuptomer - 27.07.2014, 17:36
Re: GMX command issue - by DaniceMcHarley - 27.07.2014, 17:42
Re: GMX command issue - by wakeuptomer - 28.07.2014, 08:31
Re: GMX command issue - by wakeuptomer - 29.07.2014, 15:02
Re: GMX command issue - by wakeuptomer - 30.07.2014, 13:09
Re: GMX command issue - by Stanford - 30.07.2014, 14:07
Re: GMX command issue - by DaniceMcHarley - 30.07.2014, 14:09

Forum Jump:


Users browsing this thread: 1 Guest(s)