The International Simutrans Forum

Development => Patches & Projects => Incorporated Patches and Solved Bug Reports => Topic started by: Spacethingy on November 22, 2013, 09:04:22 PM

Title: [r6912] Strange city road generation near water
Post by: Spacethingy on November 22, 2013, 09:04:22 PM
Hey guys, booted up r6912 on Lubuntu (latest pak64 too) for the first time and this was the first thing that grabbed my attention:


(http://i.imgur.com/NyJHpY3.png)

(http://i.imgur.com/RhpPavn.png)

Also in other paks: (pak96)
(http://i.imgur.com/ZDv2j4o.png)

These images show generated city roads going mad when hitting water - both sea and lake - and building a tile of bridge for no apparent reason.
Title: Re: [r6912] Strange city road generation near water
Post by: prissi on November 22, 2013, 09:40:54 PM
Likely my new bridge code broke this. Thank you for reporting.

EDIT: Please try r6917 or higher.
Title: Re: [r6912] Strange city road generation near water
Post by: eipi on November 22, 2013, 09:56:20 PM
Hm, just noticed this is also true for city roads near rivers:
(https://dl.dropboxusercontent.com/u/53679800/Simutrans/river_bridge.png)

Another issue is that bridge ramps can be built over other ways:
(https://dl.dropboxusercontent.com/u/53679800/Simutrans/rail_bridge.png)

Title: Re: [r6912] Strange city road generation near water
Post by: prissi on November 22, 2013, 10:25:18 PM
Should be also fixed in r6920
Title: Re: [r6912] Strange city road generation near water
Post by: Dwachs on November 22, 2013, 10:27:59 PM
Still problems: one cannot connect bridge to elevated way. If one builds a rail bridge to a vertical cliff and there is a road on top with wrong direction a crossing is created nevertheless with wrong directions.
Title: Re: [r6912] Strange city road generation near water
Post by: prissi on November 22, 2013, 11:28:39 PM
The connection to any road on a cliff is intended; especially with tunnels or when there is a station, you need the autoconnections. It must check however, if it can connect (But that is the task of the bridgebuilder, the cliff should be always a valid end tile.)
Title: Re: [r6912] Strange city road generation near water
Post by: Dwachs on November 23, 2013, 09:55:56 AM
Still problems when creating bridges to cliffs with automatic generation of crossings:
(1) program crashes if required crossing type is not available
(2) crossings will be places regardless of the ribi of the existing way: crossings on curves, with two parallel ways etc
The checks in lines 172-200 in brueckenbauer.cc revision pre r6912 were there for a reason.
Title: Re: [r6912] Strange city road generation near water
Post by: prissi on November 24, 2013, 12:30:20 AM
My intention was to do not automatically build the way, but only when needed. But I see the problem, when I have two bridges connecting, a player has to click on the bridge to connect, which might be not very straight forward. Ok, I will add the checks again.

Still, a bridge directly connecting to a tunnel does not work without overbuilding. This I need to fix too.

EDIT: I hope I fixed it for good in r6935, because I will not look at a computer screen (well not mine at least) until Wednesday.