03.01.2013, 10:24
If I type something like "/le Hello!" it will send to the leaders: /le Hello!; not just Hello!
Please help me!
This is the code:
if (strcmp("/le", cmdtext, true, 3) == 0)
{
new
string[128],
leader[28],
text[100]
;
if(!IsLeader(playerid)) return SendClientMessage(playerid, COLOR_YELLOW, "You are not a leader!");
GetPlayerName(playerid, leader, sizeof(leader));
if(sscanf(cmdtext, "s[128]", text)) return SendClientMessage(playerid, COLOR_YELLOW, "USAGE: /le <text>");
format(string,sizeof(string),"*Leader %s: %s",leader,text);
SendClientMessageToLeaders(0xB6BAFFFF,string);
return 1;
}
Please help me!
This is the code:
if (strcmp("/le", cmdtext, true, 3) == 0)
{
new
string[128],
leader[28],
text[100]
;
if(!IsLeader(playerid)) return SendClientMessage(playerid, COLOR_YELLOW, "You are not a leader!");
GetPlayerName(playerid, leader, sizeof(leader));
if(sscanf(cmdtext, "s[128]", text)) return SendClientMessage(playerid, COLOR_YELLOW, "USAGE: /le <text>");
format(string,sizeof(string),"*Leader %s: %s",leader,text);
SendClientMessageToLeaders(0xB6BAFFFF,string);
return 1;
}