31.03.2015, 22:49
I went through the whole sscanf specifiers, and I just could not get which one I had to use, or not even.
The code is /setcolor
It is just, when you type /setcolor it will turn MY color to blue. But How do I make it so, that if I type /setcolor it will display a message /setcolor [ID] [COLOR]. I didn't know which specifier I had to use in sscanf.
The code is /setcolor
PHP код:
CMD:setcolor(playerid, params[])
{
if(IsPlayerAdmin(playerid))
{
SetPlayerColor(playerid, COLOR_BLUE);
SendClientMessage(playerid, COLOR_LIME, "You have set your colour.");
}
else
{
SendClientMessage(playerid, -1, "SERVER: Unknown command.");
}
return 1;
}