resonance 1.0.1
Loading...
Searching...
No Matches
Application Class Reference

The FreQuency application. More...

#include <application.h>

Inheritance diagram for Application:
Collaboration diagram for Application:

Public Member Functions

virtual ~Application ()
virtual int Run ()
 Bring the game up and run it until the frame loop stops.
virtual int ExitInstance ()
 Tear the game down as it exits.
Public Member Functions inherited from Globals
 Globals ()
 Clear the service pointers.
virtual ~Globals ()
void Init ()
 Create every process-wide service.
void Shutdown ()
 Destroy every process-wide service.
void CreateSynth ()
 Create the hardware synth.
void RunMainLoop ()
 Drive the main loop until it stops.
GameManagerImpl * GetGameManager ()
Ps2HardSynth * GetSynth ()
Sch::Scheduler * GetWatchdog ()
Sch::TimeClock * GetWatchdogTimer ()
ScriptSink * GetScriptSink ()
IOBPreallocMemStream * GetLog ()
IOBPreallocMemStream * GetResetLog ()
 Rewind the shared log stream and report it.
GrooveWorld * GetWorld ()
 Report the game manager's world.
MetaGameWorld * GetMetaWorld ()
 Report the game manager's front-end world.
int GetUnwrittenValue ()
 Forward GameManagerImpl::GetUnwrittenValue().
int GetPlayMode ()
 Report the game manager's play mode.
int GetGameMode ()
 Report the game manager's game mode.
Sch::TickClock * GetSongClock ()
 Report the song clock of the game manager's world.
PlayMap * GetPlayMap ()
 Report the play map of the world's level.
int IsJukeboxMode ()
 Report whether the session is a jukebox session.
LevelData * GetLevel ()
 Report the world's level.
int GetTempo ()
 Report the tempo of the song clock's tempo map.

Static Public Member Functions

static Application * shared ()

Detailed Description

The FreQuency application.

Its RTTI descriptor is at 0x008f0870. It derives from Globals. Its vtable is at 0x007dcf68 and it adds no data members. The constructor is the base constructor alone, and the compiler inlined it into the static initialiser at 0x00198c58 that creates the instance before main() runs.

The instance has file-scope linkage. Its only three references in the image all sit in this translation unit, at 0x00198c7c and 0x00198c9c in the static initialiser and at 0x00198db0 in shared(). Nothing outside the unit refers to it, and shared() exists so that nothing has to.

The two overrides are the whole of the Globals interface. Their titles come from the two exception templates the script layer registers, An exception was thrown by the function Application::Run(). and An exception was thrown by the function Application::ExitInstance().

Constructor & Destructor Documentation

◆ ~Application()

virtual Application::~Application ( )
virtual
Ghidra address:
NTSC-U/C: 0x00198cb0
Ghidra address:
PAL: 0x0019e9e0

Member Function Documentation

◆ Run()

virtual int Application::Run ( )
virtual

Bring the game up and run it until the frame loop stops.

The routine registers the script call templates, creates the script module, creates every service through Globals::Init(), runs autoexec(), loads the memory-card save icon, starts the game manager, and then hands control to the frame loop.

Returns
Always 1.
Ghidra address:
NTSC-U/C: 0x00198d20
Ghidra address:
PAL: 0x0019ea50

Implements Globals.

◆ ExitInstance()

virtual int Application::ExitInstance ( )
virtual

Tear the game down as it exits.

The NTSC-U/C override has no effect. The PAL override calls Shutdown() and then destroys the script host.

Returns
Always zero.
Ghidra address:
NTSC-U/C: 0x00198da0
Ghidra address:
PAL: 0x0019ead0

Implements Globals.

◆ shared()

Application * Application::shared ( )
static
Returns
The single application instance.
Ghidra address:
NTSC-U/C: 0x00198da8
Ghidra address:
PAL: 0x0019eaf8

The documentation for this class was generated from the following file: