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

p4nzer
Engineer
Engineer
Posts: 31
Joined: 27 Jun 2017 21:43

Re: JGR's Patch Pack

Post by p4nzer »

Hello,

Would it be possible to display the "cancelled" message on the departure boards if a train misses its dispatch slot? That would be nice both for realism and to help me track my missed trips.

Thanks!
User avatar
OzTrans
Tycoon
Tycoon
Posts: 1675
Joined: 04 Mar 2005 01:07

Re: JGR's Patch Pack

Post by OzTrans »

ino wrote: 20 Jan 2023 04:37 Because it takes a while for snow to fall and build-up on the depot? ...
You lot may think this is funny, it is not ...

It is the same issue in OpenTTD v12.2.

When building a road depot, upon completion, variables 0x43 (construction date) and 0x44 (town zone) get updated immediately. But 0x40 (terrain) is not, you have to wait 3 to 4 days for that to happen. I call this a bug ...

This is not an isolated case, there are worse ones too.

For example : Feature Houses

The following does work properly if a 'House' is being constructed during GAME PLAY, but it does not during GAME START.

When a 'House' is built (placed on the map) during game start. Animation stays silent until the first time interval (animation speed 0x1B) has passed, only then will callback 0x1B be triggered.

None of the animation callbacks (0x1A, 0x1B or 0x1C [if defined]) have something to say until then; this is 15 minutes (or 1.2 game years) in my case.

You would expect at least one of the above mentioned callbacks get triggered as soon as the 'House' is on the map in its full glory, so that I can abuse the animation frame to store the road orientation and to avoid that buildings are jumping 15 minutes later.

I have now implemented an unsatisfactory workaround; during the first 15 minutes of the game (until callback 0x1B gets triggered) : Every 'House' will get its road orientation checked and determined every time the 'House' gets (re)displayed. That is a lot of resources wasted.

Can we have at least one of the callbacks triggered immediately after the 'House' is on the map; i.e.

. Next Animation Frame (0x1A)
. Animation Control (0x1B)
. Construction State Change (0x1C)

... just one will do.

Of course, it would be nice to have an equivalent to train property 0x25, vehicle variable 0x42, a callback and all in a DWord, so we can store vital information whenever appropriate. This should be available for every feature, thus we wouldn't have to abuse the animation frame.

Thank you for your attention ...
Eddi
Tycoon
Tycoon
Posts: 8257
Joined: 17 Jan 2007 00:14

Re: JGR's Patch Pack

Post by Eddi »

OzTrans wrote: 20 Jan 2023 22:03But 0x40 (terrain) is not, you have to wait 3 to 4 days for that to happen. I call this a bug ...
no. again. this is intended behaviour. it has been since original TDD.
Denswillow
Engineer
Engineer
Posts: 25
Joined: 01 May 2016 12:56

Re: JGR's Patch Pack

Post by Denswillow »

Hey JGR, is it possible to add setting to individually enable or even select town growth speed on per-town-basis? It would allow me to only have a few towns growing but keep the rest of the towns stable population-wise. The current override setting would allow that playstyle, but would require turning off town growth on every town one by one.
Eddi
Tycoon
Tycoon
Posts: 8257
Joined: 17 Jan 2007 00:14

Re: JGR's Patch Pack

Post by Eddi »

you can do that with a gamescript

for example, you can place signs on the map, the gamescript reads those signs, and then decides to enable or disable town growth for this town.
Denswillow
Engineer
Engineer
Posts: 25
Joined: 01 May 2016 12:56

Re: JGR's Patch Pack

Post by Denswillow »

Eddi wrote: 21 Jan 2023 18:29 you can do that with a gamescript

for example, you can place signs on the map, the gamescript reads those signs, and then decides to enable or disable town growth for this town.
Yes, in theory, but to my knowledge there isn't any script that currently does that. I have actually tried to write one AI but never succeeded to get the game to recognize it, and haven't tried it since. So making one myself is out of the question.
(And I'm sorry if I seem rude or demanding, English is not my native language)
LaChupacabra
Route Supervisor
Route Supervisor
Posts: 385
Joined: 08 Nov 2019 23:54

Re: JGR's Patch Pack

Post by LaChupacabra »

Denswillow wrote: 21 Jan 2023 17:42 is it possible to add setting to individually enable or even select town growth speed on per-town-basis? It would allow me to only have a few towns growing but keep the rest of the towns stable population-wise.
Have you tried the City Growth Limiter script? It adds two conditions for the development of cities. In order for cities to grow, you need to transport the right amount of passengers and mail generated by that city. You can set the limit very low and then it's enough that you don't transport any of the loads or you transport them in small amounts, and the city won't grow. This script also allows you to limit the infinite growth of cities and does not allow cities to grow on their own. :)
City Growth Limiter script.png
City Growth Limiter script.png (83.91 KiB) Viewed 2835 times
You can still adjust the development speed by the number of supported stations. 1- the slowest, 5 or more - the fastest ;)
I am sorry for may English. I know is bed.
Denswillow
Engineer
Engineer
Posts: 25
Joined: 01 May 2016 12:56

