Glitches with varying snow line height

Discussions about the technical aspects of graphics development, including NewGRF tools and utilities.

Moderator: Graphics Moderators

Post Reply
User avatar
planetmaker
OpenTTD Developer
OpenTTD Developer
Posts: 9432
Joined: 07 Nov 2007 22:44
Location: Sol d

Glitches with varying snow line height

Post by planetmaker »

I try to implement a newgrf which allows to set the snow line height in summer and winter and will vary it according to those two parameters.

Currently I do that in 7 discret steps, Jan, Feb, ... Jun, Jul, Jun, ... Feb
It works nicely, if I increase or decrease the snow line by one. But it starts to look really ugly, if I change it by more than one height level at once. Snow line height values as in the definition of it have to be - according to the specs - be mutliples of 8. That is observed as far as I could establish (sprite #36 allows testing it, sprites #37 + #38 actually define the snow line, sprites #12 - #35 calculate it from the parameters).

I'd be glad to receive pointers what's going wrong for increases of the snow line of more than one tile height between two months.

EDIT: the relevant wiki pages as far as I know:
http://wiki.ttdpatch.net/tiki-index.php ... t_table_10_
http://wiki.ttdpatch.net/tiki-index.php ... _height_97_
http://wiki.ttdpatch.net/tiki-index.php?page=Action6

EDIT2: The remaining snow in the screenshot are not tiles which have not been visited by the tile loop....

EDIT3: attached the grf file. Can someone test it with TTDPatch and tell me whether the results are similar to what is shown in the subsequent posting? If so, I'd rather see the wiki specs adjusted than the source of both games...

EDIT4: doh... :-( attached wrong newgrf. Sorry Eddi.
Attachments
Unbenannt, 01-05-1996.png
Unbenannt, 01-05-1996.png (88.93 KiB) Viewed 2695 times
snowlinemod.nfo
source NFO
(10.61 KiB) Downloaded 95 times
snowlinemod.grf
The grf file for testing. Mind that it's not allowed to distribute it in this form.
(2.62 KiB) Downloaded 96 times
Last edited by planetmaker on 30 Dec 2009 17:06, edited 3 times in total.
User avatar
planetmaker
OpenTTD Developer
OpenTTD Developer
Posts: 9432
Joined: 07 Nov 2007 22:44
Location: Sol d

Re: Glitches with varying snow line height

Post by planetmaker »

Hm... seems that only the tiles with a snow line one lower than the currently defined one are set dirty...
Attachments
mountain with snow line height changing by two
mountain with snow line height changing by two
a bit later
a bit later
Alberth
OpenTTD Developer
OpenTTD Developer
Posts: 4763
Joined: 09 Sep 2007 05:03
Location: home

Re: Glitches with varying snow line height

Post by Alberth »

Fixed in OpenTTD r18670
User avatar
planetmaker
OpenTTD Developer
OpenTTD Developer
Posts: 9432
Joined: 07 Nov 2007 22:44
Location: Sol d

Re: Glitches with varying snow line height

Post by planetmaker »

Hey, thanks! That was lightening quick :-)
Post Reply

Return to “NewGRF Technical Discussions”

Who is online

Users browsing this forum: No registered users and 22 guests