Add option to disable the upgrade of buildables

This commit is contained in:
A Man
2020-05-27 17:38:34 +02:00
parent 709078c69f
commit 4040b784b5
3 changed files with 5 additions and 4 deletions

View File

@@ -13,10 +13,10 @@ s_player_upgrade_build = 1;
_obj = _this select 3;
_objectID = _obj getVariable ["ObjectID","0"];
_objectUID = _obj getVariable ["ObjectUID","0"];
if (_objectID == "0" && {_objectUID == "0"}) exitWith {dayz_actionInProgress = false; s_player_upgrade_build = -1; localize "str_epoch_player_50" call dayz_rollingMessages;};
_classname = typeOf _obj;
if ((_objectID == "0" && {_objectUID == "0"}) || _classname in DZE_DisableUpgrade) exitWith {dayz_actionInProgress = false; s_player_upgrade_build = -1; localize "str_epoch_player_50" call dayz_rollingMessages;};
_text = getText (configFile >> "CfgVehicles" >> _classname >> "displayName");
_upgrade = getArray (configFile >> "CfgVehicles" >> _classname >> "upgradeBuilding");