ZCMD Unknown command problem
#1

How do I change the text "SERVER: Unknown command" in ZCMD

I searched and found this but it does not work:
Код:
public OnPlayerCommandPerformed(playerid, cmdtext[], success) 
{
    if (!success) 
    {
        SendClientMessage(playerid, -1, "Wrong command");
    }
}
Reply
#2

You need to add return with a positive value - return 1, or just use value returned by SendClientMessage
pawn Код:
return SendClientMessage(playerid, -1, "Wrong command");
Reply
#3

Код:
zcmd.inc(127) : warning 209: function "OnPlayerCommandPerformed" should return a value
Код:
public OnPlayerCommandPerformed(playerid, cmdtext[], success) 
{
    if (!success) 
   {
        return SendClientMessage(playerid, -1, "Wrong command"); - Line 127
    }
}
Reply
#4

RESOLVED
Reply
#5

pawn Код:
public OnPlayerCommandPerformed(playerid, cmdtext[], success)
{
    if (!success)
    {
        return SendClientMessage(playerid, -1, "Wrong command");
    }
    return 0;
}
#e: ಠ_ಠ
Reply
#6

return 0;
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)