25.11.2013, 22:05
whenever I use my /gmx command it doens't save my Player Files.
Command:
GMX Variable
Command:
pawn Код:
COMMAND:gmx(playerid, targetid, params[])
{
if(PlayerStat[playerid][AdminLevel] < 5) return SendClientMessage(playerid, GREY, "You are not authorized to use this command.");
GMX(playerid);
new string[128];
for(new i = 0; i < MAX_PLAYERS; i++)
format(string, sizeof(string), "%s %s has issued a server restart, it will occur in 30 seconds.", GetAdminRank(playerid), GetOOCName(playerid));
SendClientMessageToAll(GOLD, string);
SetTimer("gmxtimer", 30000, false);
return 1;
}
pawn Код:
stock GMX(playerid)
{
SavePlayerData(playerid);
for(new i = 0; i < MAX_PLAYERS; i++)
{
SavePlayerData(i);
}
for(new g = 1; g < MAX_GANGS; g++)
{
SaveGang(g);
}
return 1;
}