Difference between revisions of "Quick Stat Tweaks"

From Zero-K
Jump to navigation Jump to search
(Created page with "The Tweak Units modoption can be used to modify many unit and weapon parameters. It can be used for rapidly testing balance changes or just for making a quick game mode. It ha...")
 
Line 2: Line 2:
  
 
[[File:Tweakunitswindow.jpg]]
 
[[File:Tweakunitswindow.jpg]]
 +
 +
== Workflow ==
 +
The Tweak Units modoption overwrites unit paramers (called unitDefs) as they are loaded. The modoption requires a base64 encoded lua array of differences. Here is how to use it.
 +
* Make a lua table in an empty file.
 +
* For each unit you wish to modify, add an empty table indexed by the internal name of the unit to your table.
 +
* Search for the units you wish to modify in the [https://github.com/ZeroK-RTS/Zero-K/blob/master/units Zero-K repository].
 +
* Copy the parameters you wish to modify into the table, maintaining the structure of the unitDef table.
 +
* [https://www.base64encode.org/ Base 64 encode] your table.
 +
* Put the base 64 encoding of your table into the Tweak Units modoption.
 +
* Start the game.
 +
* Check infolog.txt in your install directory and fix your syntax errors.
 +
 +
Check out the [https://springrts.com/wiki/Gamedev:UnitDefs unit def] and [https://springrts.com/wiki/Gamedev:WeaponDefs weapon def] pages on the SpringRTS wiki for definitions of many of the parameters.
 +
 +
== Example ==

Revision as of 22:19, 12 November 2019

The Tweak Units modoption can be used to modify many unit and weapon parameters. It can be used for rapidly testing balance changes or just for making a quick game mode. It has limitations and should not be used for large mod projects, see Mod Creation to get started on full modding.

Tweakunitswindow.jpg

Workflow

The Tweak Units modoption overwrites unit paramers (called unitDefs) as they are loaded. The modoption requires a base64 encoded lua array of differences. Here is how to use it.

  • Make a lua table in an empty file.
  • For each unit you wish to modify, add an empty table indexed by the internal name of the unit to your table.
  • Search for the units you wish to modify in the Zero-K repository.
  • Copy the parameters you wish to modify into the table, maintaining the structure of the unitDef table.
  • Base 64 encode your table.
  • Put the base 64 encoding of your table into the Tweak Units modoption.
  • Start the game.
  • Check infolog.txt in your install directory and fix your syntax errors.

Check out the unit def and weapon def pages on the SpringRTS wiki for definitions of many of the parameters.

Example