8 years ago
[Updated] Help Wanted: Writing SimData Files
I'm working on a tool (an much more advanced version of my current Mod Constructor program) that can generate tuning from scratch using the TDESC files. I've already got quite far into development on the XML portion, so I've begun work on generating SimData files. I extracted an unedited version of the SimData file for the "Lazy" trait and ran the BT file on it.
For this purpose, the program needs to generate SimData files from scratch, rather than read and edit existing ones. I'm very slowly learning the format, but it's complicated, so any help would be appreciated.
I'm currently working on generating the TableInfo variables. After analysing, I've figured out a few basic details: the first table is an "Object" table, then there are separate tables for different data types, ie there's a table for 32-bit integers, a table for 64-bit integers, a table for strings, etc. However, some values go into the main object table.
What determines which values should go into the main Object table and which should go into separate tables? And is there anything about how tables are organised that I haven't figured out yet?
I bet I'll encounter more problems after that. Creating a tool that can generate SimData is really tricky, but it'll make a huge difference in the end which will be worth it.
@SimGuruModSquad
UPDATE: I'm slowly but steadily starting to understand the format. From what I understand so far:
I have a lot of work ahead of me, but it's starting to become less and less confusing.
For this purpose, the program needs to generate SimData files from scratch, rather than read and edit existing ones. I'm very slowly learning the format, but it's complicated, so any help would be appreciated.
I'm currently working on generating the TableInfo variables. After analysing, I've figured out a few basic details: the first table is an "Object" table, then there are separate tables for different data types, ie there's a table for 32-bit integers, a table for 64-bit integers, a table for strings, etc. However, some values go into the main object table.
What determines which values should go into the main Object table and which should go into separate tables? And is there anything about how tables are organised that I haven't figured out yet?
I bet I'll encounter more problems after that. Creating a tool that can generate SimData is really tricky, but it'll make a huge difference in the end which will be worth it.
@SimGuruModSquad
UPDATE: I'm slowly but steadily starting to understand the format. From what I understand so far:
- "Object" tables are the ones with Schemas attached. The base table is always an object. I took a look at a Commodity SimData file (which is more complicated than the trait one) and found that TunableTuple tunables are also objects, which have their own schemas.
- Each column in the schema points to a value in the table.
- The object table references data in other tables For example, in the trait SimData file, the values for "ages" and "conflicting_traits" in table 0 are an offset that points to the data in table 1, which defines the list values.
- RowCount defines how many values there are in a list.
I have a lot of work ahead of me, but it's starting to become less and less confusing.