sscanf warning: Format specifier does not match parameter count.
#1

Help Me Please
Reply
#2

the same warning says the error .. Code?
Reply
#3

Код:
CMD:givecash(playerid, params[])
{
    new player, amount,name1[24], name2[24], string[128];
    if(PlayerInfo[playerid][pAdmin] >= 3) return SendClientMessage(playerid,COLOR_RED,"[ERROR]Kamu Bukan Admin!");
    if(!sscanf(params, "ui",player,amount))
    {
        GetPlayerName(playerid, name1, 24);
        GetPlayerName(player, name2, 24);
        format(string, sizeof(string), "{3BF5C6}[INFO]{B30222} - Kamu Menerima $%d ke %s.",amount,name2);
        SendClientMessage(playerid, 0xFFFF00FF, string);
        format(string, sizeof(string), "{3BF5C6}AdmCmd: {B30222}Admin %s gave you $%d!", name1, amount);
        SendClientMessage(player, 0xFFFF00FF, string);
        GivePlayerMoney(player, amount);
    }
    else return SendClientMessage(playerid, 0xFFFFFFFF,"{3BF5C6}[USE]{B30222}: /givecash [Player ID] [Cash]");
    return 1;
}
Reply
#4

if(!sscanf(params, "ui[128]",player,amount))
{
Reply
#5

This command doesn't hold any string characters, so it must be some other command or function which gives this warning.
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)