The evolution of game data

In the neverending battle for more configuration and less compilation, game data goes up a seemingly infinite ladder of complexity:

  • Int constant in the C++ source
  • Int constant in a config file
  • String constant in a config file
  • A script returning a string value, in a config file, evaluated to produce the string value

A good scripting language should collapse all of this into a single form: a single line of text somewhere saying “Gaul.Swordsman.MaxHealth = 80″. You wouldn’t write it in C++, because a good scripting language should never require you to write game code in C++. A good scripting language should be a good config-file language. A good scripting language should make the difference between strings and ints trivial, if not nonexistent. And finally, a good scripting language should make it possible to write “Gaul.Swordsman.MaxHealth = Gaul.BaseHealth * 0.8″ without too much trouble (e.g. explicitly including “GaulBaseParams.h” everywhere).

Comments are closed.