SA-MP Forums Archive
[FIXED]Loop problem - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [FIXED]Loop problem (/showthread.php?tid=200546)



[FIXED]Loop problem - Mean - 18.12.2010

pawn Код:
dcmd_gmx(playerid,params[])
{
    if(AccInfo[playerid][Level] < 5) return SendClientMessage(playerid, red, "ERROR: You must be level 5 to use this command");
    new string[128];
    new playername[MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername, MAX_PLAYER_NAME);
    if( isnull( params ))
    {
        format(string,sizeof(string), "Administrator %s has restarted the server || Reason: Not given", playername);
    }
    else
    {
        format(string,sizeof(string), "Administrator %s has restarted the server || Reason: %s", playername, params);
    }
    for(new i=0; i<MAX_PLAYERS; i++) if(IsPlayerConnected(i)) PlayerPlaySound(i,1057,0.0,0.0,0.0);
    SendClientMessageToAll(blue, string);
    SendRconCommand("gmx");
    return 1;
}
Added this in LuxAdmin FS and no errors or anything, but it crashed my game, not server. Any help?




EDIT: Works somehow now, it crashed me once, weird...


Re: [FIXED]Loop problem - Benjo - 18.12.2010

Glad we could be of help :P