ACE3/addons/cookoff/CfgEden.hpp
Cyruz143 5d07029db7 Cookoff - Allow enabling only on player crewed vehicles (#7147)
* Add setting for cookoff to only run for player crewed vehicles

* No point having per vehicle selection

* Merging mutliple settings in to one

* Fixing missing comma

* Using LSTRING for settings

* merging suggested fixes

* Moving enabled check to fnc

* Use existing strings for CBA options

* Reverting change to support legacy eden attribute settings

* Adding Pabsts fix for 3den attribute

* Update addons/cookoff/CfgEden.hpp

Co-Authored-By: PabstMirror <pabstmirror@gmail.com>
2019-11-05 11:55:15 -06:00

32 lines
1.5 KiB
C++

class Cfg3DEN {
class Object {
class AttributeCategories {
class ace_attributes {
class Attributes {
class GVAR(enable) {
property = QGVAR(enable);
control = "Checkbox";
displayName = CSTRING(enable_hd_name);
tooltip = CSTRING(enable_hd_tooltip);
expression = QUOTE(if !(_value) then {_this setVariable [ARR_3('%s',_value,true)];};);
typeName = "BOOL";
condition = "objectVehicle";
defaultValue = QUOTE((GETMVAR(QGVAR(enable),0)) in [ARR_2(1,2)]);
};
class GVAR(enableAmmoCookoff) {
property = QGVAR(enableAmmoCookoff);
control = "Checkbox";
displayName = CSTRING(enableAmmoCookoff_name);
tooltip = CSTRING(enableAmmoCookoff_tooltip);
expression = QUOTE(if !(_value) then {_this setVariable [ARR_3('%s',_value,true)];};);
typeName = "BOOL";
condition = "objectHasInventoryCargo";
defaultValue = QUOTE(if (_this isKindOf 'ReammoBox_F') then { GETMVAR(QGVAR(enableAmmobox),true) } else { GETMVAR(QGVAR(enableAmmoCookoff),true) };);
};
};
};
};
};
};