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

User avatar
Redirect Left
Tycoon
Tycoon
Posts: 6597
Joined: 22 Jan 2005 19:31
Location: Wakefield, West Yorkshire

Re: JGR's Patch Pack

Post by Redirect Left » 02 Nov 2019 21:20

JGR wrote:
02 Nov 2019 20:37
Redirect Left wrote:
02 Nov 2019 13:06
No crash log was generated, here is the last autosave produced before the crash. (sadly, a huge rail jam had occured whilst i was AFK ;__;)
Thanks, that is an impressive level of gridlock. :)
Always the case with my stuff, when it goes wrong, it gridlocks half if not more as its all intertwined ratherly... poorly at best.
JGR wrote:
02 Nov 2019 20:37
Edit: Fixed, this will be in the next release.
Nice and speedy as always, I am guessing every time a water based industry shut down in the background there was a chance of it crashing OTTD silently, given i was never given a warning by Windows or OpenTTD, i just alt-tabbed and "oh no!" it wasn't there and had to load it again.
Image
Worst Behaved IRC Member of 2008, 2009 & 2010 - Go Me!

Towa Shina
Engineer
Engineer
Posts: 7
Joined: 30 Jun 2019 01:45

Re: JGR's Patch Pack

Post by Towa Shina » 04 Nov 2019 02:22

Towa Shina wrote:
26 Oct 2019 00:37
I guess my English is so terrible that you can't understand...

Image
Image
Attachments
bug1.png
(336.96 KiB) Not downloaded yet
bug2.png
(292.78 KiB) Not downloaded yet

User avatar
vincentkoevoets
Engineer
Engineer
Posts: 26
Joined: 14 Nov 2014 10:49
Location: Assen, Netherlands

Re: JGR's Patch Pack

Post by vincentkoevoets » 07 Nov 2019 17:17

Thanks JGR for the latest update! Everything is working now on Catalina, I installed it on a seperate partition :lol: and compiled 0.32.2. It now runs fine on Catalina. Thanks for the continuing efforts man!
I attached the zipfile for 0.32.2 for Mac OS for anyone who wants it.
openttd-custom-jgrpp-0.32.2-MacOS.zip
openttd-custom-jgrpp-0.32.2-MacOS
(8.09 MiB) Downloaded 14 times

User avatar
andythenorth
Tycoon
Tycoon
Posts: 5009
Joined: 31 Mar 2007 14:23
Location: Lost in Music

Re: JGR's Patch Pack

Post by andythenorth » 07 Nov 2019 18:09

vincentkoevoets wrote:
07 Nov 2019 17:17
Everything is working now on Catalina, I installed it on a seperate partition :lol: and compiled 0.32.2. It now runs fine on Catalina.
I don't want to derail the JGR thread, but what's the performance like on Catalina? https://github.com/OpenTTD/OpenTTD/issu ... -550555295

User avatar
vincentkoevoets
Engineer
Engineer
Posts: 26
Joined: 14 Nov 2014 10:49
Location: Assen, Netherlands

Re: JGR's Patch Pack

Post by vincentkoevoets » 07 Nov 2019 18:23

andythenorth wrote:
07 Nov 2019 18:09
vincentkoevoets wrote:
07 Nov 2019 17:17
Everything is working now on Catalina, I installed it on a seperate partition :lol: and compiled 0.32.2. It now runs fine on Catalina.
I don't want to derail the JGR thread, but what's the performance like on Catalina? https://github.com/OpenTTD/OpenTTD/issu ... -550555295
Well, you tell me.. I'd say it's pretty good. Certainly it runs smooth and I haven't had any problems so far. The screenshot shows a pretty good frame rate, although it's a game I just started on with not very many vehicles in it yet. But everything looks fine to me.
Schermafbeelding 2019-11-07 om 19.20.27.png
(1.66 MiB) Not downloaded yet

User avatar
JGR
Tycoon
Tycoon
Posts: 1990
Joined: 08 Aug 2005 13:46
Location: Ipswich

Re: JGR's Patch Pack

Post by JGR » 08 Nov 2019 00:26

vincentkoevoets wrote:
07 Nov 2019 18:23
andythenorth wrote:
07 Nov 2019 18:09
vincentkoevoets wrote:
07 Nov 2019 17:17
Everything is working now on Catalina, I installed it on a seperate partition :lol: and compiled 0.32.2. It now runs fine on Catalina.
I don't want to derail the JGR thread, but what's the performance like on Catalina? https://github.com/OpenTTD/OpenTTD/issu ... -550555295
Well, you tell me.. I'd say it's pretty good. Certainly it runs smooth and I haven't had any problems so far. The screenshot shows a pretty good frame rate, although it's a game I just started on with not very many vehicles in it yet. But everything looks fine to me.
Schermafbeelding 2019-11-07 om 19.20.27.png
I haven't made any attempt to fix the Mac-specific performance issues. I don't really have any insight/ideas as to how to address those.

