From 2aaef9e791f25f0a8506bb89f83b8e5751d9963c Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Mon, 11 Dec 2017 13:10:30 -0600 Subject: [PATCH] Fix some undefined funcs / strings (#5889) * fix missing respawn func / spectator string * fix readSettingsFromParamsArray, cleanup spec event * cleanup usless if statement --- addons/common/XEH_PREP.hpp | 1 + addons/common/functions/fnc_loadPersonLocal.sqf | 6 +++--- addons/rearm/CfgEventHandlers.hpp | 2 +- addons/spectator/XEH_postInit.sqf | 2 -- addons/spectator/config.cpp | 2 +- 5 files changed, 6 insertions(+), 7 deletions(-) diff --git a/addons/common/XEH_PREP.hpp b/addons/common/XEH_PREP.hpp index 907e4f0610..c2bbb322c1 100644 --- a/addons/common/XEH_PREP.hpp +++ b/addons/common/XEH_PREP.hpp @@ -4,6 +4,7 @@ PREP(cbaSettings); PREP(cbaSettings_loadFromConfig); PREP(cbaSettings_settingChanged); PREP(cbaSettings_transferUserSettings); +PREP(readSettingsFromParamsArray); PREP(actionKeysNamesConverted); PREP(addCanInteractWithCondition); diff --git a/addons/common/functions/fnc_loadPersonLocal.sqf b/addons/common/functions/fnc_loadPersonLocal.sqf index 90cbd7da03..f6a759add8 100644 --- a/addons/common/functions/fnc_loadPersonLocal.sqf +++ b/addons/common/functions/fnc_loadPersonLocal.sqf @@ -19,9 +19,9 @@ params ["_unit", "_vehicle", "_caller"]; -if (!alive _unit) then { - // _unit = [_unit, _caller] call FUNC(makeCopyOfBody); //func does not exist -}; +// if (!alive _unit) then { +// _unit = [_unit, _caller] call makeCopyOfBody; //func does not exist +// }; private _slotsOpen = false; diff --git a/addons/rearm/CfgEventHandlers.hpp b/addons/rearm/CfgEventHandlers.hpp index 1c715de8df..077779a642 100644 --- a/addons/rearm/CfgEventHandlers.hpp +++ b/addons/rearm/CfgEventHandlers.hpp @@ -28,7 +28,7 @@ class Extended_PostInit_EventHandlers { class Extended_Respawn_EventHandlers { class CAManBase { class ADDON { - respawn = QUOTE(call FUNC(XEH_respawn)); + respawn = QUOTE(call FUNC(handleRespawn)); }; }; }; diff --git a/addons/spectator/XEH_postInit.sqf b/addons/spectator/XEH_postInit.sqf index 462d036328..715dbe1c3d 100644 --- a/addons/spectator/XEH_postInit.sqf +++ b/addons/spectator/XEH_postInit.sqf @@ -24,8 +24,6 @@ if (isServer) then { }] call CBA_fnc_addEventHandler; }; -[QGVAR(stageSpectator), FUNC(stageSpectator)] call CBA_fnc_addEventHandler; - // A virtual spectator cannot exist without an interface if (hasInterface) then { // Local player (not ACE_Player) must be initalized to check diff --git a/addons/spectator/config.cpp b/addons/spectator/config.cpp index 3ff6000fdc..6daa59a752 100644 --- a/addons/spectator/config.cpp +++ b/addons/spectator/config.cpp @@ -21,7 +21,7 @@ class CfgPatches { class CfgRespawnTemplates { class ADDON { - displayName = CSTRING(DisplayName); + displayName = CSTRING(Module_DisplayName); onPlayerKilled = QFUNC(respawnTemplate); onPlayerRespawn = QFUNC(respawnTemplate); respawnTypes[] = {1,2,3,4,5};