SA-MP Forums Archive
Zones - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Zones (/showthread.php?tid=297217)



Zones - cruising - 14.11.2011

Hello.

how do i make these zones flash for the team when a non team member enter the zone?
And yes, i have tried before ask.

pawn Код:
new Text:Zones[MAX_PLAYERS];

public OnGameModeInit()
{
    //=====================================ZONES==================================================//
    ZoneThunderbirds = GangZoneCreate(-2907.791, -1027.653, -607.2495, 1646.58);
    ZoneBackup = GangZoneCreate(-2907.791, -1027.653, -607.2495, 1646.58);
    ZoneAirwolves = GangZoneCreate(817.4513, 607.2495, 2931.147, 2896.113);
    ZoneBluefoxes = GangZoneCreate(81.74512, -2931.147, 2977.858, -840.807);
    //===================================END ZONES===============================================//
    return 1;
}

public OnPlayerSpawn(playerid)
{
    GangZoneShowForPlayer(playerid, ZoneThunderbirds, 0xFFFF0015);
    GangZoneShowForPlayer(playerid, ZoneBackup, 0xFFFF0015);
    GangZoneShowForPlayer(playerid, ZoneAirwolves, 0x00000060);
    GangZoneShowForPlayer(playerid, ZoneBluefoxes, 0x0000FF27);
I know need to use this (on isPlayerInArea?), but im not sure how to code it proper
pawn Код:
GangZoneFlashForPlayer(playerid,gangzone,COLOR_RED);



Re: Zones - MP2 - 15.11.2011

Set a repeating timer to loop through all players and check if they are in the area.