Warning [+REP]
#1

PHP код:
warning 202number of arguments does not match definition 
The line:
PHP код:
YCMD:me(playeridparams[]) 
Whole function:
PHP код:
YCMD:me(playeridparams[])
{
    new 
string[128];
    if (
isnull(params))
    {
        
format(stringsizeof(string), "[USAGE:] /me [Action]");
        
SendClientMessage(playeridCOLOR_WHITEstring);
    }
    else
    {
    
format(stringsizeof(string), "* %s %s"GetName(playerid), params);
    
SendClientMessageToAll(0xFF0000AAstring);
    }
    return 
1
}
Reply
#2

Try this
pawn Код:
YCMD:me(playerid, params[], help)
{
    new string[128];
    if (isnull(params))
    {
        format(string, sizeof(string), "[USAGE:] /me [Action]");
        SendClientMessage(playerid, COLOR_WHITE, string);
    }
    else
    {
    format(string, sizeof(string), "* %s %s", GetName(playerid), params);
    SendClientMessageToAll(0xFF0000AA, string);
    }
    return 1;
}
Reply
#3

It's:
pawn Код:
YCMD:me(playerid, params[], help)
Reply
#4

ZCMD
PHP код:
CMD:me(playeridparams[])
{
    if(
isnull(params)) return SendClientMessageEx(playeridCOLOR_WHITE"USAGE: /me [Action]");
    new 
string[128];
    
format(stringsizeof(string), "* %s %s"GetPlayerNameEx(playerid), params);
    
ProxDetector(25.9playeridstringCOLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
    return 
1;

Which line has errorS?
Reply
#5

still has the same warning
Reply
#6

Post again the command and say what's the line.
Reply
#7

I already showed you the specific line and the whole function..

Quote:
Originally Posted by Tomer!.$
Посмотреть сообщение
The line:
PHP код:
YCMD:me(playeridparams[]) 
Whole function:
PHP код:
YCMD:me(playeridparams[])
{
    new 
string[128];
    if (
isnull(params))
    {
        
format(stringsizeof(string), "[USAGE:] /me [Action]");
        
SendClientMessage(playeridCOLOR_WHITEstring);
    }
    else
    {
    
format(stringsizeof(string), "* %s %s"GetName(playerid), params);
    
SendClientMessageToAll(0xFF0000AAstring);
    }
    return 
1
Reply
#8

+REP to the one who solves it!
Reply
#9

Help?
Reply
#10

Jesus, I already told you. If you use YCMD, you need the 'help' parameter too:

pawn Код:
YCMD:me(playerid, params[], help)
Is it that hard?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)