Trainer Encounters - haven1433/HexManiacAdvance GitHub Wiki
Trainer Encounter Overview
Unlike text for NPCs or the item within a pokeball, data for trainer battles is stored in an entirely separate table. The script only says which trainer to battle. However, expanding that table isn't safe, since there's limited space in the save file to store which trainers have been defeated. So when creating a trainer, the most important thing to decide is whether you want to use existing trainer data or new trainer data.
If you use an existing trainer, HMA just needs to know which trainer you want to use. If you want HMA to generate a trainer for you, it asks for a bit more information, and attempts to overwrite an unused trainer's data in the table.
Aside from the trainer overworld sprite, HMA wants to know what sort of team the trainer should have. This means you can configure the template once and then use it multiple times to get a variety of 'grunt' trainers to fill a route, gym, dungeon, or base.
- Pokemon will always be close to the level you choose, with some variation. If a pokemon evolves by leveling up, HMA will only use the form that makes sense at that level. So no level 30 Charmanders or level 10 Charizards.
- Pokemon will usually be of the type you choose. Some variation is allowed.
- HMA will use your game's pokedex ordering to decide which pokemon to include in the teams. Note that the Kanto Regional Dex is just the beginning of the National Dex, so you probably want to use the Hoenn Dex for Ruby/Sapphire/Emerald and the National Dex for FireRed/LeafGreen. (You can edit your pokedex order from the Utilities menu.)
You can edit everything about the trainer after creating it. Common changes, like what the trainer says or what pokemon they use, can be edited directly in the map editor using the Event Template Controls in the left panel. Or you can click the Edit More
button to see the trainer in the trainer table: