From f6d8625fcbb06deaa4e334e7ff1833df3002cc1a Mon Sep 17 00:00:00 2001 From: SilentSpike Date: Sat, 1 Aug 2015 12:55:33 +0100 Subject: [PATCH] Transfer zeus module fixes from master into hotfix --- addons/zeus/CfgVehicles.hpp | 4 ++++ addons/zeus/functions/fnc_moduleCaptive.sqf | 2 +- addons/zeus/functions/fnc_moduleSurrender.sqf | 2 +- addons/zeus/functions/fnc_moduleUnconscious.sqf | 4 ++-- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/addons/zeus/CfgVehicles.hpp b/addons/zeus/CfgVehicles.hpp index 79d4ff6f1f..77273c60b7 100644 --- a/addons/zeus/CfgVehicles.hpp +++ b/addons/zeus/CfgVehicles.hpp @@ -79,6 +79,10 @@ class CfgVehicles { class GVAR(moduleBase): Module_F { author = "SilentSpike"; category = "ACE"; + functionPriority = 1; + isGlobal = 1; + isTriggerActivated = 0; + scope = 1; scopeCurator = 2; }; class GVAR(moduleCaptive): GVAR(moduleBase) { diff --git a/addons/zeus/functions/fnc_moduleCaptive.sqf b/addons/zeus/functions/fnc_moduleCaptive.sqf index 41d515c2fc..43879a2a59 100644 --- a/addons/zeus/functions/fnc_moduleCaptive.sqf +++ b/addons/zeus/functions/fnc_moduleCaptive.sqf @@ -18,7 +18,7 @@ PARAMS_3(_logic,_units,_activated); private ["_mouseOver","_unit","_captive"]; -if (!_activated) exitWith {}; +if !(_activated && local _logic) exitWith {}; if (isNil QEFUNC(captives,setHandcuffed)) then { [LSTRING(RequiresAddon)] call EFUNC(common,displayTextStructured); diff --git a/addons/zeus/functions/fnc_moduleSurrender.sqf b/addons/zeus/functions/fnc_moduleSurrender.sqf index 8518e2f9ad..30ec8d8d35 100644 --- a/addons/zeus/functions/fnc_moduleSurrender.sqf +++ b/addons/zeus/functions/fnc_moduleSurrender.sqf @@ -18,7 +18,7 @@ PARAMS_3(_logic,_units,_activated); private ["_mouseOver","_unit","_surrendering"]; -if (!_activated) exitWith {}; +if !(_activated && local _logic) exitWith {}; if (isNil QEFUNC(captives,setSurrendered)) then { [LSTRING(RequiresAddon)] call EFUNC(common,displayTextStructured); diff --git a/addons/zeus/functions/fnc_moduleUnconscious.sqf b/addons/zeus/functions/fnc_moduleUnconscious.sqf index 529c8389ee..401fef2aa4 100644 --- a/addons/zeus/functions/fnc_moduleUnconscious.sqf +++ b/addons/zeus/functions/fnc_moduleUnconscious.sqf @@ -18,7 +18,7 @@ PARAMS_3(_logic,_units,_activated); private ["_mouseOver","_unit","_conscious"]; -if (!_activated) exitWith {}; +if !(_activated && local _logic) exitWith {}; if (isNil QEFUNC(medical,setUnconscious)) then { [LSTRING(RequiresAddon)] call EFUNC(common,displayTextStructured); @@ -38,7 +38,7 @@ if (isNil QEFUNC(medical,setUnconscious)) then { } else { _conscious = GETVAR(_unit,ACE_isUnconscious,false); // Function handles locality for me - [_unit, !_conscious, round(random(10)+5), true] call EFUNC(medical,setUnconscious); + [_unit, !_conscious, 10e10, true] call EFUNC(medical,setUnconscious); }; }; };