28.11.2012, 20:57
pawn Код:
if(!strcmp(cmd,"/siren", true))
{
if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2 || PlayerInfo[playerid][pLeader] == 3 || PlayerInfo[playerid][pMember] == 3 || IsAFreecop(playerid))
{
new SirenObject[MAX_VEHICLES];
new VID = GetPlayerVehicleID(playerid);
if (sirenstatus == 0)
{
SirenObject[VID] = CreateObject(19419, 0, 0, 0, 0, 0, 0);
AttachObjectToVehicle(SirenObject[VID], VID, 0.009999, -0.019999, 0.944999, 0.000000, 0.000000, 0.000000);
sirenstatus = 1;
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* Undercover, Siren added!");
return 1;
}
else if(sirenstatus == 1)
{
DestroyObject(SirenObject[VID]);
sirenstatus = 0;
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* Undercover, Siren removed!");
return 1;
}
}
return 1;
}