Dying industries

Got an idea for OpenTTD? Post it here!

Moderator: OpenTTD Developers

User avatar
L. Spooner Inc
Engineer
Engineer
Posts: 84
Joined: 22 Jul 2019 08:13

Dying industries

Post by L. Spooner Inc »

There really needs to be some way to either prevent an industry from going out of business or alert the player in some obvious, visible way that it's on the verge of doing so. Typically what will happen is I'll pause the game and spend two hours constructing a huge, nation-spanning network of trains bringing some resource to a lumberyard or factory... then unpause and have the lumberyard or factory wink out of existence. At that point I usually rage-quit and delete all the saves.

It should be possible to do something like pay an industry to guarantee it stays open, or do something like make it blink or turn red or something visible and obvious to warn that you're about to waste several hours of your time.
User avatar
L. Spooner Inc
Engineer
Engineer
Posts: 84
Joined: 22 Jul 2019 08:13

Re: Dying industries

Post by L. Spooner Inc »

I don't mind industries dying off, I just object to them vanishing after I've spent real-world hours setting up a rail network to service them. I'm just looking for some obvious visible cue that it's about to happen.
User avatar
kamnet
Moderator
Moderator
Posts: 8548
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: Dying industries

Post by kamnet »

It's usually down in your toolbar/pop-up history, warnings that "xxx industry is facing eminent closure if not serviced soon".
User avatar
L. Spooner Inc
Engineer
Engineer
Posts: 84
Joined: 22 Jul 2019 08:13

Re: Dying industries

Post by L. Spooner Inc »

kamnet wrote: 19 Nov 2019 01:07 It's usually down in your toolbar/pop-up history, warnings that "xxx industry is facing eminent closure if not serviced soon".
Yes, but it's not very accessible or visible. You're left with the choice of adding an extra step every single time of having to scan through all the news every single time you want to set up a new station, or risking having an industry just poof into nothingness after wasting hours setting up a rail network around it. I can't be the only person this happens to. I think it would be useful addition to the GUI to have some kind of passive warning visible in the the HUD that an industry is faltering. Flashing or blinking or a column of smoke or a red tint or something.
User avatar
andythenorth
Tycoon
Tycoon
Posts: 5656
Joined: 31 Mar 2007 14:23
Location: Lost in Music

Re: Dying industries

Post by andythenorth »

Industries that disappear just as you build service to them is a known frustration. It has existed since the original TTD. It's definitely a trigger for rage quitting from a savegame.

The solution is to use one of several newgrfs that ban closure.

OpenTTD cannot simply show you a message as it does not know the industry is going to close until the closure happens. It's vanishingly unlikely that this will be changed. :)

So as previously, use Manual Industries from the online content service (or other grfs are available).
User avatar
kamnet
Moderator
Moderator
Posts: 8548
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: Dying industries

Post by kamnet »

andythenorth wrote: 19 Nov 2019 07:10 OpenTTD cannot simply show you a message as it does not know the industry is going to close until the closure happens. It's vanishingly unlikely that this will be changed. :)
But knowing that the game does issue a warning when an industry is at risk of disappearing, how possible is it to create another type of visiual cue that closure is eminent? Would it be possible to display a special icon next to the industry name, maybe both on the map and in the industry list? Or maybe add a filter that sorts these out in the industry list?
User avatar
andythenorth
Tycoon
Tycoon
Posts: 5656
Joined: 31 Mar 2007 14:23
Location: Lost in Music

Re: Dying industries

Post by andythenorth »

kamnet wrote: 19 Nov 2019 07:17 But knowing that the game does issue a warning when an industry is at risk of disappearing, how possible is it to create another type of visiual cue that closure is eminent?
Possible. The condition is 'has not produced for 5 years or more'. https://github.com/OpenTTD/OpenTTD/blob ... .cpp#L2700

On a large map, this would cause a lot of industries to display an 'at risk' warning, would it actually add much information? :)
User avatar
kamnet
Moderator
Moderator
Posts: 8548
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: Dying industries

