Well done on the sheet, is there some way to make the columns sortable?
quote: Ace, theoretical question - would it (theoretically) be possible to reverse the functionality of the python script to re-write and update the lua files based on a singular master spreadsheet? |
There was a tool that does this but it stopped being used (maybe it stopped working, I'm not sure) ten or so years ago. Nowdays I rarely make large changes, but when I do I use unitdefs_posts to test them. Once the changes are stable I (or more likely
Sprung) apply them to the defs.
This means that the defs are not entirely based on what you see in the individual files. Under the hood I suspect (I have not looked that closely) that the defs loader is essentially a lua state that outputs a few tables. Most of the unit and weapon data is set as data in the Units directory, but there are some changes later on, especially to set our own defaults (such as default wreck values, or cost ratio). Even without unitdefs_posts there isn't a one-to-one correspondence between the defs and what ends up ingame. The engine itself has calculated defaults for things such as AoE speed. This all means that the only way to get the proper unitdefs and weapondefs is to make a widget that writes this information to a file. Parsing the files in some other way will often work, but it isn't a guarantee.
I mainly use stats like these for comparing BP/cost, energy/cost, shield charging, DPS/cost for AA, and how many shots a Dagger takes to kill a unit.
izirayd I can see the value in graphical editor programs, but I would always want some sort of human-readable and searchable data files underneath. Changing a few values or adding a field is simple when you don't have to go through a UI.