GangZoneFlashForAll Problem - Jarnu - 24.06.2012
Code
pawn Код:
public OnPlayerEnterDynamicCP(playerid, checkpointid)
{
if(checkpointid == CP[UnityStation])
{
if(tCP[UnityStation] == gTeam[playerid]) return SendClientMessage(playerid, COLOR_RED,"This zone is already captured by your team");
if(UnderAttack[UnityStation] == 1) return SendClientMessage(playerid, COLOR_RED,"This zone is already being taken over!");
UnderAttack[UnityStation] = 1;
timer[playerid][UnityStation] = SetTimerEx("SetZone",30000,false,"i", playerid);
SendClientMessage(playerid, COLOR_YELLOW,"You're Capturing this zone! Wait here for 30 Seconds!");
GangZoneFlashForAll(CP[UnityStation], COLOR_PINK);
iCP[playerid] = UnityStation;
}
if(checkpointid == CP[CluckinBell])
{
if(tCP[CluckinBell] == gTeam[playerid]) return SendClientMessage(playerid, COLOR_RED,"This zone is already captured by your team");
if(UnderAttack[CluckinBell] == 1) return SendClientMessage(playerid, COLOR_RED,"This zone is already being taken over!");
UnderAttack[CluckinBell] = 1;
timer[playerid][CluckinBell] = SetTimerEx("SetZone",30000, false, "i", playerid);
SendClientMessage(playerid, COLOR_YELLOW,"You're Capturing this zone! Wait here for 30 Seconds!");
GangZoneFlashForAll(CP[CluckinBell], COLOR_PINK);
iCP[playerid] = CluckinBell;
}
if(checkpointid == CP[Gym])
{
if(tCP[Gym] == gTeam[playerid]) return SendClientMessage(playerid, COLOR_RED,"This zone is already captured by your team");
if(UnderAttack[Gym] == 1) return SendClientMessage(playerid, COLOR_RED,"This zone is already being taken over!");
UnderAttack[Gym] = 1;
timer[playerid][Gym] = SetTimerEx("SetZone",30000, false, "i", playerid);
SendClientMessage(playerid, COLOR_YELLOW,"You're Capturing this zone! Wait here for 30 Seconds!");
GangZoneFlashForAll(CP[Gym], COLOR_PINK);
iCP[playerid] = Gym;
}
if(checkpointid == CP[HOTEL])
{
if(tCP[HOTEL] == gTeam[playerid]) return SendClientMessage(playerid, COLOR_RED,"This zone is already captured by your team");
if(UnderAttack[HOTEL] == 1) return SendClientMessage(playerid, COLOR_RED,"This zone is already being taken over!");
UnderAttack[HOTEL] = 1;
timer[playerid][HOTEL] = SetTimerEx("SetZone",30000, false, "i", playerid);
SendClientMessage(playerid, COLOR_YELLOW,"You're Capturing this zone! Wait here for 30 Seconds!");
GangZoneFlashForAll(CP[HOTEL], COLOR_PINK);
iCP[playerid] = HOTEL;
}
if(checkpointid == CP[CrackBin])
{
if(tCP[CrackBin] == gTeam[playerid]) return SendClientMessage(playerid, COLOR_RED,"This zone is already captured by your team");
if(UnderAttack[CrackBin] == 1) return SendClientMessage(playerid, COLOR_RED,"This zone is already being taken over!");
UnderAttack[CrackBin] = 1;
if(UnderAttack[UnityStation] == 1) return SendClientMessage(playerid, COLOR_RED,"Zone is already being taken over!");
timer[playerid][CrackBin] = SetTimerEx("SetZone",30000, false, "i", playerid);
SendClientMessage(playerid, COLOR_YELLOW,"You're Capturing this zone! Wait here for 30 Seconds!");
GangZoneFlashForAll(CP[CrackBin], COLOR_PINK);
UnderAttack[UnityStation] = 1;
iCP[playerid] = CrackBin;
}
if(checkpointid == CP[FireDept])
{
if(tCP[CrackBin] == gTeam[playerid]) return SendClientMessage(playerid, COLOR_RED,"This zone is already captured by your team");
if(UnderAttack[FireDept] == 1) return SendClientMessage(playerid, COLOR_RED,"This zone is already being taken over!");
UnderAttack[FireDept] = 1;
timer[playerid][FireDept] = SetTimerEx("SetZone",30000, false,"i", playerid);
SendClientMessage(playerid, COLOR_YELLOW,"You're Capturing this zone! Wait here for 30 Seconds!");
GangZoneFlashForAll(CP[FireDept], COLOR_PINK);
iCP[playerid] = FireDept;
}
return 1;
}
when i enter the CP gang zone doesn't flash why?
Re: GangZoneFlashForAll Problem -
Grand_Micha - 24.06.2012
Because you set your CHECKPOINT as your GANG ZONE, which makes no sense whatsoever.
Define zones before that and use a zone ID, not a CP ID!
Re: GangZoneFlashForAll Problem -
[MM]RoXoR[FS] - 24.06.2012
pawn Код:
GangZoneFlashForAll(CP[UnityStation], COLOR_PINK);
Replace CP[UnityStation] with gangZOne.
Re: GangZoneFlashForAll Problem - Jarnu - 24.06.2012
GangZone? but that won't help coz.. gangzone is UnityStation.
Re: GangZoneFlashForAll Problem -
Randy More - 24.06.2012
They mean the gang-zone id inserted for each zone creation, you won't flash the CP itself, you should do for the gang zone so.
Re: GangZoneFlashForAll Problem - Jarnu - 24.06.2012
i am totally confused.. -_- can someone do it?..
UnityStation 0
CluckinBell 1
Gym 2
HOTEL 3
CrackBin 4
FireDept 5
Please.. help.