28 for (i = 0; i < 3; i++) {
33 units[0].
id = digimon;
44 for (i = 0; i < 3; i++) {
51 if (entry->
item != 0) {
88 for (i = 0; i < 2; i++) {
102 for (i = 0; i < 3; i++) {
121 for (i = 0; i < 3; i++) {
122 if (slots[i] == unit->
id) {
149 for (i = 0; i < 3; i++) {
Battle FIGHTSTG_battle
the battle: its fighters, speed and drawing functions
void FIGHTSTG_queueRecovery(u8 side, s32 fighter, s32 big)
Queues a fighter's recovery of HP (event 6, with what getHeal takes as big), or sets the one already ...
#define FIGHTSTG_CREATE_LAYERS(screen, frontCallbacks)
The body of WFIGHTMN's and WFIGHTTS's layer setups: the display and the battle's layers on SCREEN (a ...
BattleTableEntry *(* FIGHTSTG_battleTableFunc)(s32 id)
how the fight stage and WFIGHTMN read the battle table
DigimonData DIGIMON_DATA[55]
55 entries: the 52 Digimon, then three placeholders (0x1D4-0x1D6)
GameState GAME
The save data, the game mode and the methods.
#define STAT_LEVEL
Indices of a partner's stats (PartnerStats.stats, computeStats, setStat)
BattleResult BATTLE_RESULT
WFIGHTMN.PRO: the battle's sub-overlay.
#define WFIGHTMN_RECOVERY_ITEM
The item a partner can equip that makes FIGHTSTG's FIGHTSTG_queueRecovery act on it at the start of t...
void WFIGHTMN_createLayers(void)
Sets up the display and the battle's layers.
s32 WFIGHTMN_rollAmbush(void)
Checks the chance in BATTLE_SETUP.ambushChance, scaled by how far the first partner's level and the f...
void WFIGHTMN_markFought(void)
Marks in BATTLE_RESULT that the current partner fought, and with which of its slots' Digimon if it is...
void WFIGHTMN_checkEquip(s32 member)
Queues a recovery (FIGHTSTG_queueRecovery) for party member MEMBER's partner when it has WFIGHTMN_REC...
static void WFIGHTMN_setStat(s16 *cur, s16 *max, s16 value)
Sets a stat and its maximum.
void WFIGHTMN_markPicked(BattleMenu *task, BattleMenuChildren *children)
Records in BATTLE_RESULT that the partner of the player's turn fought, and which of its digivolution ...
void WFIGHTMN_initFighters(s32 digimon)
Fills the battle's fighters: the party's partners (the first one with the id DIGIMON) and the encount...
void WFIGHTMN_checkParty(void)
Checks each of the party's three partners for WFIGHTMN_RECOVERY_ITEM (WFIGHTMN_checkEquip)
One of the battle's fighters, three on each side (WFIGHTMN's BattleUnit): a partner's HP and MP go ba...
s16 id
the Digimon (DIGIMON_DATA)
struct BattleResult::@9 partners[3]
u8 used[3]
the Digimon of each slot was used
u8 ambushChance
a chance that WFIGHTMN scales by level
s32 active[2]
each side's fighter
BattleFighter fighters[2][3]
s16 item
what the enemy may leave
Digimon definition (DIGIMON_DATA, 52 of them; the first 8 are the partners)
struct PartnerStats *(* getPartnerStats)(s32 partner)
s32(* getPartyMember)(u32 index)
s32(* getPartnerSlots)()
(partner, s16 *out): the count
Partner partners[PARTNER_COUNT]
A partner Digimon from its name on (Partner.info), as getPartnerStats gives it.
s32 arg
the action's: the item, the technique, or the party slot of the partner that digivolves or switches o...
s32 digimon
the Digimon a partner changes into, or the one it switches to
s32(* next)(void)
0 to RANDOM_COUNT - 1
RECT WFIGHTMN_screen
The screen its layers cover.