besteon / Ironmon-Tracker

A Lua script for the Bizhawk/mGBA emulator compatible with Pokemon Fire Red, Leaf Green, Ruby, Sapphire, and Emerald that tracks relevant data for the IronMon challenge.
MIT License
129 stars 45 forks source link

GameSettings cleanup #266

Closed Fellshadow closed 2 years ago

Fellshadow commented 2 years ago

A big ol' cleanup of the big pile of mess that is GameSettings.lua The GitHub changes comparison below may be hard to read, might be easier viewing the new resulting file directly here

This should hopefully be a lot simpler and easier to navigate / add new addresses to, but let me know your thoughts. I've done some brief testing on all currently supported games (i.e. checking it doesn't crash the tracker on load, and playing a tiny bit) and it seems to work fine but definitely want to double-check and do more thorough tests just in case i broke something lol

In the new file, addresses are grouped as such:

I've left a comment in each section detailing the formatting of the addresses, but here's a brief summary:

The process for adding a new address would simply be navigating to the relevant section for the address type, checking how it is formatted, and adding the new address in the right format to the local addresses table.