The International Simutrans Forum

 

Author Topic: Good paks are defined in a tab file instead in a pak  (Read 2598 times)

0 Members and 1 Guest are viewing this topic.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9566
  • Languages: De,EN,JP
Good paks are defined in a tab file instead in a pak
« on: October 30, 2013, 09:02:26 PM »
I propose to move the good definitions from pak files to an editable tab file.

The reason is that people want to modify prices and speed bonus etc. quite often. It would mean that the goods are saved with the game, which also could avoid crashes due to missing goods when loading a savegame.

Any objections?
« Last Edit: October 30, 2013, 11:18:41 PM by prissi »

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: paks are defined in a tab file instead in a pak
« Reply #1 on: October 30, 2013, 11:14:01 PM »
Is it likely to make loading slower?

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9566
  • Languages: De,EN,JP
Re: Good paks are defined in a tab file instead in a pak
« Reply #2 on: October 30, 2013, 11:21:10 PM »
The Theme does miss a word "Good pak" should be defined in tab files instead pak files. Those have three parameters, which could be parsed really quick.

And for networkgames, obviously these parameters need to be taken anyway from the savegame, once set. There are maximum 127 goods with 3 parameters and a name. This is rather not much extra info imho.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5543
  • Languages: EN, NO
Re: Good paks are defined in a tab file instead in a pak
« Reply #3 on: October 31, 2013, 06:08:10 AM »
It would mean that the goods are saved with the game, which also could avoid crashes due to missing goods when loading a savegame.

What if you have an existing save game, then install an add-on for its pak set with a new type of goods? Simutrans would have to merge these things every time, rather than rely on everything being in the save game. It could also need an ability to replace stored goods information in the same game with new data for the pak set, so that an existing game could take advantage of a rebalancing in a new version of the pak set.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9566
  • Languages: De,EN,JP
Re: Good paks are defined in a tab file instead in a pak
« Reply #4 on: October 31, 2013, 01:29:17 PM »
That is true for several parameters already, like the city rules. My idea:

- Network save => only use data in savegame.
- Normal game => info in game override pakset

I think it is time for a flag in the simuconf.tab to allow to override all settings in a savegame by local setting whenever zou are loading a game.

Offline greenling

  • Lounger
  • *
  • Posts: 1728
  • Simutransarchology it my hobby!
  • Languages: DE,EN
Re: Good paks are defined in a tab file instead in a pak
« Reply #5 on: October 31, 2013, 07:13:38 PM »
Hello Prissi
It´s possible to make a preview how the good.tab inside show out and work?