Digimon World 3 decomp
The European version, SLES_039.36
Loading...
Searching...
No Matches
report.h File Reference

STFGTREP.PRO: mode 0x1400, the report after a battle. More...

#include "engine/game.h"
Include dependency graph for report.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  BattleReward
 What a battle gives (STFGTREP_rewards) More...
 
struct  Evolution
 A Digimon a partner can learn, once the conditions are met. More...
 
struct  ReportBlink
 A blinking image of a partner's panel. More...
 
struct  ReportPartner
 The panel of a partner of the party (STFGTREP_createPartner) More...
 
struct  ReportPartnerWindows
 The children of a partner's panel. More...
 
struct  FightReport
 The main task of the screen (STFGTREP_createScreen) More...
 
struct  FightReportChildren
 The children of the main task. More...
 
struct  FightReportFuncs
 The overlay's helpers (STFGTREP_funcs) More...
 

Macros

#define OVL_NAME(name)   STFGTREP_##name
 The name of this overlay's copy of a function of src/shared/.
 
#define FILE_FGTREP_SPRITES   0x7A0
 The sprite archive the overlay loads.
 

Functions

void STFGTREP_updateScene (Task *task, FightReport **children)
 scene.c
 
void STFGTREP_startFader (ScreenFade *task, s32 fadeIn, s32 duration)
 
void STFGTREP_drawFader (ScreenFade *task)
 
void STFGTREP_updateFader (ScreenFade *task)
 
ScreenFade * STFGTREP_createFader (void)
 
void STFGTREP_createPartnerWindows (ReportPartner *partner, ReportPartnerWindows *windows)
 partner.c
 
void STFGTREP_fillPartnerWindows (ReportPartner *partner, ReportPartnerWindows *windows, s32 show)
 Fills a partner's panel with its name, level, exp and Digimon, or hides it.
 
void STFGTREP_drawPartner (ReportPartner *partner)
 Draws a partner's panel: the level and slot blinks, the cursor, the partner's animation and its frames.
 
s32 STFGTREP_rollExp (ReportPartner *partner)
 Rolls the shown exp towards the target, digit by digit; 0 once it is there.
 
void STFGTREP_runPartner (ReportPartner *partner, ReportPartnerWindows *windows)
 A panel's steps: it fades in and out, gives each slot's Digimon its exp, with the levels and skills that brings (giveDigimonExp, showDigimonLevelUp, giveNextSkill, markNextSkillKnown), then the partner's exp and the Digimon it learns (raisePartnerLevel, learnNextDigimon), each with its message.
 
void STFGTREP_updatePartner (ReportPartner *partner, ReportPartnerWindows *windows)
 A partner's panel task.
 
void STFGTREP_showPartner (ReportPartner *partner)
 ReportPartner.show: fades the panel in (substate 1)
 
void STFGTREP_hidePartner (ReportPartner *partner)
 ReportPartner.hide: fades the panel out (substate 11)
 
void STFGTREP_raisePartner (ReportPartner *partner)
 ReportPartner.raise: gives the exp to the partner's Digimon, with its new levels and skills (substate 20)
 
s32 STFGTREP_boostExp (ReportPartner *partner)
 Adds a fifth to the exp once, if the partner wears item 0x141.
 
void STFGTREP_selectPartner (ReportPartner *partner)
 ReportPartner.select: shows the cursor on the panel until its exp is given.
 
ReportPartner * STFGTREP_createPartner (FightReport *report, s32 index, s32 exp)
 Creates the panel of party member index, who gets exp.
 
void STFGTREP_createWindows (FightReport *report, FightReportChildren *children)
 report.c
 
void STFGTREP_drawReport (FightReport *report)
 Draws the report's message arrow, background, header and footer.
 
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 raise (selectNextPartner, showExp, hideExp), then the money and the item won (giveMoney, giveItem), and fades out (startFadeOut)
 
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 creates their panels.
 
FightReport * STFGTREP_createScreen (void)
 Creates the report (STFGTREP_updateReport) on the screen layer.
 
void STFGTREP_loadFiles (void)
 Loads the report's sprites and requests its texts, the Digimon names and the item names.
 
s32 STFGTREP_filesLoading (void)
 Whether STFGTREP_loadFiles's texts are still loading.
 
void STFGTREP_startFade (PanelAnim *fade, s32 fadeIn)
 fade.c
 
s32 STFGTREP_updateFade (PanelAnim *fade)
 
void STFGTREP_startLerp (MenuLerp *lerp, s32 from, s32 to, s32 frames)
 
s32 STFGTREP_updateLerp (MenuLerp *lerp)
 
void STFGTREP_raiseStats (s32 partner, s32 level)
 growth.c
 
