67 if (report->
exp[report->
step] == 0) {
121 if (stats->
equip[4] == 0x142 || stats->
equip[5] == 0x142) {
174 for (i = 0; i < report->
count; i++) {
184 for (j = 0; j < report->
count; j++) {
242 switch (report->
step) {
260 for (i = 0; i < report->
count; i++) {
268 for (j = 0; j < report->
count; j++) {
294 switch (report->
state) {
309 for (i = 0; i < 3; i++) {
315 for (i = 0; i < 3; i++) {
318 for (j = 0; j < 3; j++) {
337 for (i = 0; i < report->
count; i++) {
ReportPartner * STFGTREP_createPartner(FightReport *report, s32 index, s32 exp)
Creates the panel of party member index, who gets exp.
GfxState GFX
GFX: the graphics state and its methods.
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_FIGHT_REPORT
FGTRPT: STFGTREP's.
#define TEXT_DIGIMON_NAMES
DIGNAM.
#define TEXT_ITEM_NAMES
ITMNAM.
#define FILE_MENU_SPRITES
Files the engine loads by number.
FileCache FILE_CACHE
The file cache.
#define SCREEN_LAYER
The layer over the whole screen that most modes create first and draw their menus on (FIELDSTG and ST...
BattleResult BATTLE_RESULT
#define PAD_PRESSED(button)
One button of pad 1: newly pressed, auto-repeated while held, or held.
static void hideExp(FightReport *report, FightReportChildren *children)
Fades the header out and hides the exp once the partner's raise is shown, moving on to the next partn...
static void giveItem(FightReport *report, FightReportChildren *children)
Gives the item the battle won, up to 99, and shows it in the message; with none the report ends.
static void startFadeOut(FightReport *report, FightReportChildren *children)
Starts fading the screen and the footer out and hides the message.
static void giveMoney(FightReport *report, FightReportChildren *children)
Gives the money the battle won, a fifth more with item 0x142 equipped, and shows it in the message.
void STFGTREP_runReport(FightReport *report, FightReportChildren *children)
The report while it runs: shows the panels, then for each partner that got exp its message and the ra...
static void showExp(FightReport *report, FightReportChildren *children)
Shows the current partner's exp in the message and in the exp window.
FightReport * STFGTREP_createScreen(void)
Creates the report (STFGTREP_updateReport) on the screen layer.
void STFGTREP_drawReport(FightReport *report)
Draws the report's message arrow, background, header and footer.
static void turnMessagePage(FightReport *report, FightReportChildren *children)
While the message types, cross shows its whole page; at a page end the arrow shows until cross,...
void STFGTREP_updateReport(FightReport *report, FightReportChildren *children)
The report's main task: loads the files, shares the battle's exp among the partners who fought and cr...
s32 STFGTREP_filesLoading(void)
Whether STFGTREP_loadFiles's texts are still loading.
void STFGTREP_loadFiles(void)
Loads the report's sprites and requests its texts, the Digimon names and the item names.
static void selectNextPartner(FightReport *report, FightReportChildren *children)
Selects the next partner that got exp and fades the header in; after the last one goes on to the mone...
void STFGTREP_createWindows(FightReport *report, FightReportChildren *children)
Creates the report's text windows: the exp, its label and the two-line message.
STFGTREP.PRO: mode 0x1400, the report after a battle.
ScreenFade * STFGTREP_createFader(void)
#define FILE_FGTREP_SPRITES
The sprite archive the overlay loads.
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.
void initSpriteDrawer(SpriteDrawer *obj)
Clears a sprite drawer to neutral (no scale, gray tint, follows the scroll), gives it its methods and...
BattleReward STFGTREP_rewards[]
FightReportFuncs STFGTREP_funcs
s16 member
the party member whose accessory adds money
s16 battle
row of STFGTREP_rewards
struct BattleResult::@9 partners[3]
u8 used[3]
the Digimon of each slot was used
s16 item
the item won, 0 for none
s32 exp
shared by the partners who fought
The children of the main task.
ReportPartner * partners[3]
s32(* filesLoading)(void)
void(* startFade)(PanelAnim *fade, s32 fadeIn)
s32(* updateFade)(PanelAnim *fade)
The main task of the screen (STFGTREP_createScreen)
s32 arrowOn
the message waits for a button
s32 count
partners in the party
void(* setSubstate)(struct FightReport *task, s32 substate)
s32 exp[3]
what each one gets
s32 used
Digimon used in the battle.
void(* nextState)(struct FightReport *task)
s32 bgSkip
the background moves every other frame
s32(* isLoading)(s32 file)
void(* request)(s32 file)
void *(* getEntry)(u32 fileAndIndex)
struct PartnerStats *(* getPartnerStats)(s32 partner)
void(* requestMode)(s32 mode, s32 arg)
s32(* getPartyMember)(u32 index)
s8 items[0x193]
counts, up to 99
s32 fieldMode
where the menu returns to
A partner Digimon from its name on (Partner.info), as getPartnerStats gives it.
void(* show)(struct ReportPartner *partner)
void(* raise)(struct ReportPartner *partner)
void(* select)(struct ReportPartner *partner)
s32(* boostExp)(struct ReportPartner *partner)
void(* hide)(struct ReportPartner *partner)
void(* start)(struct ScreenFade *fade, s32 fadeIn, s32 frames)
TASK_DONE when done.
short(* playSound)(s32 id)
returns the voice of a key-on
Draws sprites from a sprite sheet (such as file 0x277, the menu graphics): a sheet has a table of fra...
void(* setScale)()
(x, y, z), ONE = 1.0
void(* setLayerId)()
(id, depth)
void(* setClutRow)()
(row)
void(* draw)()
(sheet, frame, x, y)
void(* setTexture)()
(x, y)
A text window (createTextWindow): up to six text buffers (0 is shown, 1-5 are "work" buffers that con...
s32(* isWaitingForButton)()
s32(* isFinished)()
s32: callers don't truncate the result to a byte
void(* setRightAlign)()
no prototype: callers would truncate u8 args
void(* setLines)()
no prototype: callers would truncate u8 args
void(* setVisible)(struct TextWindow *obj, u8 arg)
Uploads TIM images to VRAM (initTimLoader); acts on TIM_LOADER.
void(* setImagePos)()
(x, y)
void(* loadArchive)()
(archive): each image 64 halfwords to the right
void * createTask(void(*update)(), s32 size, s32 childrenSize)
createTaskWithId for a task nothing needs to find
TextWindow * createTextWindow(s16 layerId, s16 style, s16 x, s16 y)
A text window on a layer, in a font style, at (x, y)
void initTimLoader(TimLoader *obj)
Clears a TIM loader, gives it its methods and binds it.