From 388b00f58cbbf7a1566dce90d9e6a601efbed4d3 Mon Sep 17 00:00:00 2001 From: SzwedzikPL Date: Wed, 10 Feb 2016 01:38:14 +0100 Subject: [PATCH] remove unnecessary code, aesthetic tweak --- addons/cargo/CfgEventHandlers.hpp | 7 ------- addons/cargo/CfgVehicles.hpp | 6 +----- addons/dragging/CfgEventHandlers.hpp | 5 ----- addons/interaction/functions/fnc_switchLamp.sqf | 2 +- 4 files changed, 2 insertions(+), 18 deletions(-) diff --git a/addons/cargo/CfgEventHandlers.hpp b/addons/cargo/CfgEventHandlers.hpp index f2fbba9722..f65dc24e06 100644 --- a/addons/cargo/CfgEventHandlers.hpp +++ b/addons/cargo/CfgEventHandlers.hpp @@ -95,16 +95,9 @@ class Extended_InitPost_EventHandlers { init = QUOTE(_this call DFUNC(initObject)); }; }; - class Land_PortableLight_single_F { class ADDON { init = QUOTE(_this call DFUNC(initObject)); }; }; - - class Land_PortableLight_double_F { - class ADDON { - init = QUOTE(_this call DFUNC(initObject)); - }; - }; }; diff --git a/addons/cargo/CfgVehicles.hpp b/addons/cargo/CfgVehicles.hpp index 98ef458bf9..038bc52915 100644 --- a/addons/cargo/CfgVehicles.hpp +++ b/addons/cargo/CfgVehicles.hpp @@ -45,7 +45,7 @@ class CfgVehicles { description = CSTRING(MakeLoadable_description); typeName = "BOOL"; defaultValue = 1; - }; + }; class setSize { displayName = CSTRING(makeLoadable_setSize_displayName); typeName = "NUMBER"; @@ -491,8 +491,4 @@ class CfgVehicles { GVAR(size) = 1; GVAR(canLoad) = 1; }; - class Land_PortableLight_double_F: Land_PortableLight_single_F { - GVAR(size) = 1; - GVAR(canLoad) = 1; - }; }; diff --git a/addons/dragging/CfgEventHandlers.hpp b/addons/dragging/CfgEventHandlers.hpp index 15be3529a9..ca706f8427 100644 --- a/addons/dragging/CfgEventHandlers.hpp +++ b/addons/dragging/CfgEventHandlers.hpp @@ -32,11 +32,6 @@ class Extended_Init_EventHandlers { init = QUOTE(_this call DFUNC(initObject)); }; }; - class Land_PortableLight_double_F { - class ADDON { - init = QUOTE(_this call DFUNC(initObject)); - }; - }; }; class Extended_Killed_EventHandlers { diff --git a/addons/interaction/functions/fnc_switchLamp.sqf b/addons/interaction/functions/fnc_switchLamp.sqf index 23152b0468..20a2d45dea 100644 --- a/addons/interaction/functions/fnc_switchLamp.sqf +++ b/addons/interaction/functions/fnc_switchLamp.sqf @@ -29,7 +29,7 @@ private _hitPointsDamage = []; } count _reflectors; //if lamp is on turn it off -private _eventName = if(_isOn) then {"lampTurnOff"} else {"lampTurnOn"}; +private _eventName = ["lampTurnOn", "lampTurnOff"] select _isOn; if(local _lamp) then { [_eventName, [_lamp, _hitPointsDamage, DISABLED_LAMP_DMG]] call EFUNC(common,localEvent); } else {