18 for (i = 0, index = -1; i < 3; i++) {
31 current = fighter->
id;
33 for (i = 0; i < task->
count; i++) {
34 if (windows[i + 1] ==
NULL) {
40 if (current == task->
ids[i]) {
52 0, 168, 147, 19, 36, 167, 146, 19,
72 switch (task->
state) {
79 for (i = 0; i < 3; i++) {
80 if (task->
slots[i] >= 3) {
99 if (pressed & (1 <<
PAD_R1)) {
100 if (++task->
page == 3) {
107 if (pressed & (1 <<
PAD_L1)) {
108 if (--task->
page < 0) {
119 current = fighter->
prevId;
121 current = fighter->
id;
Battle FIGHTSTG_battle
the battle: its fighters, speed and drawing functions
MenuCursor * FIGHTSTG_createCursor(CursorLayout *layout)
Creates a menu cursor laid out by layout.
#define BATTLE_LAYER_MENUS
the HUD, the menus and the messages
FIGHTSTG.PRO: the battle.
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 TASK_INIT
Tasks: every game object is a task, a heap block that starts with this header and is updated once per...
#define TEXT_DIGIMON_NAMES
DIGNAM.
FileCache FILE_CACHE
The file cache.
DigimonData *(* GET_DIGIMON)(s32 id)
getDigimon for the overlays, in the small data (.sdata) between game/items.c's and file/file_table....
PadState PAD
Controller input: cleared by initPad, then the methods.
PartnerInfo * FIGHTSTG_createPartnerInfo(s32 partner, s32 page, s32 slot)
Shows page page about the partner in slot (0 for itself)
SoundState SOUND
rsin and rcos (libgte) read rsin_tbl[a - 0x800] and the like: their addresses before the table fall i...
#define SOUND_MENU_CONFIRM
SYSTEM07.
#define SOUND_MENU_CANCEL
SYSTEM01.
#define SOUND_MENU_MOVE
SYSTEM06.
One of the battle's fighters, three on each side (WFIGHTMN's BattleUnit): a partner's HP and MP go ba...
u8 temporary
id is a temporary Digimon
s16 id
the Digimon (DIGIMON_DATA)
s16 prevId
its own id while id is a temporary one
s32 active[2]
each side's fighter
BattleFighter fighters[2][3]
A menu cursor's layout, which FIGHTSTG_createCursor copies into its task: a highlight bar over count ...
Digimon definition (DIGIMON_DATA, 52 of them; the first 8 are the partners)
u8 nameId
string in file 0x4F
s32(* getPartyMember)(u32 index)
s32(* getPartnerSlots)()
(partner, s16 *out): the count
s32(* getPressed)(s32 pad)
void(* setState)(struct PartnerInfo *task, s32 state)
short(* playSound)(s32 id)
returns the voice of a key-on
A text window (createTextWindow): up to six text buffers (0 is shown, 1-5 are "work" buffers that con...
void(* setPalette)(struct TextWindow *obj, u8 arg)
void * createTask(void(*update)(), s32 size, s32 childrenSize)
createTaskWithId for a task nothing needs to find
#define PALETTE_WHITE
The text windows' palettes (TextWindow.palette, setPalette): rows of the font's CLUTs,...
#define PALETTE_GREY
what is unavailable
TextWindow * createTextWindow(s16 layerId, s16 style, s16 x, s16 y)
A text window on a layer, in a font style, at (x, y)