Server: Unknown Command - How to solve this?
#4

I think so too actually, I know everyone hates them, but they're kind of fun to edit. I taught myself aswell.
Well, it starts with a few commands, and then after I've typed in 4-5 commands, they all just stop working.

pawn Код:
if(strcmp(cmd, "/update", true) == 0)
{
    if (PlayerInfo[playerid][pAdmin] >= 2)
    {
        SaveAccounts();
        SendClientMessage(playerid, COLOR_YELLOW, "All player accounts were successfully updated.");
    }
    else
    {
        SendClientMessage(playerid, COLOR_RED, "* You must be a level 2 admin to do this command.");
    }
    return 1;
}
This is one of the commands that fuck up.

pawn Код:
public SaveAccounts()
{
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
            SavePlayerSQL(i);
            if(PlayerInfo[i][pJob] > 0)
            {
                if(PlayerInfo[i][pContractTime] < 25)
                {
                    PlayerInfo[i][pContractTime] ++;
                }
            }
        }
    }
    return 1;
}
Figured I should add this, as it was called in the command /update.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)