02.08.2012, 22:42
(
Последний раз редактировалось Larceny; 21.04.2019 в 11:25.
)
MOVED TO GITHUB
Github
Description
* This include contains functions to manage gang zones,
* Also contains two callbacks to check when a player enters
* or leaves a zone.
Native list
Current Version
* 1.0
Functions info
Atention
* If you're using the include in a filterscript you must #define FILTERSCRIPT before including the inc file.
Callbacks info
Example
Download
Github
Thanks
* ******
* SA-MP Team.
Github
Description
* This include contains functions to manage gang zones,
* Also contains two callbacks to check when a player enters
* or leaves a zone.
Native list
pawn Код:
native GetDynamicZoneArea(zoneid, &Float:minx, &Float:miny, &Float:maxx, &Float:maxy);
native SetDynamicZoneArea(zoneid, Float:minx, Float:miny, Float:maxx, Float:maxy);
native CreateDynamicZone(Float:minx, Float:miny, Float:maxx, Float:maxy, color);
native FlashDynamicZoneForPlayer(playerid, zoneid, color);
native IsDynamicZoneFlashingForPlayer(playerid, zoneid);
native IsDynamicZoneVisibleForPlayer(playerid, zoneid);
native StopFlashDynamicZoneForPlayer(playerid, zoneid);
native ShowDynamicZoneForPlayer(playerid, zoneid);
native HideDynamicZoneForPlayer(playerid, zoneid);
native IsPlayerInDynamicZone(playerid, zoneid);
native FlashDynamicZoneForAll(zoneid, color);
native SetDynamicZoneColor(zoneid, color);
native StopFlashDynamicZoneForAll(zoneid);
native ShowDynamicZoneForAll(zoneid);
native HideDynamicZoneForAll(zoneid);
native GetDynamicZoneColor(zoneid);
native DestroyDynamicZone(zoneid);
native zexist(zoneid);
* 1.0
Functions info
Name | Function | Params |
StopFlashDynamicZoneForPlayer | Stops a zone of flashing for a player. | (playerid, zoneid) |
IsDynamicZoneFlashingForPlayer | Checks if a zone is flashing for a player. | (playerid, zoneid) |
IsDynamicZoneVisibleForPlayer | Checks if a zone is visible for a player. | (playerid, zoneid) |
StopFlashDynamicZoneForAll | Stops a zone of flashing for all. | (zoneid) |
ShowDynamicZoneForPlayer | Show a zone for a player. | (playerid, zoneid) |
FlashDynamicZoneForPlayer | Flashes a zone for a player. | (playerid, zoneid) |
HideDynamicZoneForPlayer | Hides a zone for a player. | (playerid, zoneid) |
ShowDynamicZoneForAll | Flashes a zone for all. | (zoneid) |
FlashDynamicZoneForAll | Flashes a zone for all. | (zoneid) |
HideDynamicZoneForAll | Flashes a zone for all. | (zoneid) |
IsPlayerInDynamicZone | Checks if a player is in a zone. | (playerid, zoneid) |
SetDynamicZoneColor | Set the color of a zone. | (zoneid, color) |
GetDynamicZoneColor | Get the color of a zone. | (zoneid) |
SetDynamicZoneArea | Change the zone position. | (zoneid, Float:minx, Float:miny, Float:maxx, Float:maxy) |
GetDynamicZoneArea | Store the zone position, passed by reference. | (zoneid, Float:minx, Float:miny, Float:maxx, Float:maxy) |
DestroyDynamicZone | Destroys a Dynamic Zone | (zoneid) |
CreateDynamicZone | Creates a Dynamic Zone. | (Float:minx, Float:miny, Float:maxx, Float:maxy, color) |
zexist | Check if a zone exist. | (zoneid) |
* If you're using the include in a filterscript you must #define FILTERSCRIPT before including the inc file.
Callbacks info
Name | Info | Params |
OnPlayerEnterDynamicZone | Called when a player enters a zone | (playerid, zoneid) |
OnPlayerExitDynamicZone | Called when a player exits a zone | (playerid, zoneid) |
pawn Код:
public OnPlayerEnterDynamicZone( playerid, zoneid )
{
if(zoneid == 1 && IsPlayerAdmin(playerid)) SendClientMessage( playerid, 0xFFFFFFFF, "Welcome to the zone, admin." );
return 1;
}
public OnPlayerExitDynamicZone( playerid, zoneid )
{
if(zoneid == 1 && IsPlayerAdmin(playerid)) SendClientMessage( playerid, 0xFFFFFFFF, "Good bye, admin." );
return 1;
}
Github
Thanks
* ******
* SA-MP Team.