Post by kamnet »

andythenorth wrote: 19 Nov 2019 08:30
kamnet wrote: 19 Nov 2019 07:17 But knowing that the game does issue a warning when an industry is at risk of disappearing, how possible is it to create another type of visiual cue that closure is eminent?
Possible. The condition is 'has not produced for 5 years or more'. https://github.com/OpenTTD/OpenTTD/blob ... .cpp#L2700

On a large map, this would cause a lot of industries to display an 'at risk' warning, would it actually add much information? :)
What about giving it its own mini-map with ability to filter by industry?
User avatar
L. Spooner Inc
Engineer
Engineer
Posts: 84
Joined: 22 Jul 2019 08:13

Re: Dying industries

Post by L. Spooner Inc »

What about baking in something like a six month delay, with any servicing effectively reversing the elimination? That way you can give a warning only for those industries which are absolutely guaranteed 100% to die, making the warning more useful and less prevalent.
User avatar
andythenorth
Tycoon
Tycoon
Posts: 5656
Joined: 31 Mar 2007 14:23
Location: Lost in Music

Re: Dying industries

Post by andythenorth »

L. Spooner Inc wrote: 19 Nov 2019 21:45 What about baking in something like a six month delay, with any servicing effectively reversing the elimination?
Yes, that can be done by writing an industry newgrf.
User avatar
odisseus
Director
Director
Posts: 552
Joined: 01 Nov 2017 21:19

Re: Dying industries

Post by odisseus »

I don't understand why this is a problem at all.

Even a smallest service is sufficient to keep an industry alive. If you absolutely need to secure a factory at a drop point of your future mainline, build a truck stop and feed it with grain from a nearby farm. When the mainline comes into existence, the truck service can be removed.

If the industry disappears nevertheless, just fund another one in its place. With the right settings, you can even fund primary industries.
User avatar
andythenorth
Tycoon
Tycoon
Posts: 5656
Joined: 31 Mar 2007 14:23
Location: Lost in Music

Re: Dying industries

Post by andythenorth »

odisseus wrote: 20 Nov 2019 01:09I don't understand why this is a problem at all.
It's an aspect of the game mechanic that I find really unfair. When you're relatively new to the game, it just smacks you in the face frequently. :)

That said though, it has been solved by newgrf for a long time. And won't be changed in the base game, as it's long-established behaviour: https://github.com/OpenTTD/OpenTTD/blob ... ject-goals

Sometimes though I wonder if OpenTTD should ship with a default newgrf that 'fixes' things like this for new players (and also, for example, makes the default vehicles refittable) :D
User avatar
L. Spooner Inc
Engineer
Engineer
Posts: 84
Joined: 22 Jul 2019 08:13

Re: Dying industries

Post by L. Spooner Inc »

andythenorth wrote: 20 Nov 2019 07:12 And won't be changed in the base game, as it's long-established behaviour: https://github.com/OpenTTD/OpenTTD/blob ... ject-goals
An annoyance which can't be avoided by more careful or prudent or skillful play, but could be entirely eliminated just by making more information visible, isn't a game mechanic, it's poor UI. And improving the interface is within the mandate of the base game.
User avatar
andythenorth
Tycoon
Tycoon
Posts: 5656
Joined: 31 Mar 2007 14:23
Location: Lost in Music

Re: Dying industries

Post by andythenorth »

L. Spooner Inc wrote: 23 Nov 2019 05:42An annoyance which can't be avoided by more careful or prudent or skillful play, but could be entirely eliminated just by making more information visible, isn't a game mechanic, it's poor UI. And improving the interface is within the mandate of the base game.
I think that's well expressed, and I tend to agree.

What I can't see is how to design a useful solution. Do you have an idea for how this could be improved?
LaChupacabra
Route Supervisor
Route Supervisor
Posts: 385
Joined: 08 Nov 2019 23:54

Re: Dying industries

Post by LaChupacabra »

