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

The game modes' overlays and the task that runs them (system/overlay.c) More...

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

Go to the source code of this file.

Data Structures

struct  OverlayLoader
 Loads the overlay of the current mode (OVERLAY_LOADER) More...
 

Macros

#define FILE_CARDGAME   0x161
 The mode overlays' files (MODE_OVERLAY_FILES), by their disc names: each one's sector count in FILE_SECTOR_COUNTS is its .PRO file's.
 
#define FILE_STDGNAME   0x162
 
#define FILE_CNTY_SEL   0x165
 
#define FILE_FIELDSTG   0x166
 
#define FILE_FIGHTSTG   0x167
 
#define FILE_SHOCKTST   0x168
 
#define FILE_SOUNDTST   0x169
 
#define FILE_STAGSLCT   0x184
 
#define FILE_STCRDABM   0x185
 
#define FILE_STCRDDEK   0x1CA
 
#define FILE_STCRDSHP   0x1CE
 
#define FILE_STDWTITL   0x1D0
 
#define FILE_STFGTREP   0x1D1
 
#define FILE_STGDGLAB   0x1EC
 
#define FILE_STGMCARD   0x1EE
 
#define FILE_STGTRAIN   0x1F2
 
#define FILE_STITSHOP   0x205
 
#define FILE_STPLNMET   0x206
 
#define FILE_STSTATUS   0x207
 

Functions

void updateModeTask (Task *task, Task **children)
 The root task (created by main): loads the overlay of the current game mode and calls its entry point, which returns the mode's top task.
 
void * createModeTask (void)
 Creates the task that runs the current mode (updateModeTask)
 
void loadModeOverlay (void)
 Copies the overlay of the current mode (mode >> 8) to OVERLAY_ADDRESS.
 
void loadSubOverlay (s32 id)
 Copies a file to the second overlay area (SUB_OVERLAY_ADDRESS)
 
Task * FIELDSTG_start (void)
 The mode overlays' entry points, which MODE_ENTRY_POINTS holds: declared here, where the executable and every overlay see them, as the overlays' headers can't be included together.
 
Task * STCRDDEK_start (void)
 
Task * STPLNMET_start (void)
 The mode's entry point (MODE_ENTRY_POINTS): starts the root task.
 
Task * FIGHTSTG_start (void)
 The mode's entry point (MODE_ENTRY_POINTS): starts the root task.
 
Task * CARDGAME_start (void)
 The mode's entry point (MODE_ENTRY_POINTS)
 
Task * SOUNDTST_start (void)
 Creates the sound test's root task.
 
Task * SHOCKTST_start (void)
 
Task * STGTRAIN_start (void)
 The mode's entry point (MODE_ENTRY_POINTS): starts the root task.
 
Task * STDGNAME_start (void)
 The mode's entry point (MODE_ENTRY_POINTS): starts the root task.
 
Task * STGMCARD_start (void)
 
Task * STGDGLAB_createScene (void)
 Starts the mode: creates its scene task.
 
Task * STDWTITL_start (void)
 The overlay's entry: creates its main task (STDWTITL_tickScreen)
 
Task * STITSHOP_start (void)
 
Task * STSTATUS_start (void)
 
Task * STCRDABM_start (void)
 
Task * STCRDSHP_start (void)
 
Task * STFGTREP_start (void)
 The mode's entry point (MODE_ENTRY_POINTS)
 
Task * STAGSLCT_start (void)
 Creates the stage select's root task.
 
Task * CNTY_SEL_start (void)
 The mode's entry point (MODE_ENTRY_POINTS): clears VRAM, starts the root task and loads the screen's sound bank.
 

Variables

OverlayLoader OVERLAY_LOADER
 
Task *(* MODE_ENTRY_POINTS [])(void)
 Each mode's overlay (mode >> 8): its entry point and its file.
 
s32 MODE_OVERLAY_FILES []
 
u8 OVERLAY_VRAM []
 the memory map of mk/version/<version>.mk, which the Makefile gives the linker: where the overlays and the stages load
 
u8 STAGE_VRAM []
 
void *const OVERLAY_ADDRESS
 the two areas the loader copies to, at those addresses (system/main.c)
 
void *const SUB_OVERLAY_ADDRESS
 

