FS#3947 - height information for bridge tiles sometimes wrong

Attached to Project: OpenTTD
Opened by Ingo von Borstel (planetmaker) - Wednesday, 14 July 2010, 13:08 GMT
Last edited by frosch (frosch) - Monday, 09 August 2010, 07:32 GMT
Type Bug
Category NewGRF
Status Closed
Assigned To No-one
Operating System All
Severity Low
Priority Normal
Reported Version trunk
Due in Version 1.1.0
Due Date Undecided
Percent Complete 100%
Votes 0
Private No


See the attached screenshot and look at the track on the indicated tracks on bridges. The red circled one should have no reason to be snowy - tiles below and at the same height are not indicated as snowy. The green indicated on on the other hand should be snowy, given the height of the foundations.

That it's to my knowledge not a problem with the newgrf itself show the bridges which are on foundations or one or two height levels lower than those where there are snowy sprites (newgrf attached).
This task depends upon

Closed by  frosch (frosch)
Monday, 09 August 2010, 07:32 GMT
Reason for closing:  Fixed
Additional comments about closing:  in r20420 to r20423
Comment by Ingo von Borstel (planetmaker) - Wednesday, 21 July 2010, 09:12 GMT
hm... this is the screenshots with the circles I talk about. Seems I got the wrong screenshot.
Comment by frosch (frosch) - Wednesday, 21 July 2010, 14:32 GMT
Some status report :)

Snowyness has been fixed for all tiles.
Remaining is only snowyness on bridges, and on bridgeheads.

For snow on bridges different methods were tried. They all result in the same problem.
The bridge and the track on the bridge is on a different height than the groundtile of the bridgeheads. So either
1) the track on the bridge has different snowyness compared to surrounding rail,
2) the groundtile of the bridgehead has different snowyness compared to surrounding groundtiles, or
3) the track on the bridgeramp has different snowyness than the groundtile. In this case, what snowyness shall the ramp itself get? (If bridgeheads would become newgrf configurable).

Note: Snowyness of bridgeheads is currently not foundation aware, but that is easy to fix if it the rules for snowyness itself are decided.
Comment by frosch (frosch) - Wednesday, 21 July 2010, 14:45 GMT
My current preference: The entrance edge of the bridgehead defines snowyness. That way the groundtile has the same snowyness than surrounding groundtiles, if it is flat and the track is sloped. And the track has the same snowyness as surrounding track, if the track is flat and the groundtile is sloped.
Comment by Ingo von Borstel (planetmaker) - Thursday, 22 July 2010, 12:07 GMT
I'd prefer the snowyness to have the same height dependence as normal ground tiles have, too: slopes snowy if a ground tile slope would be snowy and the horizontal tracks snowy, if a ground tile of the equivalent height would be snowy, too; this will lead to bridges where only the horizontal part is snowy and the slopes not - but a bump in the height level would be the same, so it is nicely consistent, especially if one considers bridges which have only one sloped bridge head - which is basically what frosch shows in his last png,