Page 1 of 4
Powerful Industry Patch
Posted: 21 Jun 2006 08:44
by Haukinger
Hi all !
I've made a patch that makes cargo-trains more competitive compared to passenger trains. It's running on my server (a slightly modified version, will change to the one posted below on the next restart), so feel free to try it out -
http://haukinger.dyndns.org/ottd.
Raw material production can now get much higher than in normal OpenTTD. In the past, production was limited to about 2300 - now it can be 12500. This way goods-trains are as desirable in late-game as passengers. Production will never decrease. It will grow if you transport more than about 55%. If you transport more than 80%, large increases are possible.
Unserviced industries will close down. Normal industries start closing 3 years after the last train left, and raw material industries start one year later. Don't expect unserviced industries to live more than 5 or 6 years! On the other hand, the rate of new industries emerging is increased, too.
Loading/unloading-time is always zero, that is, if the train fits into the station. This way you don't need to build stations that are larger than the town they're serving...
Conversion from normal to electrified tracks with trains present is enabled, too.
EDIT: updated patch - got switch in patch-settings
EDIT: updated patch - got three-way switch in patch-settings
EDIT: updated patch to be at least syntactically savegame-compatible to normal ottd.
EDIT: updated MiniIN-diff according to official procedure
EDIT: removed easy_convert_tracks, changed to SLE_CONDVAR, savegame bump to 30 (normal) or 35 (MiniIN). can load old savegames. defaults to smooth economy.
Posted: 21 Jun 2006 09:29
by graphics_master
How do u install this patch ?
Posted: 21 Jun 2006 09:33
by XeryusTC
Posted: 21 Jun 2006 09:35
by graphics_master
could someone post the ready files nessicary for installing this patch because it is too confusing.
Posted: 21 Jun 2006 09:40
by mart3p
Download the exe from Haukinger’s link in the first post.
Re: Powerful Industry Patch
Posted: 21 Jun 2006 10:46
by SirkoZ
Haukinger wrote:Hi all !
I've made a patch that makes cargo-trains more competitive compared to passenger trains. It's running on my server (a slightly modified version, will change to the one posted below on the next restart), so feel free to try it out -
http://haukinger.dyndns.org/ottd.
Raw material production can now get much higher than in normal OpenTTD. In the past, production was limited to about 2300 - now it can be 63000. This way goods-trains are as desirable in late-game as passengers. Production will never decrease. It will grow if you transport more than about 55%. If you transport more than 80%, large increases are possible.
Unserviced industries will close down. Normal industries start closing 3 years after the last train left, and raw material industries start one year later. Don't expect unserviced industries to live more than 5 or 6 years! On the other hand, the rate of new industries emerging is increased, too.
Loading/unloading-time is always zero, that is, if the train fits into the station. This way you don't need to build stations that are larger than the town they're serving...
Conversion from normal to electrified tracks with trains present is enabled, too.
In the currently running game we have two coal mines nearing 10000, and a factory at 15000. By far not every corner of the map is connected to the network. The server has a hard time, though, and everything's a bit slow...
Powerful? No.
Totally unrealistic and way too easy? Probably - it's like playing with LeG0 technic and then downgrading to duplo.
A viable 3rd option (apart from TTD_ and smooth_economy)? Perhaps.
Re: Powerful Industry Patch
Posted: 21 Jun 2006 11:21
by Haukinger
SirkoZ wrote:
Powerful? No.
Call it what you like...
SirkoZ wrote:
Totally unrealistic and way too easy? Probably - it's like playing with LeG0 technic and then downgrading to duplo.
What do you mean with 'easy' ? Easy to make money ? That has always been easy. Easy to transport much ? That depends on what you call much. It's different from normal transport tycoon. The quest is to build an effective network that can handle much cargo. That is, more cargo that normally, considering the largest factory I've seen so far (with standard rules) generated about 9000 goods. With normal trains, no monorail or maglev.
SirkoZ wrote:
A viable 3rd option (apart from TTD_ and smooth_economy)? Perhaps.
Of course. It's not meant to replace smooth_economy. It's for those who lile myself want to experience a different ottd. If someone explains the patches-configuration-gui to me (or I explore it myself), I'll add a switch for it, nor unlike that for smooth_economy.
Nobody is forced to use this...
Posted: 21 Jun 2006 12:14
by sc79
Not to start an arguement but....
I do think you've gone a bit overboard on your numbers. One of the stations feeding the factory in the SS has 6 tracks/18 platforms, and can barely hold > 60% of 17000 total production from 6 farms. You're looking at 50+ platforms per industry with this patch (less with longer trains, obiviously, but its still a massive volume).
You barely touched the potential of your numbers on any individual industry, let alone the map as a whole, and the server is already hurting.
But, as you say, noone has to use it. If it works, more power to you

Posted: 21 Jun 2006 12:28
by Haukinger
The server is a crappy duron 1300, that doesn't count

