19.06.2015, 09:19
Here some light on what you're trying to understand. Let's say I have a command called say and I use if(sscanf(parmas, "s[128]", text)) return SendClientMessage(playerid, -1, "ERROR: You haven't used the command correctly use /say testing1...2....3");
What that would do if you just did /say it would return that SendClientMessage, if you use /say siaais it will imput the command.
Edit: heres a command
What that would do if you just did /say it would return that SendClientMessage, if you use /say siaais it will imput the command.
Edit: heres a command
PHP код:
CMD:test(playerid, params[])
{
new text[128], string[128];
if(sscanf(params, "s[128]", text)) return SendClientMessage(playerid, -1, "/test [message]"); //Check if the command has a extra input e.g /test hello :D
format(string, sizeof(string), "%s", text); //Format the string
SendClientMessageToAll(-1, string);
return 1;
}
