Oneway road only using one side of road.
Moderator: OpenTTD Developers
-
- Engineer
- Posts: 9
- Joined: 26 Apr 2010 12:23
Oneway road only using one side of road.
I have a large number of trucks hauling raw material to a train station. I have to oneway roads, one going to the station, one from. Problem is the trucks only use one side of the oneway road and create a bottleneck. What am I doing wrong?
Re: Oneway road only using one side of road.
You're probably doing nothing wrong.
With one-way roads, road vehicles still drive on the driving side and only use the opposite side for overtaking, like on normal roads. The difference is that overtaking is easier because there is no opposing traffic on a one-way road.
You also must know that articulated vehicles (the ones that can only use drive-through stops) cannot overtake and therefore will always use only one side of the road, one-way or not.
With one-way roads, road vehicles still drive on the driving side and only use the opposite side for overtaking, like on normal roads. The difference is that overtaking is easier because there is no opposing traffic on a one-way road.
You also must know that articulated vehicles (the ones that can only use drive-through stops) cannot overtake and therefore will always use only one side of the road, one-way or not.
-
- Engineer
- Posts: 9
- Joined: 26 Apr 2010 12:23
Re: Oneway road only using one side of road.
That is what I thought. But when one truck stalls (breaks down) all the rest of the trucks just pile up behind it. Is there a fix to this?
Re: Oneway road only using one side of road.
no, this limitation is very deep in the code and cannot be fixed.
Re: Oneway road only using one side of road.
At the risk of getting shot down again, why can't the vehicle code detect that the vehicle in front which is broken down is going slowe rthan it and overtake based off of that?
If the 70mph van can see the 56mph lorry ahead and decide "That's 56mph. I'm 70mph. I'm faster. Overtake.", why not go "That's 0mph. I'm 70mph. I'm faster. Overtake."
If the 70mph van can see the 56mph lorry ahead and decide "That's 56mph. I'm 70mph. I'm faster. Overtake.", why not go "That's 0mph. I'm 70mph. I'm faster. Overtake."
Re: Oneway road only using one side of road.
Basically because the vehicle code is never taught to understand that.Deepsmeg wrote:why can't the vehicle code detect that the vehicle in front which is broken down
Probably not the answer you were looking for, but there you go

Re: Oneway road only using one side of road.
The road vehicle movement code could be changed to do that. It just need someone that is willing to rework the whole thing (right now it is very confusing) taking into account all possible corner cases and other missing stuff. For example, right now under some conditions road vehicles can drive through each other. Needless to say, this would not be a small task 

Spanish translation of OpenTTD
Extended heightmaps
Have fun, don't quarrel too much and add as many advanced settings as you can.
Extended heightmaps
Have fun, don't quarrel too much and add as many advanced settings as you can.
Re: Oneway road only using one side of road.
that's what vehicles already do, but there are more conditions:Deepsmeg wrote:At the risk of getting shot down again, why can't the vehicle code detect that the vehicle in front which is broken down is going slowe rthan it and overtake based off of that?
If the 70mph van can see the 56mph lorry ahead and decide "That's 56mph. I'm 70mph. I'm faster. Overtake.", why not go "That's 0mph. I'm 70mph. I'm faster. Overtake."
- there must be less than 3 vehicles [only me and the slower vehicle] around. this means articulated vehicles (that consist of 2 or more vehicles already) can never overtake or be overtaken.
- there may be no crossings, curves or stations nearby
- cannot be on a bridge
Re: Oneway road only using one side of road.
The gold standard would be having it recognise dual carriageways that have been made and having overtake based rules that'd allow a 70mph vehicle to pass a convoy of 56mph lorries
Why is overtaking not allowed on a bridge? Is that due to virtual road/portal stuff like tunnels?
For a potential quick win:
Can the 3 vehicle rule change?
Am I articulated (Am I more than 1 vehicle?)?
Yes, do not overtake.
No.
Am I on a 2way road?
Yes, usual behaviour.
No.
Look ahead. Would I have room to complete this overtake before hitting a junction,corner,L/C,station,etc?
Yes, overtake.
No, stay behind.
Why is overtaking not allowed on a bridge? Is that due to virtual road/portal stuff like tunnels?
For a potential quick win:
Can the 3 vehicle rule change?
Am I articulated (Am I more than 1 vehicle?)?
Yes, do not overtake.
No.
Am I on a 2way road?
Yes, usual behaviour.
No.
Look ahead. Would I have room to complete this overtake before hitting a junction,corner,L/C,station,etc?
Yes, overtake.
No, stay behind.
- Simons Mith
- Transport Coordinator
- Posts: 326
- Joined: 14 Jan 2010 23:45
Re: Oneway road only using one side of road.
How would the system behave if an RV breakdown set the vehicle's maximum speed and power to 1mph and 1hp for a short time rather than zero? (A bit like some of the advanced train breakdown mods I've seen.) Such a vehicle would presumably crawl along at an imperceptible pace for a few days, then recover, but because it hasn't 'broken down', merely suddenly become very very slow, maybe the game engine could cope with overtaking?
Re: Oneway road only using one side of road.
I once took a look on this. Started with bridges code only to realize that vehicles can't overtake at all on bridges at all. ^^ And somewhere then I found something else to occupy my time with.Terkhen wrote:The road vehicle movement code could be changed to do that. It just need someone that is willing to rework the whole thing (right now it is very confusing) taking into account all possible corner cases and other missing stuff. For example, right now under some conditions road vehicles can drive through each other. Needless to say, this would not be a small task
Edit: "took a look" = started to code on what might could have turned out as a solution, but for obvious reasons mentioned above, I couldn't get it to work :-p
My OpenTTD contributions (AIs, Game Scripts, patches, OpenTTD Auto Updater, and some sprites)
Junctioneer (a traffic intersection simulator)
Junctioneer (a traffic intersection simulator)
Re: Oneway road only using one side of road.
Now I'm using a nightly build, so I don't know where this would've been implemented or if it's a bug of some sort but I swear I've seen my RVs use the left lane to overtake both on bridges and in corners, and I also remember that it stayed in the left lane all the way until the bridge ended for some reason (the bridge was much longer then needed to overtake).Eddi wrote:
- there may be no crossings, curves or stations nearby
- cannot be on a bridge
Re: Oneway road only using one side of road.
indeed they do that, if they started the overtaking before the bridge, they continue on it
Who is online
Users browsing this forum: No registered users and 4 guests