15.07.2010, 17:48
So I made a /me command from scratch:
When I type /me with only two letters after (like /me hi) it works, but if I type more than 2 letters it doesn't work. It just says "Unknown Command".
pawn Код:
CMD:me(playerid, params[])
{
if(IsPlayerConnected(playerid))
{
new message;
if(sscanf(params, "s", message)) return SendClientMessage(playerid, CYAN, "[USAGE]: /me [text]. This command will display a local message, used for showing actions.");
{
new string[128];
format(string, sizeof(string), "*[ACTION]* %s: %s", ReturnPlayerName(playerid), message);
ProxDetector(30.0, playerid, string, PURPLE,PURPLE,PURPLE,PURPLE,PURPLE);
}
}
return 1;
}