From b57f731dd06facd0531685ac3d753e66252badd6 Mon Sep 17 00:00:00 2001 From: commy2 Date: Sat, 9 May 2015 04:59:10 +0200 Subject: [PATCH] disable laserpointer inheritance for rhs --- .../laserpointer/functions/fnc_switchLaserLightMode.sqf | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/addons/laserpointer/functions/fnc_switchLaserLightMode.sqf b/addons/laserpointer/functions/fnc_switchLaserLightMode.sqf index f996d6b270..423090796f 100644 --- a/addons/laserpointer/functions/fnc_switchLaserLightMode.sqf +++ b/addons/laserpointer/functions/fnc_switchLaserLightMode.sqf @@ -29,11 +29,17 @@ _pointer = switch (_weapon) do { if (_pointer == "") exitWith {}; +private "_config"; +_config = configFile >> "CfgWeapons" >> _pointer; + private "_nextPointer"; -_nextPointer = getText (configFile >> "CfgWeapons" >> _pointer >> "ACE_nextModeClass"); +_nextPointer = getText (_config >> "ACE_nextModeClass"); if (_nextPointer == "") exitWith {}; +// disable inheritance for this entry, because addons claim this as a base class for convenience +if !((_config >> "ACE_nextModeClass") in configProperties [_config, "true", false]) exitWith {}; + private ["_description", "_picture"]; _description = getText (configFile >> "CfgWeapons" >> _nextPointer >> "ACE_modeDescription");