Woah! My CMDS are not working!
#6

You don't need sscanf() for this params is already a string you only need to check if it's null. You should also work on your logic your using return; improperly it inflates your code uselessly.

pawn Код:
CMD:me(playerid, params[])
{
    new string[128];
    if(isnull(params)) SendClientMessage(playerid, -1, "USAGE: /me [action]");
    else
    {
        new pName[MAX_PLAYER_NAME];
        GetPlayerName(playerid,pName,sizeof(pName));
        format(string, sizeof(string), "* %s %s",pName, action);
        SendClientMessage(playerid,COLOR_HERE,string); // <<----------
    }
    return 1;
}
Reply


Messages In This Thread
Woah! My CMDS are not working! - by Songason - 18.06.2013, 14:09
Re: Woah! My CMDS are not working! - by Littlehelper - 18.06.2013, 14:12
AW: Woah! My CMDS are not working! - by Blackazur - 18.06.2013, 14:14
Re: AW: Woah! My CMDS are not working! - by Songason - 18.06.2013, 14:15
Re: Woah! My CMDS are not working! - by Enforcer501 - 18.06.2013, 14:31
Re: Woah! My CMDS are not working! - by Pottus - 18.06.2013, 14:42
Re: Woah! My CMDS are not working! - by Enforcer501 - 18.06.2013, 14:49
Re: Woah! My CMDS are not working! - by Pottus - 18.06.2013, 14:56

Forum Jump:


Users browsing this thread: 5 Guest(s)