Catenary Pylon Spacing for Road/Tramways

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

Moderator: Graphics Moderators

Post Reply
User avatar
supermop
Tycoon
Tycoon
Posts: 1104
Joined: 21 Feb 2010 00:15
Location: Fitzroy North - 96

Catenary Pylon Spacing for Road/Tramways

Post by supermop »

I am kind of curious as to the method by which catenary like Dutch Catenary is able to alternate pylon placement to be every 2nd tile. Dutch Catenary seems not to have its sources on devzone, and I couldn't find a dedicated forum topic for it. NML documentation mentions that there is a callback for catenary pylons, but doesn't explain how this may be selectively used by tile, or really mention any interesting features for catenary for that matter.

Further to learning how this works for railtypes, I am curious as to if it is also applicable to road and tramways, with or without NotRoadTypes (for example, can regular tramway have pylons every other tile)? Beyond that, is it possible to place pylons every 3rd or 4th tile?


Thanks!
User avatar
Quast65
Tycoon
Tycoon
Posts: 2654
Joined: 09 Oct 2011 13:51
Location: The Netherlands

Re: Catenary Pylon Spacing for Road/Tramways

Post by Quast65 »

the method by which catenary like Dutch Catenary is able to alternate pylon placement to be every 2nd tile.
Isnt that "normal" behaviour of the game? AFAIK all railcatenary has this behaviour and AFAIK all catenary sets are just simple graphics replacements. You can tweak the position a little bit (move it closer or further from the rails), but that may eventually result in glitching or problems with catenary on bridges.
Turning pylons off is AFAIK only possible for stationtiles (and waypoints), maybe that is the callback what the NML documentation refers to...

Therefor I think this can only be changed via a patch and not simply with a GRF.

Because I think pylonplacement depends on the x/y-position of the tile in the game. I believe that determines when and where pylons are placed, at least for the position along the railway (leftside/rightside). But maybe also when a start/end-tile of the line gets 2 or just 1 pylon on a single tile:
Example230.png
Example230.png (102.04 KiB) Viewed 1431 times
Maybe the devs can clear this up a bit more, about how this actually works. This information may indeed be handy for future patches (so, like making pylons get the same behaviour like signals, where you are able to control the spacing and left/right position. Maybe not exactly like signals, but a setting that you can set before starting a game, or railtype dependable). Or even making it possible to get pylons on both sides of a rail (making it possible to get gated catenary).

If this is possible at all (a big "if" ;-) ), I can imagine that it may take a while to work this out, however if this behaviour is the same for roadtypes, then it may be interesting for the developers of NotRoadTypes to look into this for tramways....
Projects: http://www.tt-forums.net/viewtopic.php?f=26&t=57266
Screenshots: http://www.tt-forums.net/viewtopic.php?f=47&t=56959
Scenario of The Netherlands: viewtopic.php?f=60&t=87604

Winner of the following screenshot competitions:
sep 2012, jan 2013, apr 2013, aug 2013, mar 2014, mar 2016, oct 2020
All my work is released under GPL-license (either V2 or V3), if not clearly stated otherwise.
User avatar
supermop
Tycoon
Tycoon
Posts: 1104
Joined: 21 Feb 2010 00:15
Location: Fitzroy North - 96

Re: Catenary Pylon Spacing for Road/Tramways

Post by supermop »

Quast65 wrote:
the method by which catenary like Dutch Catenary is able to alternate pylon placement to be every 2nd tile.
Isnt that "normal" behaviour of the game? AFAIK all railcatenary has this behaviour and AFAIK all catenary sets are just simple graphics replacements. You can tweak the position a little bit (move it closer or further from the rails), but that may eventually result in glitching or problems with catenary on bridges.
Turning pylons off is AFAIK only possible for stationtiles (and waypoints), maybe that is the callback what the NML documentation refers to...

Therefor I think this can only be changed via a patch and not simply with a GRF.

Because I think pylonplacement depends on the x/y-position of the tile in the game. I believe that determines when and where pylons are placed, at least for the position along the railway (leftside/rightside). But maybe also when a start/end-tile of the line gets 2 or just 1 pylon on a single tile:
Example230.png

Maybe the devs can clear this up a bit more, about how this actually works. This information may indeed be handy for future patches (so, like making pylons get the same behaviour like signals, where you are able to control the spacing and left/right position. Maybe not exactly like signals, but a setting that you can set before starting a game, or railtype dependable). Or even making it possible to get pylons on both sides of a rail (making it possible to get gated catenary).

If this is possible at all (a big "if" ;-) ), I can imagine that it may take a while to work this out, however if this behaviour is the same for roadtypes, then it may be interesting for the developers of NotRoadTypes to look into this for tramways....

Thanks for the insight, although it is starting to bode less well for applying this concept to tramways. Tramways have a set of sprites for catenary 'rear' (positioned behind vehicles) and 'front' (drawn over vehicles), but as far as I can tell, there is only one sprite in each for \ and / directions, and no separate sprites for pylon and wire - meaning it would be impossible currently to automatically omit a pylon on some tiles.
Post Reply

Return to “NewGRF Technical Discussions”

Who is online

Users browsing this forum: No registered users and 4 guests