JGR's Patch Pack

Forum for technical discussions regarding development. If you have a general suggestion, problem or comment, please use one of the other forums.

Moderator: OpenTTD Developers

maxucao
Engineer
Engineer
Posts: 18
Joined: 18 Mar 2014 03:57

Re: JGR's Patch Pack

Post by maxucao »

Walter Novotny wrote: 14 Feb 2025 22:51
maxucao wrote: 14 Feb 2025 19:05 hi!!! anyone can guide or help me how do a more realistic simulation time?
i got Calendar timekeeping for default...so..i dont understand how slowing down the time...
thanks
Setting the number of ticks to 592 makes the train travel time realistic. Assuming 20 squares per kilometer, we get the travel time as in the real timetable. (I personally currently play on 296 ticks)
I have chosen the remaining settings experimentally, they allow for realistic acceleration of trains. This is necessary to obtain train travel times depending on the number of stops (expresses, suburban trains, etc.)

Image
Image
Thanks a lot!!!!!!!
User avatar
Redirect Left
Tycoon
Tycoon
Posts: 7404
Joined: 22 Jan 2005 19:31
Location: Wakefield, West Yorkshire

Re: JGR's Patch Pack

Post by Redirect Left »

I can't readily tell if this is related to the patch pack or not, but I will post it here in case there's any pathfinding differences, even minor ones, that may cause this. Then if its not PP related it can be reported to OTTD team if its not intentional for some reason.

I am having an issue where an irrelevant path being blocked, is not treated as being irrelevant, even though there's other routes that do not cross that reservation to start with.

Here, a train is partially blocking the entry to far left platform, but not to worry. There's lots of spare platforms that its ignoring.
1.png
(351.17 KiB) Not downloaded yet
If we delete the piece of track that connects the not-moving train to that platform, it suddenly remembers the other platforms exist.
2.png
(334.47 KiB) Not downloaded yet
Also, if the train is fully in platform 1, and not reserving the track piece in/out of it. It also remembers there is other platforms and uses them.
3.png
(1.7 MiB) Not downloaded yet
All platforms are of the same same length, and all are electrified, but for some reason the pathfinding appears to be giving up at the first blocked path, instead of going "...or we can test if we can go to the other places too".
Image
Need some good tested AI? - Unofficial AI Tester, list of good stuff & thread is here.
User avatar
JGR
Tycoon
Tycoon
Posts: 2599
Joined: 08 Aug 2005 13:46
Location: Ipswich

Re: JGR's Patch Pack

Post by JGR »

Redirect Left wrote: 18 Feb 2025 18:25 I can't readily tell if this is related to the patch pack or not, but I will post it here in case there's any pathfinding differences, even minor ones, that may cause this. Then if its not PP related it can be reported to OTTD team if its not intentional for some reason.

I am having an issue where an irrelevant path being blocked, is not treated as being irrelevant, even though there's other routes that do not cross that reservation to start with.

Here, a train is partially blocking the entry to far left platform, but not to worry. There's lots of spare platforms that its ignoring.
1.png
If we delete the piece of track that connects the not-moving train to that platform, it suddenly remembers the other platforms exist.
2.png
Also, if the train is fully in platform 1, and not reserving the track piece in/out of it. It also remembers there is other platforms and uses them.
3.png

All platforms are of the same same length, and all are electrified, but for some reason the pathfinding appears to be giving up at the first blocked path, instead of going "...or we can test if we can go to the other places too".
It's because the pathfinder cost for the single reserved track piece it has to cross is less than the extra pathfinder cost to get to the platforms further away.
Probably your best bet is to move the signal that the train at the top is waiting at 1 tile further away.
Ex TTDPatch Coder
Patch Pack, Github
User avatar
Redirect Left
Tycoon
Tycoon
Posts: 7404
Joined: 22 Jan 2005 19:31
Location: Wakefield, West Yorkshire

Re: JGR's Patch Pack

Post by Redirect Left »

JGR wrote: 18 Feb 2025 18:37 Probably your best bet is to move the signal that the train at the top is waiting at 1 tile further away.
I've moved the signal to behind the road, hopefully this will resolve it without adding too much extra dead time from signal to any platforms as my network is already pretty jammed (yay 5000 trains).
I kind of presumed the pathfinder would always notice there were more platforms at the same station available even if an extra but not massive amount of squares away, or after a certain amount of ticks would give up and go "...yeah that reservation is not happening, lets try something else" similar to how trains will eventually turn around at a signal if you have "automatic reversing at signals" enabled. With that pathfinder setup, I guess it massively limits how big you can even make platforms (or station spread) to begin with, regardless of how big the setting for station spread is, if it doesn't affect the logic of the pathfinder too.
Image
Need some good tested AI? - Unofficial AI Tester, list of good stuff & thread is here.
User avatar
JGR
Tycoon
Tycoon
Posts: 2599
Joined: 08 Aug 2005 13:46
Location: Ipswich