s32 STFGTREP_addExp (s32 partner, s32 exp)
 Adds exp to a partner and raises its level, and its stats with it, as far as the exp reaches; whether it went up.
 
s32 STFGTREP_learnDigimon (s32 partner)
 Gives a partner the first Digimon of its evolution list (STFGTREP_evolutions) it hasn't yet and whose needs it meets: the Digimon it must have at a level, and a stat (1-6 battle stats, 7 the level, 8-14 resistances) of at least a value.
 
s32 STFGTREP_addDigimonExp (s32 partner, s32 id, s32 exp)
 Adds exp to one of a partner's Digimon and raises its level as far as the exp reaches, up to 99; whether it went up.
 
s32 STFGTREP_addSkill (s32 partner, s32 id)
 Gives one of a partner's Digimon the first skill whose level it has reached and that it hasn't yet (DigimonData.skills); the skill, or 0.
 
s32 STFGTREP_learnSkill (s32 partner, s32 id)
 Marks known (SKILL_KNOWN) the first skill of one of a partner's Digimon whose level it has reached (DigimonData.knownLevels); the skill, or 0.
 
s32 STFGTREP_getDigimonExp (s32 partner, s32 id, s32 exp, s32 used)
 The exp one of a partner's Digimon gets of a battle's: less as the partner goes up in level, shared by the Digimon used, at least 1 and at most 10, or 50 once the Digimon is past its expLevel.
 

Variables

s32 STFGTREP_levelExp [4]
 What a level adds to the exp the next one needs, by tier.
 
s32 STFGTREP_vitalCuts [4]
 What is taken from the HP and MP growth, by tier, and added at random.
 
s32 STFGTREP_vitalRandom [9]
 
s32 STFGTREP_statGains [6][9]
 A battle stat's gain by tier, from its growth plus 0-4 at random.
 
s32 STFGTREP_resistGains [8]
 A resistance's gain, from its growth plus 0-3 at random.
 
BattleReward STFGTREP_rewards []
 
FightReportFuncs STFGTREP_funcs
 
Evolution * STFGTREP_evolutions [PARTNER_COUNT]
 each partner's (STFGTREP_learnDigimon)
 
s32 STFGTREP_animations [][7]
 each partner Digimon's sprite frames, -1 ending them early
 

Detailed Description

STFGTREP.PRO: mode 0x1400, the report after a battle.

WFIGHTMN requests it when a battle ends; it goes through the party (getPartyMember) and shows the partners that went up a level, with their name and new level, from text file 0x56. Its one object is cut, in its link order, into src/battle/report's scene.c, partner.c, report.c, fade.c and growth.c, with its data in data/stfgtrep.c.

Definition in file report.h.

Macro Definition Documentation

◆ OVL_NAME

#define OVL_NAME (   name)    STFGTREP_##name

The name of this overlay's copy of a function of src/shared/.

Definition at line 14 of file report.h.

◆ FILE_FGTREP_SPRITES

#define FILE_FGTREP_SPRITES   0x7A0

The sprite archive the overlay loads.

Definition at line 20 of file report.h.

Function Documentation

◆ STFGTREP_updateScene()

void STFGTREP_updateScene ( Task *  task,
FightReport **  children 
)

scene.c

scene.c

Definition at line 8 of file scene.c.

Referenced by STFGTREP_start().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_startFader()

void STFGTREP_startFader ( ScreenFade *  task,
s32  fadeIn,
s32  duration 
)

◆ STFGTREP_drawFader()

void STFGTREP_drawFader ( ScreenFade *  task)

◆ STFGTREP_updateFader()

void STFGTREP_updateFader ( ScreenFade *  task)

◆ STFGTREP_createFader()

ScreenFade * STFGTREP_createFader ( void  )

Referenced by startFadeOut().

Here is the caller graph for this function:

◆ STFGTREP_createPartnerWindows()

void STFGTREP_createPartnerWindows ( ReportPartner *  partner,
ReportPartnerWindows *  windows 
)

partner.c

partner.c

Definition at line 7 of file partner.c.

Referenced by STFGTREP_updatePartner().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_fillPartnerWindows()

void STFGTREP_fillPartnerWindows ( ReportPartner *  partner,
ReportPartnerWindows *  windows,
s32  show 
)

Fills a partner's panel with its name, level, exp and Digimon, or hides it.

< FGTRPT: STFGTREP's

< FGTRPT: STFGTREP's

< DIGNAM

Definition at line 28 of file partner.c.

Referenced by learnNextDigimon(), raisePartnerLevel(), showDigimonLevelUp(), STFGTREP_rollExp(), and STFGTREP_runPartner().

Here is the caller graph for this function:

◆ STFGTREP_drawPartner()

void STFGTREP_drawPartner ( ReportPartner *  partner)

Draws a partner's panel: the level and slot blinks, the cursor, the partner's animation and its frames.