Detailed Description

The game modes' overlays and the task that runs them (system/overlay.c)

Definition in file overlay.h.

Macro Definition Documentation

◆ FILE_CARDGAME

#define FILE_CARDGAME   0x161

The mode overlays' files (MODE_OVERLAY_FILES), by their disc names: each one's sector count in FILE_SECTOR_COUNTS is its .PRO file's.

The Japanese disc numbers them as the USA one does

Definition at line 41 of file overlay.h.

◆ FILE_STDGNAME

#define FILE_STDGNAME   0x162

Definition at line 42 of file overlay.h.

◆ FILE_CNTY_SEL

#define FILE_CNTY_SEL   0x165

Definition at line 43 of file overlay.h.

◆ FILE_FIELDSTG

#define FILE_FIELDSTG   0x166

Definition at line 44 of file overlay.h.

◆ FILE_FIGHTSTG

#define FILE_FIGHTSTG   0x167

Definition at line 45 of file overlay.h.

◆ FILE_SHOCKTST

#define FILE_SHOCKTST   0x168

Definition at line 46 of file overlay.h.

◆ FILE_SOUNDTST

#define FILE_SOUNDTST   0x169

Definition at line 47 of file overlay.h.

◆ FILE_STAGSLCT

#define FILE_STAGSLCT   0x184

Definition at line 48 of file overlay.h.

◆ FILE_STCRDABM

#define FILE_STCRDABM   0x185

Definition at line 49 of file overlay.h.

◆ FILE_STCRDDEK

#define FILE_STCRDDEK   0x1CA

Definition at line 50 of file overlay.h.

◆ FILE_STCRDSHP

#define FILE_STCRDSHP   0x1CE

Definition at line 51 of file overlay.h.

◆ FILE_STDWTITL

#define FILE_STDWTITL   0x1D0

Definition at line 52 of file overlay.h.

◆ FILE_STFGTREP

#define FILE_STFGTREP   0x1D1

Definition at line 53 of file overlay.h.

◆ FILE_STGDGLAB

#define FILE_STGDGLAB   0x1EC

Definition at line 54 of file overlay.h.

◆ FILE_STGMCARD

#define FILE_STGMCARD   0x1EE

Definition at line 55 of file overlay.h.

◆ FILE_STGTRAIN

#define FILE_STGTRAIN   0x1F2

Definition at line 56 of file overlay.h.

◆ FILE_STITSHOP

#define FILE_STITSHOP   0x205

Definition at line 57 of file overlay.h.

◆ FILE_STPLNMET

#define FILE_STPLNMET   0x206

Definition at line 58 of file overlay.h.

◆ FILE_STSTATUS

#define FILE_STSTATUS   0x207

Definition at line 59 of file overlay.h.

Function Documentation

◆ updateModeTask()

void updateModeTask ( Task *  task,
Task **  children 
)

The root task (created by main): loads the overlay of the current game mode and calls its entry point, which returns the mode's top task.

Once a new mode is requested it dies, and main creates it again.

Definition at line 28 of file overlay.c.

Referenced by createModeTask().

Here is the caller graph for this function:

◆ createModeTask()

void * createModeTask ( void  )

Creates the task that runs the current mode (updateModeTask)

Definition at line 48 of file overlay.c.

Referenced by main().

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

◆ loadModeOverlay()

void loadModeOverlay ( void  )

Copies the overlay of the current mode (mode >> 8) to OVERLAY_ADDRESS.

Definition at line 53 of file overlay.c.

Here is the call graph for this function:

◆ loadSubOverlay()

void loadSubOverlay ( s32  id)

Copies a file to the second overlay area (SUB_OVERLAY_ADDRESS)

Definition at line 68 of file overlay.c.

Here is the call graph for this function:

◆ FIELDSTG_start()

Task * FIELDSTG_start ( void  )

The mode overlays' entry points, which MODE_ENTRY_POINTS holds: declared here, where the executable and every overlay see them, as the overlays' headers can't be included together.

The mode overlays' entry points, which MODE_ENTRY_POINTS holds: declared here, where the executable and every overlay see them, as the overlays' headers can't be included together.

Definition at line 34 of file start.c.

Here is the call graph for this function:

◆ STCRDDEK_start()

