11.09.2010, 01:59
Okay,
So I made a /bk Cmd in DCMD. Only one slight Issue. It send "Police Use Only" to me even when Im in the NSP team, If I'm not it doesn't send ERROR.
I know im in the NSP team because all my other commands work.
So I made a /bk Cmd in DCMD. Only one slight Issue. It send "Police Use Only" to me even when Im in the NSP team, If I'm not it doesn't send ERROR.
I know im in the NSP team because all my other commands work.
pawn Код:
dcmd_bk(playerid,params[])
{
new string[128];
new location[MAX_ZONE_NAME];
new chat[256];
GetPlayer2DZone(playerid, location, MAX_ZONE_NAME);
for(new i=0; i<MAX_PLAYERS; i++) {
if(sscanf(params,"s",chat)) return SendClientMessage(playerid,COLOR_YELLOW,"ERROR: Police Use Only.");
GetPlayerName(playerid, playername, sizeof(playername));
if(PlayerTeam[playerid] == Team_NSP || PlayerTeam[playerid] == Team_LVPD) {
format(string, sizeof(string), "-------------------------------------------------------------------------------------------------------------");
SendMessageToLaw(string);
format(string, sizeof(string), "POLICE DISPATCH (911 CALL)");
SendMessageToEMS(string);
format(string, sizeof(string), "Be advised. The following is a Priority One Call.");
SendMessageToEMS(string);
format(string, sizeof(string), "Officer Name: %s",playername);
SendMessageToEMS(string);
format(string, sizeof(string), "Officer ID: %d",playerid);
SendMessageToEMS(string);
format(string, sizeof(string), "Officer Need's Immediate Assistance");
SendMessageToEMS(string);
format(string, sizeof(string), "Officer location: %s",location);
SendMessageToEMS(string);
format(string, sizeof(string), "-------------------------------------------------------------------------------------------------------------");
}
}
return 1;
}