17.08.2012, 21:03
Just an example:
pawn Код:
CMD:duty(playerid, params[])
{
new option[24];
if(sscanf(params, "s[24]", option)) return SendClientMessage(playerid, -1, "Usage: /duty [job/faction]");
if(!strcmp(option, "cop", true)) //If they typed cop for the option
{
//Do something
}
else if(!strcmp(option, "taxi", true)) //If they typed taxi for the option
{
//Do something
}
else return SendClientMessage(playerid, -1, "Incorrect option!");
return 1;
}