The issues that I recently fixed was (as far as I can ascertain without doing any testing on MacOS myself) due to stack misalignment related to a recent xcode issue.
https://github.com/JGRennison/OpenTTD-p ... 132d30be85
Towa Shina wrote:
04 Nov 2019 02:22
Towa Shina wrote:
26 Oct 2019 00:37
I guess my English is so terrible that you can't understand...
I understand what you are saying.
This is just how the cost estimation mechanism works.
It is per-tile and there isn't any tracking of operations which affect adjacent tiles to avoid double accounting.
Ex TTDPatch Coder, Grumpy Greymuzzle
Avatar by MoonsongWolf.
Patch Pack, Github
Dad-Coder since April 2018

Ragin1_
Engineer
Engineer
Posts: 4
Joined: 10 Dec 2018 05:58

Re: JGR's Patch Pack

Post by Ragin1_ » 08 Nov 2019 03:27

Not sure if this has been mentioned before but the template train replacement window is massive when you use 2x gfx and font size

https://gyazo.com/2b7805db7ecc4780294f5ea75d2b0ed3

https://gyazo.com/f24a24368a5d863a52fdcc9a55549aa7

I think it might be something to do with the 2x font size as it doesnt have the same issue in jokers patch pack which is missing it

https://gyazo.com/631cc701a2bcf8a2b22d00df16cefc51

https://gyazo.com/33912c23139283dcb702e61574c7d79d

I saw something about resizing the template based train replacement window in the patch notes for 0.32.1 but upgrading to 0.32.2 didnt do anything

User avatar
vincentkoevoets
Engineer
Engineer
Posts: 26
Joined: 14 Nov 2014 10:49
Location: Assen, Netherlands

Re: JGR's Patch Pack

Post by vincentkoevoets » 08 Nov 2019 07:39

JGR wrote:
08 Nov 2019 00:26
I haven't made any attempt to fix the Mac-specific performance issues. I don't really have any insight/ideas as to how to address those.
Well I'd say everything runs just fine! I wasn't expecting a fix or anything (and I don't think @andythenorth was either), in fact I don't expect anything at all :)
JGR wrote:
08 Nov 2019 00:26
The issues that I recently fixed was (as far as I can ascertain without doing any testing on MacOS myself) due to stack misalignment related to a recent xcode issue.
https://github.com/JGRennison/OpenTTD-p ... 132d30be85
Well, it worked! Incredible how we are (again) able to play a game this old on our new machines :D

User avatar
jfs
Director
Director
Posts: 593
Joined: 08 Jan 2003 23:09
Location: Denmark

Re: JGR's Patch Pack

Post by jfs » 08 Nov 2019 13:09

Ragin1_ wrote:
08 Nov 2019 03:27
Not sure if this has been mentioned before but the template train replacement window is massive when you use 2x gfx and font size
Might be related to the change that went into official 1.9.2 (and master a bit before that) which makes specified window/control minimum sizes scaled by the UI scale factor as well. It makes the default UI look much better, especially newspapers, vehicle/station info news, and the red error/question popups. But since TBTR isn't in the official version, its UI was naturally not tested with that change.

User avatar
Redirect Left
Tycoon
Tycoon
Posts: 6597
Joined: 22 Jan 2005 19:31
Location: Wakefield, West Yorkshire

Re: JGR's Patch Pack

Post by Redirect Left » 08 Nov 2019 21:06

This train has been stuck at this station for quite some time, it it stuck at "100%" loading, and has been stuck there long enough for the town rating to bomb down to 'Appalling'. This is running the recent 0.32.2 update, though i dunno if the 'stuck' issue is related to this.

I've saved the game as it is, and i've checked, if you reload the game from this save, it continues to be 'stuck' there. If you skip the train to the next station, it sets off fine, however the next train will arrive and also get stuck on 100%, they will also get stuck at the next station down the line after that, Corwen, which is north west up the track.

Image
Attachments
JUNE2019.sav
(6.31 MiB) Downloaded 11 times
OTTD.png
(322.34 KiB) Not downloaded yet
Image
Worst Behaved IRC Member of 2008, 2009 & 2010 - Go Me!

User avatar
vincentkoevoets
Engineer
Engineer
Posts: 26
Joined: 14 Nov 2014 10:49
Location: Assen, Netherlands

