From 7f80557c6b63673df06a6b375418b3636241678e Mon Sep 17 00:00:00 2001 From: HARLAN Date: Fri, 13 Dec 2013 14:12:36 -0500 Subject: [PATCH] #894 allow tanktraps on road, global toggle on road building DZE_BuildOnRoads toggle (default False) --- SQF/dayz_code/actions/player_build.sqf | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/SQF/dayz_code/actions/player_build.sqf b/SQF/dayz_code/actions/player_build.sqf index f0320cd47..e25b2a0e0 100644 --- a/SQF/dayz_code/actions/player_build.sqf +++ b/SQF/dayz_code/actions/player_build.sqf @@ -372,8 +372,10 @@ if (_hasrequireditem) then { }; }; - // No building on roads - if (isOnRoad _position) then { _cancel = true; _reason = "Cannot build on a road."; }; + // No building on roads for most items + if (!DZE_BuildOnRoads) then { + if ((isOnRoad _position) and (_classname!="Hedgehog_DZ")) then { _cancel = true; _reason = "Cannot build on a road."; }; + }; // No building in trader zones if(!canbuild) then { _cancel = true; _reason = "Cannot build in a city."; };