Adding safe/no fire zones

Having trouble in certain trading areas, or just want to give your players a rest?

Add this simple script to add a safe zone.

Credit for this Script belongs to Bake and tweaked by Rarek.

Installation :

1.Create a File with the Name "safezone.sqf" :

/* GrenadeStop v0.8 for ArmA 3 Alpha by Bake (tweaked slightly by Rarek) DESCRIPTION: Stops players from throwing grenades in safety zones. CONFIGURATION: Edit the #defines below.*/#define SAFETY_ZONES [["Safe_Kav", 25]] // Syntax: [["marker1", radius1], ["marker2", radius2], ...]#define MESSAGE "Granaten sowie Schießen ist auf dem Marktplatz ausgeschaltet!" if (isDedicated) exitWith {}; waitUntil {!isNull player};switch (playerSide) do{ case west: {}; case civilian: { player addEventHandler ["Fired", { if ({(_this select 0) distance getMarkerPos (_x select 0) < _x select 1} count SAFETY_ZONES > 0) then { deleteVehicle (_this select 6); titleText [MESSAGE, "PLAIN", 3]; }; }]; };};
2.Create in the Arma3 Editor a Marker at the Position where the Safezone would be.

3. At the top of the Script you can see "#define SAFETY_ZONES" there can you add the Safezone´s Marker Names.(The Syntax is at the Back).

#define SAFETY_ZONES [["Safe_Kav", 25]] // Syntax: [["marker1", radius1], ["marker2", radius2], ...]
Also you can see "#define MESSAGE" this can you change to the Text do you would say to the Guy who fired.

#define MESSAGE "Granaten sowie Schießen ist auf dem Marktplatz ausgeschaltet!"
4.To active this Script you need to add something to the Mission.sqm Init.sqf :

[] execVM "safezone.sqf";
Like this but you must have the right Path

5. In this Version of the Script Cops(Bluefor) can fire in the Savezone. To Change this Copy this to the Case West:

player addEventHandler ["Fired", {if ({(_this select 0) distance getMarkerPos (_x select 0) < _x select 1} count SAFETY_ZONES > 0) then{deleteVehicle (_this select 6);titleText [MESSAGE, "PLAIN", 3];};}];

Please see here for extended forum help http://www.altisliferpg.com/topic/2241- ... -function/
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Altis Life Dogs

If you wish to add a dog to your Arma 3 server you will first need to add an AI, there is an...

Altis Life prices

To change the prices of things in Altis Life you need to do the following;STOP the server and...

How to remove open cop slots

When you start playing Altis life, you will find that the first 4 cop slots are open to the...

Adding mods for Altis life 5.0

Adding mods for Altis life 5.0 can be more difficult that adding them for previous verions, as...