Task * STCRDDEK_start ( void  )

◆ STPLNMET_start()

Task * STPLNMET_start ( void  )

The mode's entry point (MODE_ENTRY_POINTS): starts the root task.

Definition at line 43 of file scene.c.

Here is the call graph for this function:

◆ FIGHTSTG_start()

Task * FIGHTSTG_start ( void  )

The mode's entry point (MODE_ENTRY_POINTS): starts the root task.

Definition at line 32 of file start.c.

Here is the call graph for this function:

◆ CARDGAME_start()

Task * CARDGAME_start ( void  )

The mode's entry point (MODE_ENTRY_POINTS)

Definition at line 51 of file scene.c.

Here is the call graph for this function:

◆ SOUNDTST_start()

Task * SOUNDTST_start ( void  )

Creates the sound test's root task.

Definition at line 633 of file sound_test.c.

Here is the call graph for this function:

◆ SHOCKTST_start()

Task * SHOCKTST_start ( void  )

◆ STGTRAIN_start()

Task * STGTRAIN_start ( void  )

The mode's entry point (MODE_ENTRY_POINTS): starts the root task.

Definition at line 45 of file scene.c.

Here is the call graph for this function:

◆ STDGNAME_start()

Task * STDGNAME_start ( void  )

The mode's entry point (MODE_ENTRY_POINTS): starts the root task.

Definition at line 34 of file scene.c.

Here is the call graph for this function:

◆ STGMCARD_start()

Task * STGMCARD_start ( void  )

◆ STGDGLAB_createScene()

Task * STGDGLAB_createScene ( void  )

Starts the mode: creates its scene task.

Definition at line 13 of file scene.c.

Here is the call graph for this function:

◆ STDWTITL_start()

Task * STDWTITL_start ( void  )

The overlay's entry: creates its main task (STDWTITL_tickScreen)

Definition at line 77 of file scene.c.

Here is the call graph for this function:

◆ STITSHOP_start()

Task * STITSHOP_start ( void  )

◆ STSTATUS_start()

Task * STSTATUS_start ( void  )

◆ STCRDABM_start()

Task * STCRDABM_start ( void  )

◆ STCRDSHP_start()

Task * STCRDSHP_start ( void  )

◆ STFGTREP_start()

Task * STFGTREP_start ( void  )

The mode's entry point (MODE_ENTRY_POINTS)

Definition at line 35 of file scene.c.

Here is the call graph for this function:

◆ STAGSLCT_start()

Task * STAGSLCT_start ( void  )

Creates the stage select's root task.

Definition at line 756 of file stage_select.c.

Here is the call graph for this function:

◆ CNTY_SEL_start()

Task * CNTY_SEL_start ( void  )

The mode's entry point (MODE_ENTRY_POINTS): clears VRAM, starts the root task and loads the screen's sound bank.

Definition at line 73 of file country_select.c.

Here is the call graph for this function:

Variable Documentation

◆ OVERLAY_LOADER

OverlayLoader OVERLAY_LOADER
extern

◆ MODE_ENTRY_POINTS

Task *(* MODE_ENTRY_POINTS[])(void) ( void  )
extern

Each mode's overlay (mode >> 8): its entry point and its file.

Definition at line 4 of file overlay.c.

Referenced by updateModeTask().

◆ MODE_OVERLAY_FILES

s32 MODE_OVERLAY_FILES[]
extern

Definition at line 12 of file overlay.c.

Referenced by loadModeOverlay().

◆ OVERLAY_VRAM

u8 OVERLAY_VRAM[]
extern

the memory map of mk/version/<version>.mk, which the Makefile gives the linker: where the overlays and the stages load

◆ STAGE_VRAM

u8 STAGE_VRAM[]
extern

◆ OVERLAY_ADDRESS

void* const OVERLAY_ADDRESS
extern

the two areas the loader copies to, at those addresses (system/main.c)

the two areas the loader copies to, at those addresses (system/main.c)

Definition at line 91 of file main.c.

Referenced by loadModeOverlay().

◆ SUB_OVERLAY_ADDRESS

void* const SUB_OVERLAY_ADDRESS
extern

Definition at line 92 of file main.c.

Referenced by loadSubOverlay(), and main().