Definition at line 71 of file partner.c.

Referenced by STFGTREP_updatePartner().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_rollExp()

s32 STFGTREP_rollExp ( ReportPartner *  partner)

Rolls the shown exp towards the target, digit by digit; 0 once it is there.

Definition at line 165 of file partner.c.

Referenced by STFGTREP_runPartner().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_runPartner()

void STFGTREP_runPartner ( ReportPartner *  partner,
ReportPartnerWindows *  windows 
)

A panel's steps: it fades in and out, gives each slot's Digimon its exp, with the levels and skills that brings (giveDigimonExp, showDigimonLevelUp, giveNextSkill, markNextSkillKnown), then the partner's exp and the Digimon it learns (raisePartnerLevel, learnNextDigimon), each with its message.

< SYSTEM07

< FGTRPT: STFGTREP's

< SYSTEM10: a number counts up or down

Definition at line 324 of file partner.c.

Referenced by STFGTREP_updatePartner().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_updatePartner()

void STFGTREP_updatePartner ( ReportPartner *  partner,
ReportPartnerWindows *  windows 
)

A partner's panel task.

Definition at line 443 of file partner.c.

Referenced by STFGTREP_createPartner().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_showPartner()

void STFGTREP_showPartner ( ReportPartner *  partner)

ReportPartner.show: fades the panel in (substate 1)

Definition at line 476 of file partner.c.

Referenced by STFGTREP_createPartner().

Here is the caller graph for this function:

◆ STFGTREP_hidePartner()

void STFGTREP_hidePartner ( ReportPartner *  partner)

ReportPartner.hide: fades the panel out (substate 11)

Definition at line 481 of file partner.c.

Referenced by STFGTREP_createPartner().

Here is the caller graph for this function:

◆ STFGTREP_raisePartner()

void STFGTREP_raisePartner ( ReportPartner *  partner)

ReportPartner.raise: gives the exp to the partner's Digimon, with its new levels and skills (substate 20)

Definition at line 487 of file partner.c.

Referenced by STFGTREP_createPartner().

Here is the caller graph for this function:

◆ STFGTREP_boostExp()

s32 STFGTREP_boostExp ( ReportPartner *  partner)

Adds a fifth to the exp once, if the partner wears item 0x141.

Definition at line 492 of file partner.c.

Referenced by STFGTREP_createPartner().

Here is the caller graph for this function:

◆ STFGTREP_selectPartner()

void STFGTREP_selectPartner ( ReportPartner *  partner)

ReportPartner.select: shows the cursor on the panel until its exp is given.

Definition at line 506 of file partner.c.

Referenced by STFGTREP_createPartner().

Here is the caller graph for this function:

◆ STFGTREP_createPartner()

ReportPartner * STFGTREP_createPartner ( FightReport *  report,
s32  index,
s32  exp 
)

Creates the panel of party member index, who gets exp.

Definition at line 511 of file partner.c.

Referenced by STFGTREP_updateReport().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_createWindows()

void STFGTREP_createWindows ( FightReport *  report,
FightReportChildren *  children 
)

report.c

report.c

Definition at line 8 of file report.c.

Referenced by STFGTREP_updateReport().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_drawReport()

void STFGTREP_drawReport ( FightReport *  report)

Draws the report's message arrow, background, header and footer.

Definition at line 19 of file report.c.

Referenced by STFGTREP_updateReport().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_runReport()

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 raise (selectNextPartner, showExp, hideExp), then the money and the item won (giveMoney, giveItem), and fades out (startFadeOut)

Definition at line 166 of file report.c.

Referenced by STFGTREP_updateReport().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_updateReport()

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 creates their panels.

Definition at line 288 of file report.c.

Referenced by STFGTREP_createScreen().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_createScreen()

FightReport * STFGTREP_createScreen ( void  )

Creates the report (STFGTREP_updateReport) on the screen layer.

Definition at line 363 of file report.c.

Referenced by STFGTREP_updateScene().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ STFGTREP_loadFiles()

void STFGTREP_loadFiles ( void  )

Loads the report's sprites and requests its texts, the Digimon names and the item names.

< FGTRPT: STFGTREP's

< DIGNAM

< ITMNAM

Definition at line 373 of file report.c.

Here is the call graph for this function:

◆ STFGTREP_filesLoading()

s32 STFGTREP_filesLoading ( void  )

Whether STFGTREP_loadFiles's texts are still loading.

< FGTRPT: STFGTREP's

< DIGNAM

< ITMNAM

Definition at line 385 of file report.c.

◆ STFGTREP_startFade()

void STFGTREP_startFade ( PanelAnim *  fade,
s32  fadeIn 
)

◆ STFGTREP_updateFade()

