The International Simutrans Forum

 

Author Topic: Ability to save and load game to file  (Read 1126 times)

0 Members and 1 Guest are viewing this topic.

Offline jk271

  • *
  • Posts: 292
  • Languages: CZ, EN, DE
Ability to save and load game to file
« on: February 06, 2012, 08:40:54 PM »
It would be very nice to have an option dialog to save (and load) my setting from settings dialog (opened from new world dialogue) similar to saming saving and loading games from/to file.

Edit:

« Last Edit: February 06, 2012, 11:10:39 PM by jk271 »

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9518
  • Languages: De,EN,JP
Re: Ability to save and load game to file
« Reply #1 on: February 06, 2012, 08:58:27 PM »
That is in principle very easy. YOu just have to stop to load a game after the settings.

Offline jk271

  • *
  • Posts: 292
  • Languages: CZ, EN, DE
Re: Ability to save and load game to file
« Reply #2 on: February 07, 2012, 12:04:43 AM »
I have not expressed myself exactly.
My idea to have more files with settings (more variants) that can be loaded (or saved) by user from settings dialog.
Example:
I will use one set of setting (file1) for small maps (256x256) - probably default pak settings.
Another setttings (file2) for large maps (2048x2048) would have e.g. double  size of factory_spacing and minimum_city_distance, different bits_per_month, ...

When I want to play new game, I could load one of predefined settings, change map size, generate new map and play.

I have more simuconf(_my_variant).tab files today. Before playing I have to rename most suitable one to simuconf.tab (or create a symlink) and than play with favourite settings. Having a dialogue for loading particular file would be useful.

There is a file settings.xml in simutrans directory. So I assume, that a way for loading and saving settings already exists.
« Last Edit: February 07, 2012, 01:31:53 PM by jk271 »

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9518
  • Languages: De,EN,JP
Re: Ability to save and load game to file
« Reply #3 on: February 07, 2012, 01:39:48 PM »
Yes, very simple to add. Might be a good first contribution ;)

Offline jk271

  • *
  • Posts: 292
  • Languages: CZ, EN, DE
Re: Ability to save and load game to file
« Reply #4 on: February 09, 2012, 08:45:19 PM »
There are finance window, help files and some ships for pak64 in my queue now. I will push_back() this request there too. :)