Re: JGR's Patch Pack

Post by JGR »

Redirect Left wrote: 18 Feb 2025 18:44
JGR wrote: 18 Feb 2025 18:37 Probably your best bet is to move the signal that the train at the top is waiting at 1 tile further away.
I've moved the signal to behind the road, hopefully this will resolve it without adding too much extra dead time from signal to any platforms as my network is already pretty jammed (yay 5000 trains).
I kind of presumed the pathfinder would always notice there were more platforms at the same station available even if an extra but not massive amount of squares away, or after a certain amount of ticks would give up and go "...yeah that reservation is not happening, lets try something else" similar to how trains will eventually turn around at a signal if you have "automatic reversing at signals" enabled. With that pathfinder setup, I guess it massively limits how big you can even make platforms (or station spread) to begin with, regardless of how big the setting for station spread is, if it doesn't affect the logic of the pathfinder too.
To clarify, I mean moving this signal by one tile, not the one by the level crossing.
Attachments
1.png
(497.05 KiB) Not downloaded yet
Ex TTDPatch Coder
Patch Pack, Github
User avatar
Redirect Left
Tycoon
Tycoon
Posts: 7404
Joined: 22 Jan 2005 19:31
Location: Wakefield, West Yorkshire

Re: JGR's Patch Pack

Post by Redirect Left »

JGR wrote: 18 Feb 2025 18:48 To clarify, I mean moving this signal by one tile, not the one by the level crossing.
Oh, moved that one now too. thank you for the advice!
Image
Need some good tested AI? - Unofficial AI Tester, list of good stuff & thread is here.
maxucao
Engineer
Engineer
Posts: 18
Joined: 18 Mar 2014 03:57

Re: JGR's Patch Pack

Post by maxucao »

hi!!! i still doesnt know how to program the signals..i read the manual but i dont understand..maybe produced by the diferent language
can someone give me a hand with this
https://ibb.co/ksCTk0Lw
i try to do the next

if the Signal in yellow circle activate o reserve the perpendicular railway next the signal 2 in black must be red

explain myself? i hope
Attachments
Pelayos & Co., 1915-07-30.png
(1.65 MiB) Not downloaded yet
SparkyMarkyR33
Engineer
Engineer
Posts: 11
Joined: 16 Feb 2020 17:18

Re: JGR's Patch Pack

Post by SparkyMarkyR33 »

maxucao wrote: 01 Mar 2025 03:42 hi!!! i still doesnt know how to program the signals..i read the manual but i dont understand..maybe produced by the diferent language
can someone give me a hand with this
https://ibb.co/ksCTk0Lw
i try to do the next

if the Signal in yellow circle activate o reserve the perpendicular railway next the signal 2 in black must be red

explain myself? i hope
The only option I would know, is to select the next signal AFTER the yellow circle signal (the one between the 2 depots) and put in routing restrictions - not program signals. Click the 'End' text in the box, it should highlight. On the bottom left of the window click INSERT, Select 'if' and then hit UNDIFINED, specify that if 'current order' is going to a station/waypoint down the single line (over the red bridge), click 'Select Target' and choose the station/waypoint. Once you do that you need to give it an action to take. Click 'End if' just below that line, click INSERT again, then 'reserve through' which will cause the black signal to not allow a train through if a train gets to the yellow signal first.

What this will do is treat the yellow signal as the only signal between the train and the junction if the train diverges to the single line. you can do this for numerous signals before a junction to allow a faster train have higher priority.
Alternatively select 'Long reserve' will do the same if no other train is blocking the junction before the yellow signal is triggered, but if there is, the train will pull up to the signal between the depots without stopping at the yellow signal beforehand. Hope that makes sense?
User avatar
ColdIce
Transport Coordinator
Transport Coordinator
Posts: 314
Joined: 25 Apr 2006 10:22
Location: Bucharest

Re: JGR's Patch Pack

Post by ColdIce »

Hi JGR,

Is there a possibility to get town names on a topography screenshot? It's useful for large maps when I edit topography screenshots in Photoshop.
The rest is confetti!
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: Bing [Bot] and 4 guests