In fact, noone needs 63000 production per industry, it could even be around 500000 with uint16 production_rate. More important is the behaviour of the industries. They don't shrink leaving you with unneeded trains that just hang around and block crossings and stations. They don't stop growing as long as your network is capable of handling the traffic. They grow linearly, not exponentially, so you can use a newly built coal mine in 2010 and have it reach reasonable output before the game ends.
Nice screenshot, btw

Posted: 21 Jun 2006 12:28
by gkirilov
The only useful thing here (for me) is the increased capacity of the primary/secondary industries. THis is really good because I don't have to build several mines next to each other to get high capacity.
Anyway I'll try it. Thanks for the effort.

Posted: 21 Jun 2006 14:11
by Born Acorn
This would be good for a true sandbox mode. (The cheat menu seems to me more of a hackish solution due to the fact its called cheats).
Re: Powerful Industry Patch
Posted: 22 Jun 2006 09:26
by SirkoZ
Haukinger wrote:SirkoZ wrote:
A viable 3rd option (apart from TTD_ and smooth_economy)? Perhaps.
Of course. It's not meant to replace smooth_economy. It's for those who lile myself want to experience a different ottd. If someone explains the patches-configuration-gui to me (or I explore it myself), I'll add a switch for it, nor unlike that for smooth_economy.
Nobody is forced to use this...
'Tell you what - if you would be so kind and:
1.) Look at my and existing smooth_economy patch for pointers how to make a GUI switch - it's really easy (observe the variables.h, settings.c and settings_gui.c files)

,
2.) patch the nightly code with my patch (PM me if it needs updating),
3.) then write in beside existing your code, link up the switches in the GUI and we then got the normal, smooth and powerful/overkill

patches which can be included in the next mini_Integrated nightly.
Of course you could also check out the latest mini_Integrated_nightly which already contains my patch and just add your code to that one and make a patch...
Posted: 22 Jun 2006 13:39
by Hazelrah
Not to be a stick in the mud, but if your going to put the two together, then they should probably be one option in the patches. I haven't figured out how to do it yet, but take a look at "Review vehicles' orders:" under the Vehicles patches. You press the arrow keys and it switches through the 3 options. That's how I'd envision something like this working too, as I don't think it makes sense to have smoot_economy and powerful_economy at the same time... does it?
-Hazelrah
Posted: 22 Jun 2006 13:44
by SirkoZ
Hazelrah wrote:Not to be a stick in the mud, but if your going to put the two together, then they should probably be one option in the patches. I haven't figured out how to do it yet, but take a look at "Review vehicles' orders:" under the Vehicles patches. You press the arrow keys and it switches through the 3 options. That's how I'd envision something like this working too, as I don't think it makes sense to have smoot_economy and powerful_economy at the same time... does it?
-Hazelrah
Indeed - one switch to choose among all 3.
Posted: 22 Jun 2006 14:05
by Haukinger
I've updated the patch and added two switches - one for the powerful industry and one for the track-conversion. It was really easy

The powerful-industry-switch overrides the one for smooth economy. I agree that a three-way switch would be optimal, though.
BTW - is there a reason that the amount of cargo moved in MoveIndustryGoods() is limited to 255 ? I've raised it to 1023 and it seems to work. Otherwise production of mines/oil-wells is limited to about 13500, regardless of production_rate.
What happens if produced_last_mo overflows ? I've limited it to 65535 to avoid this. Or should it become uint32 ?
Applying it to the MiniIN-branch looks like a bit of work. We'll see...
EDIT: three-way switch for economy is done
Posted: 22 Jun 2006 15:24
by SirkoZ
Wow cool!
I don't know why the amount of cargo moved in MoveIndustryGoods() is limited to 255 - which file is that BTW?
The "old" TTD economy has had production_rate limited to 255 and total_production is production_rate * 8 or 9 or 10 (at 74 for day_ticks) - depends on day_ticks - to have TTOriginal behaviour, day_ticks should be set to 112...
If produced_last_mo overflows, probably a crash would occur - which file again (I don't have much time right now)?
Well - in any case - please try to make your patch compatible with my improved_smooth_economy already integrated in both nightly (you have to do it) and mini_IN (already merged).
Thanks.
After you're done - we'll talk to richk67 to get it into the mini_IN.

Posted: 22 Jun 2006 15:47
by Haukinger
It's
TransportIndustryGoods... (embarrassing) in industry_cmd.c.
is there, too. It could just wrap around and result in a hellishly low rating... anyway, as it is now, if 65535 is reached, no more goods are transported this month.
The patch works with the current head-revision from trunk. Expect the version for MiniIN tomorrow.
Posted: 22 Jun 2006 17:24
by SirkoZ
I see - well - I didn't have the time to check out the file before - in any case - post patches somewhere here, so we can review/test them...
Posted: 22 Jun 2006 18:35
by webfreakz.nl
Hmm, this sounds great, but as usual i've got a couple questions: does this affect your savegame *in any way*? So i will play with a game including this patch, next day, i can still open it with e.g. a new nightly?
Posted: 22 Jun 2006 23:40
by SirkoZ
I think it won't - well at least any and all of my patches don't affect the savegame in a way it wouldn't work without them...