CMD trouble (sscanf)
#2

You're indicating to sscanf that "title" is a string, but you've defined it as an integer. I would also recommend placing the string as the last parameter, because strings may have spaces and you may confuse sscanf parsing system.

Код:
CMD:menu(playerid, params[])
{
    new title[32], columns, Float:x, Float:y, Float:col1width, Float:col2width;
    if(sscanf(params, "dffffs", columns, Float:x, Float:y, Float:col1width, Float:col2width, title)) return SendClientMessage(playerid, -1, "Usage: CreateMenu(columns, Float:x, Float:y, Float:col1width, Float:col2width, title);");
    {
        CreateMenu(title, columns, Float:x, Float:y, Float:col1width, Float:col2width);
    }
    return 1;
}
Reply


Messages In This Thread
CMD trouble (sscanf) - by cnoopers - 22.02.2015, 15:16
Re: CMD trouble (sscanf) - by admantis - 22.02.2015, 15:23
Re: CMD trouble (sscanf) - by AndySedeyn - 22.02.2015, 15:35

Forum Jump:


Users browsing this thread: 1 Guest(s)