13.03.2010, 04:45
here is my script
if(strcmp(cmd, "/warrant", true) == 0) {
if (gTeam[playerid] == TEAM_COP) {
if (IsPlayerConnected(giveplayerid)) {
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "You have been warranted by %s!", sendername, playerid);
SendClientMessage(giveplayerid, COLOR_RED1, string);
format(string, sizeof(string), "%s has been warranted by %s!", giveplayer, giveplayerid, sendername, playerid);
SendClientMessageToAll(COLOR_RED1, string);
printf(string);
SetPlayerColor(playerid, COLOR_ORANGE);
return 1;
}else{
format(string, sizeof(string), "id %d is not an active player.", giveplayerid);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
}else{
format(string, sizeof(string), "You are not cop, you cannot jail.", giveplayerid);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
}else{
format(string, sizeof(string), "Someone already jailed that .", giveplayerid);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
When i go ingame,it shows SERVER:UNKOWN COMMAND message.
if(strcmp(cmd, "/warrant", true) == 0) {
if (gTeam[playerid] == TEAM_COP) {
if (IsPlayerConnected(giveplayerid)) {
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "You have been warranted by %s!", sendername, playerid);
SendClientMessage(giveplayerid, COLOR_RED1, string);
format(string, sizeof(string), "%s has been warranted by %s!", giveplayer, giveplayerid, sendername, playerid);
SendClientMessageToAll(COLOR_RED1, string);
printf(string);
SetPlayerColor(playerid, COLOR_ORANGE);
return 1;
}else{
format(string, sizeof(string), "id %d is not an active player.", giveplayerid);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
}else{
format(string, sizeof(string), "You are not cop, you cannot jail.", giveplayerid);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
}else{
format(string, sizeof(string), "Someone already jailed that .", giveplayerid);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
When i go ingame,it shows SERVER:UNKOWN COMMAND message.