Commit Graph

8 Commits

Author SHA1 Message Date
Benjamin Popp
d13613f431 Improve lvlMoves member name
This name appears in the table tool. Make it more helpful.
2019-11-02 22:15:24 -05:00
Benjamin Popp
2900e252f9 Allow tables to include integer-bounded fields
Integer bounded fields work a lot like table-matched fields. But instead of having an option of every entry in the table, it's just an option of every entry less than the given number.

* Also moved `GetOptions` to `ModelCacheScope` since no one else is using it.
* Also updated `ArrayRunEnumSegment` to use cache scopes.
* trainerdata makes use of this feature
2019-10-28 15:04:03 -05:00
Benjamin Popp
ecc0ceee33 Tutor fix
tutor compatibility was finding the wrong data.
2019-10-28 08:33:50 -05:00
Benjamin Popp
0c55136f2a add basic trainer support
Trainer tables include a nested pointer, which works a bit weird because the pointer points to a different data structure depending on the `structType`. The structure is a table, but won't be named. Since that pointer will require some more changes, for now we're just adding the parent table - the trainers.
2019-10-27 21:24:53 -05:00
Benjamin Popp
6827faa013 Add links into table tool
To facilitate faster editing, the table tool enums and bitarrays now include links to their sources. This should allow the user to jump to a source faster for when they want to add a new option to a list, such as adding a new type or a new item.
2019-10-21 22:45:20 -05:00
Benjamin Popp
71485d0743 Fixing more tests
everything is working at this point except Gaia
2019-10-19 19:44:08 -05:00
Benjamin Popp
42b3d4349e Hardcoded Tables improvements
It now works for all existing tables with all 5 base roms.
2019-10-19 13:29:32 -05:00
Benjamin Popp
18c714e4cc hard-code stage 1
The AutoSearchModel is nifty, but seems to have trouble in a lot of situations where data isn't in the format I expect.

However, I've noticed that while many romhacks move tables around, a lot less of them move code around. So I can depend on most of the pointers to those tables still being in the same spot.

Based on this idea, I've created a new "HardcodeTablesModel" that uses known pointer locations to find tables instead of just searching for tables based on their format. This lets me simplify a lot of the logic, reducing it to basically a pointer lookup in many cases.

Most of the tests for FireRed are passing now using the new HardcodeTablesModel. I'll continue looking into issues from FireRed and the other baseroms in the next update.
2019-10-18 23:03:48 -05:00