[FIXED]Loop problem
#1

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...
Reply
#2

Glad we could be of help :P
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)