02.07.2013, 16:43
Start off with 3 people dying.
Check if these people died in the area that you want them to die
Getplayerpos or IsPlayerInrangeOfPoint
In OnplayerDeath,
So now you can put a timer that makes the gangzones flash, change the color every second, or something like that.
Don't forget to add a timer that counts to 2 minutes.
And at the end of the 2 minute timer, you change the gangzone to the team that took over.
Let me know If you have any questions
pawn Код:
new deaths = 0;
Getplayerpos or IsPlayerInrangeOfPoint
In OnplayerDeath,
pawn Код:
public OnPlayerDeath(...)
{
(Might want to check if a player is in a specific team here)
{
if(Did the player die in your area)
{
deaths= deaths +1
if(deaths == 3)
{
SetTimerEx(EndTimer, ....);
SetTimerEx(FlashTimer, ....);
}
}
return 1;
}
}
Don't forget to add a timer that counts to 2 minutes.
pawn Код:
public FlashTimer(...)
{
Change the color;
SetTimerEx(FlashTimerTwo,...);
return 1;
}
public FlashTimerTwo(...)
{
Change the color;
SetTimerEx(FlashTimer,...);
return 1;
}
pawn Код:
public endtimer(...)
{
KillTimer(FlashTimer);
KillTimer(FlashTimerTwo);
Change the color if you want to
return 1;
}