new GZ_ZONE1;
public OnGameModeInit()
{
GZ_ZONE1 = GangZoneCreate(890.625,503.90625,2906.25,2906.25,-1,-1,-1,2.0,0x00000060);
return 1;
}
public OnPlayerSpawn(playerid)
{
GangZoneShowForAll(GZ_ZONE1,-1,0x00000060);
return 1;
}
native GangZoneCreate(Float:minx, Float:miny, Float:maxx, Float:maxy, color = -1, interior = -1, virtualworld = -1, Float:bordersize = 1.0, bordercolor = 0x00000060); native GangZoneDestory(zone); native GangZoneExist(zone); native GangZoneShowForPlayer(playerid, zone, color = -1, bordercolor = -1); native GangZoneShowForAll(zone, color = -1, bordercolor = -1); native GangZoneHideForPlayer(playerid, zone); native GangZoneHideForAll(zone); native GangZoneSetColorForPlayer(playerid, zone, color, bordercolor = 0x00000060); native GangZoneSetColorForAll(playerid, zone, color, bordercolor = 0x00000060); native GangZoneFlashForPlayer(playerid, zone, flashcolor); native GangZoneFlashForAll(zone, flashcolor); native GangZoneStopFlashForPlayer(playerid, zone); native GangZoneStopFlashForAll(zone); native GangZoneSetInterior(zone, interior); native GangZoneGetInterior(zone); native GangZoneSetVirtualWorld(zone, virtualworld); native GangZoneGetVirtualWorld(zone); native CountAllGangZones(); native DestroyAllGangZones(); native ShowAllGangZonesForPlayer(playerid, color = -1, bordercolor = -1); native ShowAllGangZonesForAll(color = -1, bordercolor = -1); native HideAllGangZonesForPlayer(playerid); native HideAllGangZonesForAll(); native IsPlayerInGangZone(playerid, zone); native IsPlayerInAnyGangZone(playerid); native GetPlayerGangZone(playerid);
Same as normal one,just add border in GangZoneCreate params,functions:
Код:
native GangZoneCreate(Float:minx, Float:miny, Float:maxx, Float:maxy, color = -1, interior = -1, virtualworld = -1, Float:bordersize = 1.0, bordercolor = 0x00000060); native GangZoneDestory(zone); native GangZoneExist(zone); native GangZoneShowForPlayer(playerid, zone, color = -1, bordercolor = -1); native GangZoneShowForAll(zone, color = -1, bordercolor = -1); native GangZoneHideForPlayer(playerid, zone); native GangZoneHideForAll(zone); native GangZoneSetColorForPlayer(playerid, zone, color, bordercolor = 0x00000060); native GangZoneSetColorForAll(playerid, zone, color, bordercolor = 0x00000060); native GangZoneFlashForPlayer(playerid, zone, flashcolor); native GangZoneFlashForAll(zone, flashcolor); native GangZoneStopFlashForPlayer(playerid, zone); native GangZoneStopFlashForAll(zone); native GangZoneSetInterior(zone, interior); native GangZoneGetInterior(zone); native GangZoneSetVirtualWorld(zone, virtualworld); native GangZoneGetVirtualWorld(zone); native CountAllGangZones(); native DestroyAllGangZones(); native ShowAllGangZonesForPlayer(playerid, color = -1, bordercolor = -1); native ShowAllGangZonesForAll(color = -1, bordercolor = -1); native HideAllGangZonesForPlayer(playerid); native HideAllGangZonesForAll(); native IsPlayerInGangZone(playerid, zone); native IsPlayerInAnyGangZone(playerid); native GetPlayerGangZone(playerid); |
public OnPlayerEnterGangZone(playerid, zone);
{
if IsPlayerInGangZone(playerid, G_zone1){
SendClientMessage(playerid,-1,"USA")
//uhmm?
}
return 1;
[PHP]
public OnPlayerLeaveGangZone(playerid, zone); //uhmm?
public OnPlayerEnterGangZone(playerid, zone); { switch(zone) { case G_zone1: { SendClientMessage(playerid,-1,"Joined USA Base!")( } } return 1; }
Thank you! it worK! +rep
EDIT : You must spread some Reputation around before giving it to Roberto80 again. :C |