This commit is contained in:
Siarhei Fedartsou
2022-10-27 21:13:57 +02:00
parent 16685d0de9
commit 8a4af59838
23 changed files with 401 additions and 14 deletions
+23
View File
@@ -0,0 +1,23 @@
local GiveWay = {}
function GiveWay.get_value(node)
local tag = node:get_value_by_key("highway")
if "give_way" == tag then
local direction = node:get_value_by_key("direction")
if direction then
if "forward" == direction then
return give_way.direction_forward
end
if "backward" == direction then
return give_way.direction_reverse
end
end
-- return give_way.direction_all
return true
end
-- return give_way.none
return false
end
return GiveWay
+21
View File
@@ -0,0 +1,21 @@
local StopSign = {}
function StopSign.get_value(node)
local tag = node:get_value_by_key("highway")
if "stop" == tag then
local direction = node:get_value_by_key("direction")
if direction then
if "forward" == direction then
return stop_sign.direction_forward
end
if "backward" == direction then
return stop_sign.direction_reverse
end
end
return stop_sign.direction_all
end
return stop_sign.none
end
return StopSign