Private ["_EH_Fired"];
if (isNil "inSafezone") then {
inSafezone = false;
};
if (isNil "demiGOD") then {
demiGOD = 0;
};
while {true} do {
waitUntil { inSafeZone };
titleText [format["Entering Safe Zone. Your weapons have been deactivated."],"PLAIN DOWN"]; titleFadeOut 4;
waitUntil { player == vehicle player };
thePlayer = vehicle player;
_EH_Fired = thePlayer addEventHandler ["Fired", {
titleText ["Don't waste your ammo, your shootin blanks.","PLAIN DOWN"]; titleFadeOut 4;
NearestObject [_this select 0,_this select 4] setPos[0,0,0];
}];
if (demiGOD == 0) then {
player_zombieCheck = {};
fnc_usec_damageHandler = {};
fnc_usec_unconscious = {};
thePlayer removeAllEventHandlers "handleDamage";
thePlayer addEventHandler ["handleDamage", {false}];
thePlayer allowDamage false;
};
waitUntil { !inSafeZone };
titleText [format["Exiting Safe Zone. Your weapons have been reactivated."],"PLAIN DOWN"]; titleFadeOut 4;
thePlayer removeEventHandler ["Fired", _EH_Fired];
if (demiGOD == 0) then {
player_zombieCheck = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\player_zombieCheck.sqf";
fnc_usec_damageHandler = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\fn_damageHandler.sqf";
fnc_usec_unconscious = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\fn_unconscious.sqf";
thePlayer addEventHandler ["handleDamage", {true}];
thePlayer removeAllEventHandlers "handleDamage";
thePlayer allowDamage true;
};
};
Currently this gives the player 'God Mode' and Disables the damage of the bullets you fire. What I'm looking for is a addition of the script that will delete/teleport/remove zombies from the zone.
Question
mysticviperx
This is my current Safe Zones Script:
Currently this gives the player 'God Mode' and Disables the damage of the bullets you fire. What I'm looking for is a addition of the script that will delete/teleport/remove zombies from the zone.
Link to comment
Share on other sites
2 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now