Re: JGR's Patch Pack

Post by vincentkoevoets » 09 Nov 2019 21:40

Redirect Left wrote:
08 Nov 2019 21:06
This train has been stuck at this station for quite some time, it it stuck at "100%" loading, and has been stuck there long enough for the town rating to bomb down to 'Appalling'. This is running the recent 0.32.2 update, though i dunno if the 'stuck' issue is related to this.

I've saved the game as it is, and i've checked, if you reload the game from this save, it continues to be 'stuck' there. If you skip the train to the next station, it sets off fine, however the next train will arrive and also get stuck on 100%, they will also get stuck at the next station down the line after that, Corwen, which is north west up the track.

Image
+1

User avatar
einsteinyh
Engineer
Engineer
Posts: 36
Joined: 15 Feb 2016 01:22
Location: Bogotá

Re: JGR's Patch Pack

Post by einsteinyh » 11 Nov 2019 00:37

Redirect Left wrote:
08 Nov 2019 21:06
...
Image
It is due to the autotimetable function, at some point you got a wrong time reading that lengthened the timetable (7th stop shows a travel time of 27.000 days). To solve it, reset the automate option to force them to correct timetabling, however, very probably you will have some trains waiting too long until it synchronizes again, maybe it's better for you to organize timings manually and then start the timetable. I do'nt know if the scheduled dispatch might help as I don't know how to use it.
Image
Attachments
Captura.PNG
(131.53 KiB) Not downloaded yet

cmhbob
Engineer
Engineer
Posts: 57
Joined: 29 May 2010 06:06
Contact:

Re: JGR's Patch Pack

Post by cmhbob » 12 Nov 2019 01:11

Green Cartage, Dec 28th, 2013.png
(431.05 KiB) Not downloaded yet
Having a problem that may or may not be due to the PP.

I've recently run into trains not being replaced, with a message of "Vehicle is not available." I'm trying to replace an EMD E9 with a GE P42DC Genesis. Both are regular old diesel engines.

If I force the old train to the depot, then sell the engine and buy a new one, it doesn't carry the info over. It just shows up as "Train 123" instead of "Pax MPS-CMH 4" and I have to redo the orders as well.

This does not seem to happen with RV (894 of 900), ships (88 of 500), or aircraft (39 of 200). Train limit is 500.

I currently have 144 trains, running JGRPP 0.31.2. Savegame and screenie attached.
Attachments
Green Cartage, Dec 28th, 2013.sav
(4.14 MiB) Downloaded 6 times
--
Bob
The wrinkles only go where the smiles have been...
Me, elsewhere

User avatar
JGR
Tycoon
Tycoon
Posts: 1990
Joined: 08 Aug 2005 13:46
Location: Ipswich

Re: JGR's Patch Pack

Post by JGR » 13 Nov 2019 03:00

cmhbob wrote:
12 Nov 2019 01:11
Green Cartage, Dec 28th, 2013.pngHaving a problem that may or may not be due to the PP.

I've recently run into trains not being replaced, with a message of "Vehicle is not available." I'm trying to replace an EMD E9 with a GE P42DC Genesis. Both are regular old diesel engines.

If I force the old train to the depot, then sell the engine and buy a new one, it doesn't carry the info over. It just shows up as "Train 123" instead of "Pax MPS-CMH 4" and I have to redo the orders as well.

This does not seem to happen with RV (894 of 900), ships (88 of 500), or aircraft (39 of 200). Train limit is 500.

I currently have 144 trains, running JGRPP 0.31.2. Savegame and screenie attached.
The "Pax" train group has a different autoreplace engine for the EMD E9 engine: Alco PA-4, which overrides the global engine replacement. This engine is not available.
Perhaps the error message should clarify which engine is not available, I can see if I can look into that in due course.
jfs wrote:
08 Nov 2019 13:09
Ragin1_ wrote:
08 Nov 2019 03:27
Not sure if this has been mentioned before but the template train replacement window is massive when you use 2x gfx and font size
Might be related to the change that went into official 1.9.2 (and master a bit before that) which makes specified window/control minimum sizes scaled by the UI scale factor as well. It makes the default UI look much better, especially newspapers, vehicle/station info news, and the red error/question popups. But since TBTR isn't in the official version, its UI was naturally not tested with that change.
I'll look into this.
Redirect Left wrote:
08 Nov 2019 21:06
This train has been stuck at this station for quite some time, it it stuck at "100%" loading, and has been stuck there long enough for the town rating to bomb down to 'Appalling'. This is running the recent 0.32.2 update, though i dunno if the 'stuck' issue is related to this.

