Page 1 of 1

Save-able game parameters

Posted: 17 Jan 2020 15:53
by Oncle Boris
While it's easy to make custom, recallable lists of NewGRF settings, the same can't be said of game parameters.

For instance, rather than setting all parameters manually when I start a new game, I'd like to be able to save and recall parameters for my most common types of games.

Any chance this may happen?

Re: Save-able game parameters

Posted: 17 Jan 2020 18:19
by jfs
It will be difficult to make a good GUI for, I think.

You can sort of do this by making console scripts that can then be executed, they can change game settings via a command, but it does require a bunch of fiddling.

Re: Save-able game parameters

Posted: 17 Jan 2020 22:47
by rowdog
The settings are stored in openttd.cfg so you can copy that to another file with a name of your choice (e.g. openttd-pax.cfg) and then start the game with a command line option:

Code: Select all

openttd -c openttd-pax.cfg
From there, it wouldn't be too hard to write a GUI launcher to select the config file and execute openttd with the proper command line.

Re: Save-able game parameters

Posted: 18 Jan 2020 18:50
by Oncle Boris
Thank you @rowdog nice hint!

Re: Save-able game parameters

Posted: 18 Jan 2020 21:55
by kamnet
jfs wrote: 17 Jan 2020 18:19 It will be difficult to make a good GUI for, I think.

You can sort of do this by making console scripts that can then be executed, they can change game settings via a command, but it does require a bunch of fiddling.
Could you not just have a simple select menu like with the NewGRF window, one button where you can click to save the configuration, one to open a window to select a configuration?

Re: Save-able game parameters

Posted: 18 Jan 2020 22:03
by jfs
kamnet wrote: 18 Jan 2020 21:55 Could you not just have a simple select menu like with the NewGRF window, one button where you can click to save the configuration, one to open a window to select a configuration?
Which parts of the configuration?
Do you include the Localisation things (display units etc.)? The Sound settings? Music volume? Newspaper settings? Various default settings for vehicles? Vehicle and economy game settings? Disaster settings? And so on and so on.
There's hundreds of settings in many categories, and you typically don't want to store the complete set.

Re: Save-able game parameters

Posted: 18 Jan 2020 22:08
by kamnet
Why not? We store the complete set when we save all the NewGRF settings, don't we? Why would you only save part of a configuration?

Re: Save-able game parameters

Posted: 18 Jan 2020 23:49
by LaChupacabra
I think that creating a good GUI, at least logically or visually, would not be that difficult. Certainly it would be worse in terms of coding and it could be quite or very laborious to do it well and not go back to it for a long time.
I have some ideas about what and how it could be done, but unfortunately I don't have enough time to describe it fully yet.
For now, I will post one of the graphics from this idea ...
Setting window - big improvement v1.0.png
Setting window - big improvement v1.0.png (19.46 KiB) Viewed 2311 times
Generally, the purpose of the changes I wanted to propose was to make all settings from the configuration file available in the settings window. In order not to increase chaos on the setting list, this would propably require rebuilding the entire layout.
In the presented case, all gameplay settings would have a separate tab and there it would be possible to choose a set of settings, as in the case of newGRF.