Re: JGR's Patch Pack

Post by Denswillow »

LaChupacabra wrote: 22 Jan 2023 09:59
Denswillow wrote: 21 Jan 2023 17:42 is it possible to add setting to individually enable or even select town growth speed on per-town-basis? It would allow me to only have a few towns growing but keep the rest of the towns stable population-wise.
Have you tried the City Growth Limiter script? It adds two conditions for the development of cities. In order for cities to grow, you need to transport the right amount of passengers and mail generated by that city. You can set the limit very low and then it's enough that you don't transport any of the loads or you transport them in small amounts, and the city won't grow. This script also allows you to limit the infinite growth of cities and does not allow cities to grow on their own. :)

City Growth Limiter script.png

You can still adjust the development speed by the number of supported stations. 1- the slowest, 5 or more - the fastest ;)
I know about that gamescript, and I have used it sometimes(mostly Villages is Villages though, as it also requires goods/food for town growth). It still doesn't completely give me the freedom to have a full coverage of mail and passengers everywhere, but only grow a select few towns or urban areas.
LaChupacabra
Route Supervisor
Route Supervisor
Posts: 385
Joined: 08 Nov 2019 23:54

Re: JGR's Patch Pack

Post by LaChupacabra »

This is just my personal opinion, but I'm not convinced by the idea where it would be possible to arbitrarily decide which city can and cannot develop. I prefer a more spontaneous and free-market approach, so I think it's better if the development of cities depends on some external factor. For example, if you would like to retain complete freedom in transporting passengers and mail, the development of cities could depend on whether you deliver goods or food or building materials to them. It is still possible to create a script that could determine the development of cities based on this. It could work on the principle that the more you deliver, the faster it will grow, or simply the city will grow if you deliver whatever in 1, 3 or even 12 months. All in all, I would even like such a function that improves the logic of city development to be added even to the basic version of the game. However, the biggest problem seems to be not so much creating such a function, but choosing the best one. Everyone will have a different opinion, or even a few opinion, so I guess scripts will remain the only way. But who knows, maybe JGR will create something interesting. :))
I am sorry for may English. I know is bed.
Oakman
Engineer
Engineer
Posts: 47
Joined: 15 Jul 2016 20:26

Re: JGR's Patch Pack

Post by Oakman »

Hi!

has anyone an idea why the latest version (win64) just won't start at my system (win10)? Clicking on the .exe just causes nothing. Virustotal was as negative as it can be (https://www.virustotal.com/gui/file/fe7 ... ?nocache=1)
User avatar
kamnet
Moderator
Moderator
Posts: 8548
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: JGR's Patch Pack

Post by kamnet »

Oakman wrote: 25 Jan 2023 17:11 Hi!