I've saved the game as it is, and i've checked, if you reload the game from this save, it continues to be 'stuck' there. If you skip the train to the next station, it sets off fine, however the next train will arrive and also get stuck on 100%, they will also get stuck at the next station down the line after that, Corwen, which is north west up the track.

Image
I'd suggest just removing the offending timetable entry for now. It should clear by itself given sufficiently long, however I wouldn't hang around waiting.
If congestion is sufficiently permanent it will eventually get built into the timetable.
Ex TTDPatch Coder, Grumpy Greymuzzle
Avatar by MoonsongWolf.
Patch Pack, Github
Dad-Coder since April 2018

cmhbob
Engineer
Engineer
Posts: 57
Joined: 29 May 2010 06:06
Contact:

Re: JGR's Patch Pack

Post by cmhbob » 13 Nov 2019 04:26

JGR wrote:
13 Nov 2019 03:00
The "Pax" train group has a different autoreplace engine for the EMD E9 engine: Alco PA-4, which overrides the global engine replacement. This engine is not available.
Perhaps the error message should clarify which engine is not available, I can see if I can look into that in due course.
I'll be damned. Didn't realize I had done that, and didn't realize a group setting could/would override the global. Thanks for that.

Edit: do you think that's also causing the problems at the depot when I try to manually deal with this?
--
Bob
The wrinkles only go where the smiles have been...
Me, elsewhere

User avatar
vincentkoevoets
Engineer
Engineer
Posts: 26
Joined: 14 Nov 2014 10:49
Location: Assen, Netherlands

Re: JGR's Patch Pack

Post by vincentkoevoets » 13 Nov 2019 11:44

Hey there JGR, I'm back at it again.. :roll:
Trying to compile on Windows this time, I get the following error:

Code: Select all

