diff --git a/SQF/dayz_code/compile/fn_selfActions.sqf b/SQF/dayz_code/compile/fn_selfActions.sqf index 619ec0136..0524493d1 100644 --- a/SQF/dayz_code/compile/fn_selfActions.sqf +++ b/SQF/dayz_code/compile/fn_selfActions.sqf @@ -414,14 +414,14 @@ if (!isNull _cursorTarget && !_inVehicle && !_isPZombie && (player distance _cur */ if (_isAlive) then { //Allow player to delete objects - if (_isDestructable || ((_typeOfCursorTarget in DZE_isWreck) or (_typeOfCursorTarget in DZE_isWreckBuilding)) || (_typeOfCursorTarget in DZE_isRemovable)) then { + if (_isDestructable || {((_typeOfCursorTarget in DZE_isWreck) or (_typeOfCursorTarget in DZE_isWreckBuilding))} || {(_typeOfCursorTarget in DZE_isRemovable)}) then { if (_hasToolbox && "ItemCrowbar" in _itemsPlayer) then { _player_deleteBuild = true; }; }; if (DZE_plotManagement || DZE_plotforLife) then { - if(_isModular || _isModularDoor) then { + if(_isModular || _isModularDoor || {_typeOfCursorTarget in DZE_isDestroyableStorage}) then { if(_hasToolbox && "ItemCrowbar" in _itemsPlayer) then { _isowner = [player, _cursorTarget, DZE_plotManagement] call FNC_check_owner; //compile also calls dze_getPlotFriends and lists s_player_plotManagement friendlies If ((_isowner select 0) || (_isowner select 1)) then { @@ -430,7 +430,7 @@ if (!isNull _cursorTarget && !_inVehicle && !_isPZombie && (player distance _cur }; }; } else { - if ((_isModularDoor || _isModular) && {_playerUID == _ownerID}) then { + if ((_isModularDoor || _isModular || _typeOfCursorTarget in DZE_isDestroyableStorage) && {_playerUID == _ownerID}) then { if (_hasToolbox && "ItemCrowbar" in _itemsPlayer) then { _player_deleteBuild = true; }; diff --git a/SQF/dayz_code/init/variables.sqf b/SQF/dayz_code/init/variables.sqf index 96f98ca54..48b9d62d7 100644 --- a/SQF/dayz_code/init/variables.sqf +++ b/SQF/dayz_code/init/variables.sqf @@ -491,6 +491,7 @@ DZE_isRemovable = ["Fence_corrugated_DZ","M240Nest_DZ","ParkBench_DZ","Plastic_P DZE_isWreck = ["SKODAWreck","HMMWVWreck","UralWreck","datsun01Wreck","hiluxWreck","datsun02Wreck","UAZWreck","Land_Misc_Garb_Heap_EP1","Fort_Barricade_EP1","Rubbish2"]; DZE_isWreckBuilding = ["Land_wreck_cinder","Land_wood_wreck_quarter","Land_wood_wreck_floor","Land_wood_wreck_third","Land_wood_wreck_frame","Land_iron_vein_wreck","Land_silver_vein_wreck","Land_gold_vein_wreck","Land_ammo_supply_wreck"]; DZE_isNewStorage = ["VaultStorage","OutHouse_DZ","Wooden_shed_DZ","WoodShack_DZ","StorageShed_DZ","GunRack_DZ","WoodCrate_DZ"]; +DZE_isDestroyableStorage = ["OutHouse_DZ","Wooden_shed_DZ","WoodShack_DZ","StorageShed_DZ","GunRack_DZ","WoodCrate_DZ"]; helperDetach = false; DZE_snapExtraRange = 0; if (isNil "DZE_plotOwnershipExclusions") then {