Hi,
This is my first post here on the forum. The theme of industries disappearing without notice is known and quite current for me, so I would like to add a few remarks. I admit that I would care about some changes and I wanted to post a similar thread. I apologize in advance for possible language mistakes.

Generally, the problem with closing industries is not that they are closed, but that there is no warning before closing them. Those that appear only provide information about a fait accompli - the company will disappear by the end of the month, which the player has no influence on. Sometimes this information, when there are many others at the same time, appears even after closing. In the case of primary industries, the matter is clear and obvious - lack of production means a risk of closure. Changes are not needed there. The problem concerns the processing industry, where the production of unsupported plants is always 0.

The problem is the same for the original set of industries, as well as for any other where industries may be closed, including FIRS. Only ECS has some custom solutions.

Image

A few years ago when I was configuring the server with Milek7, we had a dilemma. It was a server with a very long gameplay (over 1000 years), with the FIRS industry and the New World Disorder script dedicated to this industry set, which we together created for the needs of, among others this server (has not been fully completed). Initially, for misgivings of sudden closing of factories, steel mills and other, the option allowing this possibility was turned off. As a result, after a few hundred years of play, the whole map was overgrown with factories, to the extent that there was practically no space left to let build any railway line.

Currently, together with another colleague, we are preparing a scenario with a realistic map for one of the more popular servers and the problem of choosing the lesser evil again appears.
What to choose?
- a map overgrown with factories, with a hundred smelters to choose from
- annoying closing them without any warning, annoy especially when the train was just reaching the station, and all the funds accumulated went to the expensive construction (Base Cost Mod),
- or the same industries layout unchanging to boredom, where even shop founding is forbidden?
Choosing any additions here won't help. Creating scripts that interfere with the closing mechanism is also not the right way.

Image
Even if the train could arrive on time, nothing would change.

Solutions?
This problem could be solved in at least two ways. Some of them can be done at the addon level, but I think it would be the most appropriate for them to be permanent elements of the game, independent of the addons used or not.
1. Closing delay relative to the arrival of the message - A fixed period should elapse between the arrival of the message and the closing down of processing industries. It could be 3 months or more. If any raw cargo are delivered to the industry during this time:
A. the threat of closure is canceled (that's how it works in ECS)
B. the closing time is extended by 2 months for each delivery, up to a maximum of 10 years. When the remaining time decreases again to 3 months, information about risk of closure reappears.
1+. Additional information about the time remaining to close in the company window - In addition to the closing delay, additional information about the risk of closing could be placed in the company window. It would appear when an industry is at risk of closure. A similar solution exists and works in the ECS industries set. The readability of information is average there, therefore it would propose a slightly different, more easily visible form of such information.
2. Protection against closing - Adding a function to the industry window enabling it to be secured against liquidation for a fee. This function with possible other activities, which are currently not available, could be placed in an additional window of the industry menagement, which would be equivalent to the window of local authorities. Opening this window would be the same as for the city.

Common window of industry
Image


Proposition: Window of industry at risk of closure
Image


Proposition: Window of Industry menagement
Image

If there is any restriction on the possibility of changes in such elements of the game as information appearing or the possibility of additional actions, then there is still the possibility of adding it as an option, even enabled by default. How were cargodist and other improvements added to the game? The option may be called: "Inform about the possibility of closing industries in advance" This option should also give the possibility to save the industry from closing.

And by the way, I don't think these are any particularly significant changes. The game is changing and if anyone liked classic solutions, they can still enable older versions.
Please, do not block favorable changes in the name ... I actually don't know what? :)
I am sorry for may English. I know is bed.
User avatar
andythenorth
Tycoon
Tycoon
Posts: 5656
Joined: 31 Mar 2007 14:23
Location: Lost in Music

Re: Dying industries

Post by andythenorth »

Thanks! The suggestions make sense. Fortunately many of the suggestions above ^ can be done in newgrf. :)

The chances of getting the default closure mechanic changed are zero. :|

