-
-
Notifications
You must be signed in to change notification settings - Fork 968
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Road and Tramway Catenary Drawn Incorrectly / Unsorted #8647
Comments
Maybe it would be most expedient to just ignore bounding boxes and force all catenary_back sprites to be drawn under any vehicles? |
As a reminder to who-ever picks this up: some GRFs, like |
I gave it a spin to fix, as can been seen by the above PR, but .. I found out that there are some .. special choices made for trams :) Basically, some sprites in OpenGFX have pylons on both sides of the track. In general, for isometric games, if you have a single sprite that has to go both over and under another sprite, there is no correct way of sorting that. Unless OpenTTD has tricks up its sleeve to deal with these situations (my knowledge about this is severely lacking, so I hope someone else can fill in that gap), there is no answer to this problem. So I am afraid you will have to deal with this problem a bit longer ... sorry :( Edit: okay, gathered more information. Turns out the idea is that the back sprite draws the pylons, but the front sprite does this again for the pylons in the front. This is currently not done in OpenGFX, which was confusing me. It is fine that the back sprite has the pylon too, of course, but the front sprite should at least have it. Otherwise it is indeed an impossible situation for sorting .. but if the idea is that both have them, nothing is wrong here. It is just that OpenGFX got it wrong. |
The back sprite is now supposed to contain west, north and east pillars. The front sprite is supposed to contain the south pillar and the wires.
Version of OpenTTD
1.10.3
Expected result
"Rear" Catenary sprites are drawn behind other items, such as vehicles.
Actual result
The rear sprites are drawn over any vehicle on the tile, leading to poles, etc. appearing over the vehicle. As Road/tram catenary has no means of defining a bounding box size or position, there is no means the draw the sprites in the correct order.
Providing for bounding boxes, or forcing the "rear" sprite to always be under all others would fix this.
Steps to reproduce
The text was updated successfully, but these errors were encountered: