From 669057477dea07c0e39c77765763df5a83cddb30 Mon Sep 17 00:00:00 2001 From: commy2 Date: Thu, 27 Dec 2018 14:03:42 +0100 Subject: [PATCH] delete conditional PREP, remove spawn --- addons/trenches/Cfg3DEN.hpp | 4 ++-- addons/trenches/XEH_PREP.hpp | 15 +++++++++------ 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/addons/trenches/Cfg3DEN.hpp b/addons/trenches/Cfg3DEN.hpp index 963666e3d18..3ccece4822a 100644 --- a/addons/trenches/Cfg3DEN.hpp +++ b/addons/trenches/Cfg3DEN.hpp @@ -1,8 +1,8 @@ class Cfg3DEN { class EventHandlers { class ADDON { - onMissionPreviewEnd = QUOTE([] spawn {waitUntil {!isNil QQFUNC(initTrench3DEN)}; call FUNC(initTrench3DEN)}); // Don't ask me why but this function is nil when this event triggers - onMissionLoad = QUOTE([] spawn {waitUntil {!isNil QQFUNC(initTrench3DEN)}; call FUNC(initTrench3DEN)}); // Don't ask me why but this function is nil when this event triggers + onMissionPreviewEnd = QUOTE(with uiNamespace do {call FUNC(initTrench3DEN)}); + onMissionLoad = QUOTE(with uiNamespace do {call FUNC(initTrench3DEN)}); }; }; }; diff --git a/addons/trenches/XEH_PREP.hpp b/addons/trenches/XEH_PREP.hpp index f9d61ce8f01..8f650a3d210 100644 --- a/addons/trenches/XEH_PREP.hpp +++ b/addons/trenches/XEH_PREP.hpp @@ -24,13 +24,16 @@ PREP(placeConfirm); PREP(placeTrench); PREP(removeCamouflage); PREP(removeTrench); +PREP(getSurfaceTexturePath); -if ("surfaceTexture" in (uiNamespace getVariable ["Intercept_cba_capabilities",[]])) then { - #ifdef DISABLE_COMPILE_CACHE - DFUNC(getSurfaceTexturePath) = compile preprocessFileLineNumbers QPATHTOF(functions\DOUBLES(fnc,getSurfaceTexturePathNative).sqf); - #else - [QPATHTOF(functions\DOUBLES(fnc,getSurfaceTexturePathNative).sqf), QFUNC(getSurfaceTexturePath)] call CBA_fnc_compileFunction; - #endif +/* @todo +if ("surfaceTexture" in (uiNamespace getVariable ["Intercept_cba_capabilities", []])) then { +#ifdef DISABLE_COMPILE_CACHE + DFUNC(getSurfaceTexturePath) = compile preprocessFileLineNumbers QPATHTOF(functions\DOUBLES(fnc,getSurfaceTexturePathNative).sqf); +#else + [QPATHTOF(functions\DOUBLES(fnc,getSurfaceTexturePathNative).sqf), QFUNC(getSurfaceTexturePath)] call CBA_fnc_compileFunction; +#endif } else { PREP(getSurfaceTexturePath); }; +*/