Sscanf Warning, [HELP]
#1

Code:

pawn Код:
CMD:aduneb(playerid, params[])
{
    new id;
    new string[256];
    if(sscanf(params,"ui",id)) return SendClientMessage(playerid, RED, "[USAGE]: /aduneb [id]");
    if(!IsPlayerConnected(id))
    {
        format(string,sizeof(string),"The player ID (%d) is not connected to the server. You cannot take away his/her EB status.",id);
        SendClientMessage(playerid,RED,string);
        return 1;
    }
    if(IsLoggedIn{id} == 0)
    {
     SendClientMessage(playerid, RED, "Player not logged in.");
        return 1;
    }
    if(CanUseEB[id] != 1337)
    {
        format(string,sizeof(string),"%s(%d) is not an EB member.",GetName(id),id);
        SendClientMessage(playerid,RED,string);
        return 1;
    }
    if(PlayerInfo[playerid][aLevel] >= 3)
    {
    format(string,sizeof(string),"[ADMIN EB] Administrator has taken away %s(%d) EB status.",GetName(id),id);
    SendClientMessageToAll(GREEN,string);
    SendClientMessage(id,GREEN,"You have been taken away EB status by a Server Administrator. What a Mess.");
    CanUseEB[id] =0;
    SaveUserStats(id);
    }
 else
 {
         SendClientMessage(playerid, RED, "Only admin level +3 can use this command.");
 }
    return true;
}

CMD:adeb(playerid, params[])
{
    new id;
    new string[256];
    if(sscanf(params,"ui",id)) return SendClientMessage(playerid, RED, "[USAGE]: /adeb [id]");
    if(!IsPlayerConnected(id))
    {
        format(string,sizeof(string),"The player ID (%d) is not connected to the server. You cannot give them EB status.",id);
        SendClientMessage(playerid,RED,string);
        return 1;
    }
    if(IsLoggedIn{id} == 0)
    {
     SendClientMessage(playerid, RED, "Player not logged in.");
        return 1;
    }
    if(CanUseEB[id] == 1337)
    {
        format(string,sizeof(string),"%s(%d) is already an EB member.",GetName(id),id);
        SendClientMessage(playerid,RED,string);
        return 1;
    }
    if(PlayerInfo[playerid][aLevel] >= 3)
    {
    format(string,sizeof(string),"[ADMIN EB] Administrator has given %s(%d) EB status.",GetName(id),id);
    SendClientMessageToAll(GREEN,string);
    SendClientMessage(id,GREEN,"You have been given EB status by a Server Administrator. Congratulations.");
    CanUseEB[id] =1337;
    SaveUserStats(id);
    }
 else
 {
         SendClientMessage(playerid, RED, "Only admin level +3 can use this command.");
 }
    return 1;
}

ERROR
Код:
 
sscanf warning: Format specifier does not match parameter count
How to fix it?
Reply


Messages In This Thread
Sscanf Warning, [HELP] - by James Coral - 22.12.2012, 09:47
Re: Sscanf Warning, [HELP] - by Djole1337 - 22.12.2012, 09:49
Re: Sscanf Warning, [HELP] - by James Coral - 22.12.2012, 09:49
Re: Sscanf Warning, [HELP] - by park4bmx - 22.12.2012, 09:50
Re: Sscanf Warning, [HELP] - by James Coral - 22.12.2012, 09:52
Re: Sscanf Warning, [HELP] - by Djole1337 - 22.12.2012, 09:54
Re: Sscanf Warning, [HELP] - by Konstantinos - 22.12.2012, 10:08
Re: Sscanf Warning, [HELP] - by Djole1337 - 22.12.2012, 10:13
Re: Sscanf Warning, [HELP] - by Konstantinos - 22.12.2012, 10:16

Forum Jump:


Users browsing this thread: