Zeus Actions - Fix config code breaking during build (#6864)

* Zeus Actions - Fix config code breaking during build

* Update addons/rearm/XEH_preInit.sqf

Co-Authored-By: PabstMirror <pabstmirror@gmail.com>

* formating, add note
This commit is contained in:
PabstMirror 2019-03-14 09:17:34 -05:00 committed by GitHub
parent b4639ed758
commit 57db905f7c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 18 additions and 8 deletions

View File

@ -54,7 +54,7 @@ class ACE_ZeusActions {
displayName = "$STR_repair"; displayName = "$STR_repair";
icon = "\A3\ui_f\data\igui\cfg\actions\repair_ca.paa"; icon = "\A3\ui_f\data\igui\cfg\actions\repair_ca.paa";
condition = QUOTE(ZEUS_ACTION_CONDITION && {-1 < (curatorSelected select 0) findIf {_x isKindOf 'AllVehicles' && {!(_x isKindOf 'Man')}}}); condition = QUOTE(ZEUS_ACTION_CONDITION && {-1 < (curatorSelected select 0) findIf {_x isKindOf 'AllVehicles' && {!(_x isKindOf 'Man')}}});
statement = QUOTE({if (_x isKindOf 'AllVehicles' && {!(_x isKindOf 'Man')}) then {_x setDamage 0}} forEach (curatorSelected select 0)); statement = QUOTE(call FUNC(repair_Statement));
}; };
}; };

View File

@ -6,4 +6,11 @@ PREP_RECOMPILE_START;
#include "XEH_PREP.hpp" #include "XEH_PREP.hpp"
PREP_RECOMPILE_END; PREP_RECOMPILE_END;
DFUNC(repair_Statement) = { // moved from config because of build problems
TRACE_1("repair_Statement",_this);
{
if (_x isKindOf 'AllVehicles' && {!(_x isKindOf 'Man')}) then { _x setDamage 0; };
} forEach (curatorSelected select 0)
};
ADDON = true; ADDON = true;

View File

@ -4,13 +4,7 @@ class ACE_ZeusActions {
displayName = CSTRING(Rearm); displayName = CSTRING(Rearm);
icon = QPATHTOF(ui\icon_rearm_interact.paa); icon = QPATHTOF(ui\icon_rearm_interact.paa);
condition = QUOTE(ZEUS_ACTION_CONDITION && {-1 < (curatorSelected select 0) findIf {_x isKindOf 'AllVehicles' && {!(_x isKindOf 'Man')}}}); condition = QUOTE(ZEUS_ACTION_CONDITION && {-1 < (curatorSelected select 0) findIf {_x isKindOf 'AllVehicles' && {!(_x isKindOf 'Man')}}});
statement = QUOTE( \ statement = QUOTE(call FUNC(rearm_statement));
{ \
if (_x isKindOf 'AllVehicles' && {!(_x isKindOf 'Man')}) then { \
[ARR_2(objNull,_x)] call ace_rearm_fnc_rearmEntireVehicleSuccess; \
}; \
} forEach (curatorSelected select 0); \
);
}; };
}; };
}; };

View File

@ -8,4 +8,13 @@ PREP_RECOMPILE_END;
#include "initSettings.sqf" #include "initSettings.sqf"
DFUNC(rearm_statement) = { // moved from config because of build problems
TRACE_1("rearm_statement",_this);
{
if (_x isKindOf 'AllVehicles' && {!(_x isKindOf 'Man')}) then {
[objNull, _x] call FUNC(rearmEntireVehicleSuccess);
};
} forEach (curatorSelected select 0);
};
ADDON = true; ADDON = true;