Skip to main content

IsPlayerGangZoneFlashing

warning

This function was added in omp v1.1.0.2612 and will not work in earlier versions!

Description​

Check if the player gangzone is flashing.

NameDescription
playeridThe ID of the player to whom player gangzone is bound.
zoneidThe ID of the player gangzone.

Returns​

true - The player gangzone is flashing.

false - The player gangzone is not flashing.

Examples​

new gGangZoneID[MAX_PLAYERS];

public OnPlayerConnect(playerid)
{
// Create the gangzone
gGangZoneID[playerid] = CreatePlayerGangZone(playerid, 2236.1475, 2424.7266, 2319.1636, 2502.4348);

// Show the gangzone to player
PlayerGangZoneShow(playerid, gGangZoneID[playerid], 0xFF0000FF);
return 1;
}

public OnPlayerSpawn(playerid)
{
// Start player gangzone flash
PlayerGangZoneFlash(playerid, gGangZoneID[playerid], 0x45D1ABFF);
return 1;
}

public OnPlayerDeath(playerid, killerid, WEAPON:reason)
{
if (IsPlayerGangZoneFlashing(playerid, gGangZoneID[playerid]))
{
PlayerGangZoneStopFlash(playerid, gGangZoneID[playerid]);
}
return 1;
}