make[1]: Map '/home/Koevoets/openttd-patches/objs/lang' wordt binnengegaan
[LANG] Compiling core/alloc_func.cpp
[LANG] Compiling string.cpp
[LANG] Compiling strgen/strgen_base.cpp
[LANG] Compiling strgen/strgen.cpp
[LANG] Compiling getoptdata.cpp
[LANG] Compiling and Linking strgen.exe
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: strgen_base.o:strgen_base.cpp:(.text+0x28e): undefined reference to `__memcpy_chk'
collect2.exe: error: ld returned 1 exit status
make[1]: *** [Makefile:67: strgen.exe] Fout 1
make[1]: Map '/home/Koevoets/openttd-patches/objs/lang' wordt verlaten
make: *** [Makefile:57: all] Fout 1
Yes I know you compiled it already, but I enjoy the process myself. Can you help me with this one?
Thanks!

phobos2077
Engineer
Engineer
Posts: 20
Joined: 13 Nov 2019 16:17

Re: JGR's Patch Pack

Post by phobos2077 » 13 Nov 2019 16:33

I've been testing this (installed for the Day Patch primarily, everything else is a bonus!) and so far it works great (though as a software development person I don't like the added UI clutter of redundant buttons and such, that was accumulated over the years and this pack added some - I'm referring to the timetable window).

I have a question regarding the Day Patch though. From my understanding it was implemented with a basic idea that the day becomes longer in real time, but everything else in the game "moves" in the same rate of game-calendar days, except the actual vehicles moving on the game world. Sounds logical I guess. What I don't understand is why not add supplementary options to scale everything that depends on vehicle speed in game time. Specifically station ratings are suddenly improved after you slow down the time. Also the issue of production rates vs vehicle speeds increasing in the game time line...

I certainly see now why these patches were never merged into trunk as of yet. Because either way you add this patch, it will break the game and either approach requires other new options (configurable, preferably) to complement it and make game's mechanics coherent again.

Edit: so I guess my real question is - does anyone know any existing newgrfs that can adjust the economy according to the "faster" vehicle movement? Namely industry production rate multiplier and time multiplier in station rating calculations. I guess I'll have to increase all maintenance costs and interest rates to compensate for the faster cash-flow, but there is already BaseCost that allows to do it.

PS: I think Day Length multiplier of 3 (maybe 2) works best for my tastes. Not too slow as to completely ruin the economy, but not as warp-speed fast as vanilla. I've increased running costs to compensate for this. But obviously industry speeds (including city buildings) still work at the same rate, so now there's much less cargo to move around in total. This reduces the amount of trucks/buses or the length of trains I need to create for each line.

ino
Engineer
Engineer
Posts: 107
Joined: 09 Apr 2017 14:58

Re: JGR's Patch Pack

Post by ino » 13 Nov 2019 18:04

phobos2077 wrote:
13 Nov 2019 16:33
I've been testing this (installed for the Day Patch primarily, everything else is a bonus!) and so far it works great (though as a software development person I don't like the added UI clutter of redundant buttons and such, that was accumulated over the years and this pack added some - I'm referring to the timetable window).

I have a question regarding the Day Patch though. From my understanding it was implemented with a basic idea that the day becomes longer in real time, but everything else in the game "moves" in the same rate of game-calendar days, except the actual vehicles moving on the game world. Sounds logical I guess. What I don't understand is why not add supplementary options to scale everything that depends on vehicle speed in game time. Specifically station ratings are suddenly improved after you slow down the time. Also the issue of production rates vs vehicle speeds increasing in the game time line...

I certainly see now why these patches were never merged into trunk as of yet. Because either way you add this patch, it will break the game and either approach requires other new options (configurable, preferably) to complement it and make game's mechanics coherent again.

Edit: so I guess my real question is - does anyone know any existing newgrfs that can adjust the economy according to the "faster" vehicle movement? Namely industry production rate multiplier and time multiplier in station rating calculations. I guess I'll have to increase all maintenance costs and interest rates to compensate for the faster cash-flow, but there is already BaseCost that allows to do it.
I don't think NewGRF can do that. Just wondering, but if you want everything to speed up, why do you want to slow the day down in the first place?

Note that the vehicle running cost is also scaled, so if you have day length multiplier of 4x the yearly running cost will be quadruple. So it's not "faster" in a sense.

User avatar
JGR
Tycoon
Tycoon
Posts: 1990
Joined: 08 Aug 2005 13:46
Location: Ipswich

Re: JGR's Patch Pack

Post by JGR » 13 Nov 2019 19:11

phobos2077 wrote:
13 Nov 2019 16:33
I've been testing this (installed for the Day Patch primarily, everything else is a bonus!) and so far it works great (though as a software development person I don't like the added UI clutter of redundant buttons and such, that was accumulated over the years and this pack added some - I'm referring to the timetable window).
Each button is there for a reason but of course no single user will want to use all of them.
I'd expect the vast majority of users to either not use timetables, or to just turn on timetable automation/etc and never have to look at the timetable window again.
phobos2077 wrote:
13 Nov 2019 16:33
I have a question regarding the Day Patch though. From my understanding it was implemented with a basic idea that the day becomes longer in real time, but everything else in the game "moves" in the same rate of game-calendar days, except the actual vehicles moving on the game world. Sounds logical I guess. What I don't understand is why not add supplementary options to scale everything that depends on vehicle speed in game time. Specifically station ratings are suddenly improved after you slow down the time. Also the issue of production rates vs vehicle speeds increasing in the game time line...

I certainly see now why these patches were never merged into trunk as of yet. Because either way you add this patch, it will break the game and either approach requires other new options (configurable, preferably) to complement it and make game's mechanics coherent again.
The game mechanics never were coherent and balanced in any objective way. In reality it is entirely arbitrary. Day length amongst other features is just another knob to allow adjusting the mechanics to your personal preferences.
phobos2077 wrote:
13 Nov 2019 16:33
Edit: so I guess my real question is - does anyone know any existing newgrfs that can adjust the economy according to the "faster" vehicle movement? Namely industry production rate multiplier and time multiplier in station rating calculations. I guess I'll have to increase all maintenance costs and interest rates to compensate for the faster cash-flow, but there is already BaseCost that allows to do it.
No NewGRF author has ever asked about a way of reading the current day length, and therefore there is no such mechanism.
If a NewGRF author ever seriously wanted to implemented such behaviour it could be added easily enough.
Ex TTDPatch Coder, Grumpy Greymuzzle
Avatar by MoonsongWolf.
Patch Pack, Github
Dad-Coder since April 2018

ino
Engineer
Engineer
Posts: 107
Joined: 09 Apr 2017 14:58

Re: JGR's Patch Pack

Post by ino » 13 Nov 2019 19:18

A question. I just load up OpenTTD in quite a while (I think >6 months), and update my local installation of the patch pack to cbdd9f84d8d8a181c25a9f88c908468285f1417d. I loaded up some of my old save game, and somehow a number of train are showing as 0HP, which result in a train too heavy message being shown. The savegame is already in JGRPP format so I don't know if it's vanilla problem or not. It happen in multiple save file -- the attached file doesn't have any newgrf either.

Am I missing some new options, or is it a bug, or am I missing something?
Attachments
Tradingtown Transport, 2280-12-12.sav
(633.61 KiB) Downloaded 25 times

Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 3 guests