s32 STFGTREP_updateFade ( PanelAnim *  fade)

◆ STFGTREP_startLerp()

void STFGTREP_startLerp ( MenuLerp *  lerp,
s32  from,
s32  to,
s32  frames 
)

◆ STFGTREP_updateLerp()

s32 STFGTREP_updateLerp ( MenuLerp *  lerp)

◆ STFGTREP_raiseStats()

void STFGTREP_raiseStats ( s32  partner,
s32  level 
)

growth.c

growth.c

Definition at line 8 of file growth.c.

Referenced by STFGTREP_addExp().

Here is the caller graph for this function:

◆ STFGTREP_addExp()

s32 STFGTREP_addExp ( s32  partner,
s32  exp 
)

Adds exp to a partner and raises its level, and its stats with it, as far as the exp reaches; whether it went up.

< what the training's intensities cost

< what the training's intensities cost

< what the training's intensities cost

Definition at line 77 of file growth.c.

Here is the call graph for this function:

◆ STFGTREP_learnDigimon()

s32 STFGTREP_learnDigimon ( s32  partner)

Gives a partner the first Digimon of its evolution list (STFGTREP_evolutions) it hasn't yet and whose needs it meets: the Digimon it must have at a level, and a stat (1-6 battle stats, 7 the level, 8-14 resistances) of at least a value.

The Digimon also takes the first free slot (below 3); the Digimon, or 0

Definition at line 131 of file growth.c.

◆ STFGTREP_addDigimonExp()

s32 STFGTREP_addDigimonExp ( s32  partner,
s32  id,
s32  exp 
)

Adds exp to one of a partner's Digimon and raises its level as far as the exp reaches, up to 99; whether it went up.

Definition at line 196 of file growth.c.

◆ STFGTREP_addSkill()

s32 STFGTREP_addSkill ( s32  partner,
s32  id 
)

Gives one of a partner's Digimon the first skill whose level it has reached and that it hasn't yet (DigimonData.skills); the skill, or 0.

< the sixth skill

Definition at line 234 of file growth.c.

◆ STFGTREP_learnSkill()

s32 STFGTREP_learnSkill ( s32  partner,
s32  id 
)

Marks known (SKILL_KNOWN) the first skill of one of a partner's Digimon whose level it has reached (DigimonData.knownLevels); the skill, or 0.

< the skill, from 1 (TECHS[id - 1])

Definition at line 258 of file growth.c.

◆ STFGTREP_getDigimonExp()

s32 STFGTREP_getDigimonExp ( s32  partner,
s32  id,
s32  exp,
s32  used 
)

The exp one of a partner's Digimon gets of a battle's: less as the partner goes up in level, shared by the Digimon used, at least 1 and at most 10, or 50 once the Digimon is past its expLevel.

Definition at line 278 of file growth.c.

Variable Documentation

◆ STFGTREP_levelExp

s32 STFGTREP_levelExp[4]
extern

What a level adds to the exp the next one needs, by tier.

Definition at line 1075 of file stfgtrep.c.

Referenced by STFGTREP_addExp().

◆ STFGTREP_vitalCuts

s32 STFGTREP_vitalCuts[4]
extern

What is taken from the HP and MP growth, by tier, and added at random.

Definition at line 1078 of file stfgtrep.c.

Referenced by STFGTREP_raiseStats().

◆ STFGTREP_vitalRandom

s32 STFGTREP_vitalRandom[9]
extern

Definition at line 1081 of file stfgtrep.c.

Referenced by STFGTREP_raiseStats().

◆ STFGTREP_statGains

s32 STFGTREP_statGains[6][9]
extern

A battle stat's gain by tier, from its growth plus 0-4 at random.

Definition at line 1086 of file stfgtrep.c.

Referenced by STFGTREP_raiseStats().

◆ STFGTREP_resistGains

s32 STFGTREP_resistGains[8]
extern

A resistance's gain, from its growth plus 0-3 at random.

Definition at line 1094 of file stfgtrep.c.

Referenced by STFGTREP_raiseStats().

◆ STFGTREP_rewards

BattleReward STFGTREP_rewards[]
extern

Definition at line 345 of file stfgtrep.c.

Referenced by giveDigimonExp(), giveMoney(), and STFGTREP_updateReport().

◆ STFGTREP_funcs

◆ STFGTREP_evolutions

Evolution* STFGTREP_evolutions[PARTNER_COUNT]
extern

each partner's (STFGTREP_learnDigimon)

Definition at line 1054 of file stfgtrep.c.

Referenced by STFGTREP_learnDigimon().

◆ STFGTREP_animations

s32 STFGTREP_animations[][7]
extern

each partner Digimon's sprite frames, -1 ending them early

Definition at line 1060 of file stfgtrep.c.

Referenced by STFGTREP_drawPartner().