To help understand why it won't change:
- it's against the development goals for the game, as it can be (mostly) solved in content (newgrf). See https://github.com/OpenTTD/OpenTTD/blob ... ject-goals
- it would 'break' all existing industry newgrfs, and making it a setting does not help that, as the player may have the wrong choice for the setting
- it's not simply a case of a UI change to display the warning message, as OpenTTD has no concept of a closure period, it's just a random chance (dice roll) if the industry hasn't produced for 5 years. Depending on the economy setting, the dice roll is every month, or totally random.

There will be examples of similar changes in the history of OpenTTD that can be pointed to, but the history of OpenTTD is also full of well-intentioned mistakes which make further development difficult. Repeating those is unwise.

So the development goals for OpenTTD are good, but in this case they unfortunately lead to a less good gameplay for industries:
- players of the base game won't know that they need to use Manual Industries to avoid the shock closures
- newgrf spec doesn't contain everything that is needed to control industry closure, notably it's hard to prevent many industries closing at the same time
- gamescript can't solve this as it cannot understand or interact with newgrf

It's something I would like to solve :D But I am not a core developer :)

My current ideas are:
- extend newgrf spec to give more information about industry closure
- change OpenTTD default experience to offer 'original vanilla' and 'improved' gameplay, where 'improved' is provided by including some new default grfs, which adjust known gameplay weak points. In the case that someone disagrees with those default grfs they can continue with original gameplay, or simply load alternative grfs, or fork OpenTTD and change the defaults. So nobody loses :)
LaChupacabra
Route Supervisor
Route Supervisor
Posts: 385
Joined: 08 Nov 2019 23:54

Re: Dying industries

Post by LaChupacabra »

andythenorth wrote: 25 Nov 2019 07:50 The chances of getting the default closure mechanic changed are zero. :|

To help understand why it won't change:
- it's against the development goals for the game, as it can be (mostly) solved in content (newgrf). See https://github.com/OpenTTD/OpenTTD/blob ... ject-goals
- it would 'break' all existing industry newgrfs, and making it a setting does not help that, as the player may have the wrong choice for the setting
- it's not simply a case of a UI change to display the warning message, as OpenTTD has no concept of a closure period, it's just a random chance (dice roll) if the industry hasn't produced for 5 years. Depending on the economy setting, the dice roll is every month, or totally random.
Thanks for the useful link.:) In general, I agree with everything there and it is not a surprise to me. However, what remains to be discussed is what constitutes a neutral change, beneficial in most cases and not interfering with the original character of the game, and which is already a step too far. As for the way the industry is shut down, my suggestions don't seem controversial, at least for me.

In my opinion, this element does not have to conflict with what newGRF adds. Even graphically, information about the threat of closure can be independent of what the add-on wants to show - it can even be an additional panel in the industry window.

Image

Generally, closing the industry could be based on three mechanics (which would be chosen automatically):
1. New improved mechanism with default extended shutdown time, where closing can be prevented.
2. Mechanism fully defined by the addon - in case of extension of newGRF specification; the addon would contain code that would force its mechanism to be used.
3. Mechanism partially modified by the addon - the situation would apply to older addons that do not contain information about the mechanism used; the default mechanism currently used in the game would be used.

As for the difficulty, unfortunately I am not able to fully assess what can cause the problem and what not.
Just extending the period from the appearance of information to the removal of the industry seems quite simple. It must be written somewhere, that the interval is 1 month. This is rather not defined otherwise by any addon.
A bit bigger problem, I think, can be canceling the threat. I don't know how to do it, but I see that such a mechanism works in the case of ECS, where the delivery of goods resets closing time.

