From 20cfb69fcfb89ccf816ae7e6d5e18894b6f6e065 Mon Sep 17 00:00:00 2001 From: Nou Date: Mon, 12 Jan 2015 18:08:45 -0800 Subject: [PATCH] Added DEFUNC, QFUNC, QEFUNC macros. --- addons/main/script_macros.hpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/addons/main/script_macros.hpp b/addons/main/script_macros.hpp index 7811c32337..be16f947ac 100644 --- a/addons/main/script_macros.hpp +++ b/addons/main/script_macros.hpp @@ -177,6 +177,10 @@ #define DGVAR(varName) if(isNil "ACE_DEBUG_NAMESPACE") then { ACE_DEBUG_NAMESPACE = []; }; if(!(QUOTE(GVAR(varName)) in ACE_DEBUG_NAMESPACE)) then { PUSH(ACE_DEBUG_NAMESPACE, QUOTE(GVAR(varName))); }; GVAR(varName) #define DVAR(varName) if(isNil "ACE_DEBUG_NAMESPACE") then { ACE_DEBUG_NAMESPACE = []; }; if(!(QUOTE(varName) in ACE_DEBUG_NAMESPACE)) then { PUSH(ACE_DEBUG_NAMESPACE, QUOTE(varName)); }; varName #define DFUNC(var1) TRIPLES(ADDON,fnc,var1) +#define DEFUNC(var1,var2) TRIPLES(DOUBLES(PREFIX,var1),fnc,var2) + +#define QFUNC(var1) QUOTE(DFUNC(var1)) +#define QEFUNC(var1,var2) QUOTE(DEFUNC(var1,var2)) #ifdef DISABLE_COMPILE_CACHE #define PREP(fncName) DFUNC(fncName) = compile preprocessFileLineNumbers QUOTE(PATHTOF(functions\DOUBLES(fnc,fncName).sqf))