don't push against oneway flow on roundabout. fixes #591
This commit is contained in:
		
							parent
							
								
									ae8e51074e
								
							
						
					
					
						commit
						cc55b016e9
					
				| @ -79,3 +79,9 @@ Feature: Bike - Accessability of different way types | ||||
|  		 | construction |      |         |       | | ||||
|  		 | construction | yes  |         |       | | ||||
|  		 | construction |      | yes     |       | | ||||
|          | ||||
|     @roundabout | ||||
|   	Scenario: Bike - Don't push bikes against oneway flow on roundabouts | ||||
|   	 	Then routability should be | ||||
|   		 | junction   | forw | backw | | ||||
|   		 | roundabout | x    |       | | ||||
|  | ||||
| @ -264,6 +264,7 @@ function way_function (way, numberOfNodesInWay) | ||||
| 	-- pushing bikes | ||||
| 	if bicycle_speeds[highway] or pedestrian_speeds[highway] then | ||||
| 	    if foot ~= 'no' then | ||||
| 	        if junction ~= "roundabout" then | ||||
|             	if way.direction == Way.oneway then | ||||
|             	    way.backward_speed = walking_speed | ||||
|                 elseif way.direction == Way.opposite then | ||||
| @ -271,6 +272,7 @@ function way_function (way, numberOfNodesInWay) | ||||
|                     way.speed = way.speed | ||||
|             	end | ||||
|             end | ||||
|         end | ||||
|         if way.backward_speed == way.speed then | ||||
|             -- TODO: no way yet to mark a way as pedestrian mode if forward/backward speeds are equal | ||||
|             way.direction = Way.bidirectional | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user