However, if there were problems with compatibility, the game can always check whether it exists and in such a case show a warning about incompatibility and then when trying to start the game turn off the colliding addon or setting.
andythenorth wrote: 25 Nov 2019 07:50 My current ideas are:
- extend newgrf spec to give more information about industry closure
- change OpenTTD default experience to offer 'original vanilla' and 'improved' gameplay, where 'improved' is provided by including some new default grfs, which adjust known gameplay weak points. In the case that someone disagrees with those default grfs they can continue with original gameplay, or simply load alternative grfs, or fork OpenTTD and change the defaults. So nobody loses :)
The idea of ​​default newGRF somehow doesn't get to me. Several questions and significant doubts arise:
1. Where would they be stored / visible? As part of the newGRF addons, as a basic graphics set, or in a separate place?
2. Which way you could turn them off?
3. If this graphics had theirs place on the list of active addons, what if this list will be reset? Will you have to search for them or will they be added again automatically?

Because these should to be turned on by default and only in some cases turned off, in my opinion these graphics and solutions should be turned on or off from the game settings level.
andythenorth wrote: 25 Nov 2019 07:50 So the development goals for OpenTTD are good, but in this case they unfortunately lead to a less good gameplay for industries:
- players of the base game won't know that they need to use Manual Industries to avoid the shock closures
They do not have to. Nobody learned about all the possibilities that this game has on the first or the second day.;) It is enough for them to know that there are appropriate additions and that you can change their parameters in general, because not everyone knows it immediately. To make them easier to know about the existence of such addons, there should be some changes in the game interface, especially in the addons download window. There is a need to divide addons into subcategories and changes in the description of addons, which are very chaotic. Try to look, how do new players will know that FIRS, ECS, SPI, AuzInd are additions with a new industry?

By the way, I don't force my ideas, I just have some doubts. :)
I am sorry for may English. I know is bed.
milek7
Engineer
Engineer
Posts: 12
Joined: 18 Jul 2016 08:04

Re: Dying industries

Post by milek7 »

Hi :)
As for the difficulty, unfortunately I am not able to fully assess what can cause the problem and what not.
Just extending the period from the appearance of information to the removal of the industry seems quite simple. It must be written somewhere, that the interval is 1 month. This is rather not defined otherwise by any addon.
The problem is that when industry production change callback is defined by NewGRF, it is not core game code that decides when to close the industry, but this decision is delegated to the NewGRF itself, by returning 03: "The industry announces imminent closure, and is physically removed from the map next month."
https://newgrf-specs.tt-wiki.net/wiki/C ... e_.2829.29
While game could just ignore this request, the NewGRF internals could be left in confused state, as it already decided to close that industry. What exactly happens depends on specific NewGRF code, but further usage of that industry could result in its unexpected behaviour..
..well, almost. There is one situation when game already does such thing and ignores closure request: when industry of this type is last on the map, and (INDUSTRYBEH_CANCLOSE_LASTINSTANCE && !INDUSTRYBEH_DONT_INCR_PROD) is true. When this second condition holds, conceivably the same method could be used for prolonging closure periods. (and it shouldn't break anything, because such bug would also occur now without any game changes)

But I don't think there are any chances of getting this hack into core OpenTTD. (patchpacks maybe?) It comes round NewGRF back and adds behaviour on its own, without possibility of customization. NewGRF spec extension would be cleaner way to solve that, possibly by adding additional variables for current "protection against closure" period, way of showing message "future plans to closure in X months" and and leaving all business logic to NewGRF itself. (but eh, who is willing to add new features to spec, and even then who would implement that in NewGRF :P )
Last edited by milek7 on 29 Nov 2019 15:42, edited 2 times in total.
User avatar
andythenorth
Tycoon
Tycoon
Posts: 5656
Joined: 31 Mar 2007 14:23
Location: Lost in Music

Re: Dying industries

Post by andythenorth »

milek7 wrote: 29 Nov 2019 15:16NewGRF spec extension would be cleaner way to solve that, possibly by adding additional variables for current "protection against closure" period, way of showing message "future plans to closure in X months" and and leaving all business logic to NewGRF itself. (but eh, who is willing to add new features to spec, and even then who would implement that in NewGRF :P )
That can be done anyway - a closure period can be stored in a permanent register, and a message can be triggered once a month. :)
Post Reply

Return to “OpenTTD Suggestions”

Who is online

Users browsing this forum: Google Adsense [Bot] and 4 guests