has anyone an idea why the latest version (win64) just won't start at my system (win10)? Clicking on the .exe just causes nothing. Virustotal was as negative as it can be (https://www.virustotal.com/gui/file/fe7 ... ?nocache=1)
Make sure you downloaded the correct Win64 version. "openttd-jgrpp-0.50.2-windows-win64.zip" would be for normal Intel/AMD/x86 processors, but "openttd-jgrpp-0.50.2-windows-arm64.zip" would be for systems that are running on ARM processors (not common, you'd know if you have one though).
Oakman
Engineer
Engineer
Posts: 47
Joined: 15 Jul 2016 20:26

Re: JGR's Patch Pack

Post by Oakman »

kamnet wrote: 25 Jan 2023 21:17
Oakman wrote: 25 Jan 2023 17:11 Hi!

has anyone an idea why the latest version (win64) just won't start at my system (win10)? Clicking on the .exe just causes nothing. Virustotal was as negative as it can be (https://www.virustotal.com/gui/file/fe7 ... ?nocache=1)
Make sure you downloaded the correct Win64 version. "openttd-jgrpp-0.50.2-windows-win64.zip" would be for normal Intel/AMD/x86 processors, but "openttd-jgrpp-0.50.2-windows-arm64.zip" would be for systems that are running on ARM processors (not common, you'd know if you have one though).
I copied the contend of the archive into the existing folder and then it seems that windows defender messed up something because I get no notification at the first start. Once I used a new folder everything went fine. Thanks for the quick answer!
Argus
Tycoon
Tycoon
Posts: 1203
Joined: 16 Oct 2018 08:31
Location: Heart of the Highlands. Not Scottish. Czech.

Re: JGR's Patch Pack

Post by Argus »

I ran into some strange behavior that seems to be a bug. I'll start the scenario in, say, 1950. I want to see when certain things will be available, so I'll save the game and put the year through the cheat, like 2100, when everything should be available. No, the vehicle lists will remain the same.
It only happens if I enter a year where no new vehicle appears. As soon as I put like 1980, the cheat works.
Eddi
Tycoon
Tycoon
Posts: 8257
Joined: 17 Jan 2007 00:14

Re: JGR's Patch Pack

Post by Eddi »

is that behaviour different in the base game?
Argus
Tycoon
Tycoon
Posts: 1203
Joined: 16 Oct 2018 08:31
Location: Heart of the Highlands. Not Scottish. Czech.

Re: JGR's Patch Pack

Post by Argus »

No, it behaves the same in version 13 RC1. I don't have another version here.
User avatar
OzTrans
Tycoon
Tycoon
Posts: 1675
Joined: 04 Mar 2005 01:07

Re: JGR's Patch Pack

Post by OzTrans »

Argus wrote: 26 Jan 2023 15:43 I ran into some strange behaviour that seems to be a bug. I'll start the scenario in, say, 1950. I want to see when certain things will be available, so I'll save the game and put the year through the cheat, like 2100, when everything should be available. No, the vehicle lists will remain the same. ...
This may have something to do with this (quote from vehicle specs) :

Code: Select all

Note that TTD stops updating vehicle type data after the game ends in 2050, so all dates
of introduction should be no later than in 2044, to ensure that all vehicle types can be introduced
and reach their maximum reliability
Just jump to a year no later than 2049 and things will work for you.
Eddi
Tycoon
Tycoon
Posts: 8257
Joined: 17 Jan 2007 00:14

Re: JGR's Patch Pack

Post by Eddi »

Note that the strict year limit of 2050 has been removed from OpenTTD, and instead some years after the last new vehicle was introduced is used instead

however, the original intention behind my question was that if the behaviour is the same in the base game, then the bug should be raised in the official bug tracker on github
sjiveru
Engineer
Engineer
Posts: 23
Joined: 02 Nov 2018 06:54

Re: JGR's Patch Pack

Post by sjiveru »

I'm having some odd behaviour with cities not growing when I fully expect them to grow. I've posted about this elsewhere, but since I'm not sure if this is a general issue or a JGRPP issue, I'm uploading the save here as well.
Pilkington & Co., 1908-12-11.sav
(591.4 KiB) Downloaded 34 times
Look particularly at Yamatoyama and Nagaichi, two nearly identical towns with identical service where one town is consistently growing and the other is consistently not. Elsewhere nearby I have much larger cities - e.g. Mito, Sakura - that are not growing at all despite regular service at apparently sufficiently nearby stations. From what people have said so far, every vanilla growth mechanic indicates these towns should well be growing.

What is going on here? Does JGRPP change the requirements for town growth in such a way that it causes some of these towns to fail to grow when they seem no different from towns that are growing?
Argus
Tycoon
Tycoon
Posts: 1203
Joined: 16 Oct 2018 08:31
Location: Heart of the Highlands. Not Scottish. Czech.

Re: JGR's Patch Pack

Post by Argus »

You already have new replies in the original topic :) It's not related to the patchpack.
User avatar
JGR
Tycoon
Tycoon
Posts: 2557
Joined: 08 Aug 2005 13:46
Location: Ipswich

Re: JGR's Patch Pack

Post by JGR »

sjiveru wrote: 02 Feb 2023 01:59 I'm having some odd behaviour with cities not growing when I fully expect them to grow. I've posted about this elsewhere, but since I'm not sure if this is a general issue or a JGRPP issue, I'm uploading the save here as well.Pilkington & Co., 1908-12-11.sav

Look particularly at Yamatoyama and Nagaichi, two nearly identical towns with identical service where one town is consistently growing and the other is consistently not. Elsewhere nearby I have much larger cities - e.g. Mito, Sakura - that are not growing at all despite regular service at apparently sufficiently nearby stations. From what people have said so far, every vanilla growth mechanic indicates these towns should well be growing.

What is going on here? Does JGRPP change the requirements for town growth in such a way that it causes some of these towns to fail to grow when they seem no different from towns that are growing?
Yamatoyama is so small that the station is too far away to be classed as "near" for the purposes of the town growth calculation. This is the same in vanilla.
Also, in your save game you have town growth set to extremely slow. Set it to some higher value to get faster town growth.
Ex TTDPatch Coder
Patch Pack, Github
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 6 guests