Blacklist steps from the car profile

This commit is contained in:
Patrick Niklaus
2017-02-07 11:03:48 +00:00
committed by Patrick Niklaus
parent ef4d32a492
commit ae835cc04f
3 changed files with 15 additions and 1 deletions
+2 -1
View File
@@ -91,7 +91,8 @@ local profile = {
'toll',
'reversible',
'impassable',
'hov_lanes'
'hov_lanes',
'steps'
},
speeds = Sequence {
+5
View File
@@ -437,6 +437,11 @@ function Handlers.handle_blocked_ways(way,result,data,profile)
return false
end
-- don't route over steps
if profile.avoid.steps and data.highway == "steps" then
return false
end
-- construction
-- TODO if highway is valid then we shouldn't check railway, and vica versa
if profile.avoid.construction and (data.highway == 'construction' or way:get_value_by_key('railway') == 'construction') then