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

Screen that lists the remixes on a memory card or the factory remixes for loading. More...

#include <metremixloadscreen.h>

Inheritance diagram for MetRemixLoadScreen:
Collaboration diagram for MetRemixLoadScreen:

Public Member Functions

 MetRemixLoadScreen (MetRenderer *pRenderer, int nPriority)
 Construct the screen.
virtual ~MetRemixLoadScreen ()
 Delete the list and the button list.
virtual void EnterAndShow ()
 Choose the catalogue, set the title, build or show the list, then enter.
virtual void HandleCommand (const MetScreenCommand *pCommand)
 Act on a navigation command.
virtual void PlaySlideSound (int nSelector)
 Play the slide sound only while the catalogue has rows.
virtual void PlayHighSound (int nSelector)
 Play the emphasised-selection sound only while the catalogue has rows.
virtual void OnEnterFinished ()
 Show the first row on the data screen and the load options on the help screen.
virtual void OnExitFinished ()
 Act on the command once the exit has finished.
virtual void ResolveContainerViews ()
 Resolve the two buttons and the two row fonts.
virtual int ProvideText (int nItem, int nColumn, Rnd::Text *pText, int nContext)
 Show the name of one row of mRemixes, in mThisDiscFont when the row's albumNumber matches GetAlbumJukeboxValue() and in mOtherFont otherwise.
virtual int ProvideMesh (int nItem, int nColumn, Rnd::Mesh *pMesh, int nContext)
 Leave the cell as it is.
Public Member Functions inherited from MetScreen
 MetScreen (MetRenderer *pRenderer, int nPriority, const HxStr &name, const HxStr &directory, const HxStr &file)
 Construct a screen and start its container load.
virtual ~MetScreen ()
 Unregister from the renderer and release the container.
void DeliverCommand (const MetScreenCommand *pCommand)
 Play the sound one navigation command calls for and then act on the command.
void UpdateAnimationFrame (float flTime)
 Drive the frame of whichever animation is running and run the idle hook when none is.
void UpdateFrame (float flTime)
 Advance one screen by one frame.
virtual void PushNamedScreen (const HxStr &name)
 Bring one named screen onto the renderer's screen stack.
virtual void ActivateNamedPanel (const HxStr &name)
 Make one named screen the renderer's active panel.
virtual void OnPanelActivated ()
 Act on this screen having become the renderer's active panel.
virtual void ExitScreenByName (const HxStr &name)
 Start one named screen's exit animation.
virtual void BeginExit ()
 Start this screen's exit animation at the renderer's current time.
virtual void OnUnusedHook ()
 Do nothing.
virtual void OnKeyboardDismissed ()
 Take control back after the keyboard screen has finished.
virtual void OnDrawPass ()
 Contribute to the renderer's draw pass.
virtual void OnDestroying ()
 Release what the screen acquired, ahead of the rest of destruction.
virtual int PollContainerLoad ()
 Advance this screen's container load and resolve its views once the load finishes.
virtual void OnMsgScreenDismissed (const HxStr &name, int nChoice)
 Act on the choice the user made in a message dialogue.
virtual void OnMsgScreenShown (const HxStr &name)
 Act on a message dialogue becoming visible.
virtual void SetShowing (int nShowing)
 Show or hide the view and every drawable the container loaded.
virtual void BeginContainerLoad (const HxStr &directory, const HxStr &file)
 Intern a container load under this screen's container name and enqueue it.
virtual void PlayLeaveSound (int nSelector)
 Play the sound that accompanies departing a screen.
virtual void PlayCycleLeftSound (int nSelector)
 Play the sound that accompanies cycling a value to the left.
virtual void PlayCycleRightSound (int nSelector)
 Play the sound that accompanies cycling a value to the right.
virtual void PlayErrorSound (int nSelector)
 Play the sound that accompanies a rejected input.
virtual void UpdateIdle (float flTime)
 Advance whatever the screen updates once per frame while it is idle.
virtual void UpdateIdleAnimation (float flTime)
 Advance whatever the screen animates while it is neither entering nor exiting.
virtual void StartRepeatingSound (float flStartTime, float flInterval, Rnd::Button *pButton, int nCycles)
 Start alternating one button between its states 2 and 1.
virtual void UpdateRepeatingSound (float flTime)
 Advance the alternation that StartRepeatingSound() started.
virtual void OnRepeatingSoundFinished (Rnd::Button *pButton)
 Act on the alternation that StartRepeatingSound() started having finished.
virtual void StartEnterAnimation (float flTime)
 Rewind the enter animation and record the time it starts at.
virtual void UpdateEnterAnimation (float flTime)
 Drive the enter animation and finish it once it passes its end.
virtual void StartExitAnimation (float flTime)
 Record the time the exit animation starts at.
virtual void UpdateExitAnimation (float flTime)
 Drive the exit animation and hide the screen once it passes its end.
virtual void Draw ()
 Draw the view.
Public Member Functions inherited from MsgSink
void * operator new (size_t nSize)
 Allocate a sink from the tagged heap under the tag "MsgSink".
void operator delete (void *pBlock)
 Release a sink to the tagged heap.
virtual ~MsgSink ()
virtual void Dispatch (Message *pMsg)
 Accept a message.
Public Member Functions inherited from ListDataProvider
virtual ~ListDataProvider ()

Static Public Member Functions

static MetRemixLoadScreen * New (MetRenderer *pRenderer, int nPriority)
 Build the screen on the heap.
Static Public Member Functions inherited from MetScreen
static std::map< HxStr, MetContainerLoad * > & ContainerLoaderMap ()
 Shared table of container loads, interned under the container name.
static std::map< HxStr, MetScreenEntry > & ScreenRegistry ()
 Shared table of live screens, interned under the screen registry key.
static MetScreen * FindScreenByName (const HxStr &name)
 Resolve one screen by its registry key.
static MetScreen * FindEndScreen (MetRenderer *pRenderer, const HxStr &name)
 Resolve one end-of-game screen by its registry key, failing fatally when it is absent.
static void CreateMainMenuScreens (MetRenderer *pRenderer)
 Create the main-menu screens.
static void DestroyAllScreens ()
 Delete every registered screen and release every container loader.
static void CreateStartupScreens (MetRenderer *pRenderer)
 Create the four screens the front end needs before its containers have loaded.
static void CreateFrontEndScreens (MetRenderer *pRenderer)
 Create every remaining front-end screen, once.
static void DestroyCategory2Screens ()
 Delete and unregister every screen in category 2.
static void DestroyCategory1Screens ()
 Delete and unregister every screen in category 1.
static void DestroyNonDefaultScreens ()
 Delete and unregister every screen outside category 0, then rewind the rndMetLocAndNet zone.
static void PollContainerLoads ()
 Poll every container load that has not finished, and hide the drawables of each that does.

Additional Inherited Members

Public Attributes inherited from MetScreen
Rnd::View * mView
 The container's root view.
int mEnterPending
 Set when the screen was pushed before its container load finished.
int mActivatePending
 Set when the screen was activated as a panel before its container load finished.
float mRepeatScale
 Scale on the input auto-repeat interval.
Protected Member Functions inherited from MetScreen
virtual void DispatchPriv (Message *pMsg)
 Act on a message.
void ResolveAnimationViews ()
 Resolves the two animation views from the screen name and records the enter animation's end frame.
Protected Attributes inherited from MetScreen
float mAnimEndFrame
float mEnterStartTime
MetRenderer * mRenderer
int mExitChoice
int mAcceptsCommands
Rnd::View * mEnterAnim
std::vector< HxStr > mHelpKeys
int mViewsUnresolved
int mPlaysCommandSounds
int mShowsLoadedDrawables

Detailed Description

Screen that lists the remixes on a memory card or the factory remixes for loading.

Its RTTI descriptor is at 0x00901c10. It has two public non-virtual bases at fixed offsets, MetScreen at +0x00 and ListDataProvider at +140. New() confirms the object size of 0xac bytes by requesting exactly that many with the tag MsgSink.

The 39-entry primary vtable is at 0x00807300, the same length as the MetScreen table, so the class declares no virtual of its own, and the four-entry ListDataProvider table at 0x008072d8 adjusts this by -140 in every entry.

Two buttons choose the catalogue, mcrl_SAVED.but for the remixes on the first card slot and mcrl_FACTORY.but for the factory remixes, and a ScrollingList shows the chosen catalogue. The selected row is shown on MetRemixDataScreen.

Constructor & Destructor Documentation

◆ MetRemixLoadScreen()

MetRemixLoadScreen::MetRemixLoadScreen ( MetRenderer * pRenderer,
int nPriority )

Construct the screen.

The screen name is mcrl, the directory metagame/Shared, and the container memcard_remix_load. MetScreen::mShowsLoadedDrawables is cleared, and a MetButtonList is allocated into mButtons. The words at +0x90, +0x98, and +0x9c are not written.

Parameters
pRendererThe front-end renderer this screen registers on.
nPriorityThe load priority.
Ghidra address:
NTSC-U/C: 0x00349dc0
Ghidra address:
PAL: 0x00375678

◆ ~MetRemixLoadScreen()

virtual MetRemixLoadScreen::~MetRemixLoadScreen ( )
virtual

Delete the list and the button list.

Ghidra address:
NTSC-U/C: 0x00352618
Ghidra address:
PAL: 0x0037e788

Member Function Documentation

◆ New()

MetRemixLoadScreen * MetRemixLoadScreen::New ( MetRenderer * pRenderer,
int nPriority )
static

Build the screen on the heap.

Parameters
pRendererThe front-end renderer the screen registers on.
nPriorityThe load priority.
Returns
The new screen.
Ghidra address:
NTSC-U/C: 0x00352590
Ghidra address:
PAL: 0x0037e700

◆ EnterAndShow()

virtual void MetRemixLoadScreen::EnterAndShow ( )
virtual

Choose the catalogue, set the title, build or show the list, then enter.

Slot 5. The help line becomes mem_load_remix in jam mode and mem_load_custom otherwise, and both buttons are shown. With a card present (MetFrontEndState::mUsingMemcard) the card catalogue is chosen, unless it is empty. The factory catalogue is chosen otherwise. The title is the configuration code 0x269 text mem_load_remix or mem_load_custom formatted with the first card slot's name for the card, and fact_load_remix or fact_load_custom for the factory. The list is built on the first entry from mcrl_line.view, mcrl_hilite.mesh, mcrl_up.mesh, and mcrl_down.mesh, and shown again on later entries.

Ghidra address:
NTSC-U/C: 0x0034b568
Ghidra address:
PAL: 0x00377138

Reimplemented from MetScreen.

◆ HandleCommand()

virtual void MetRemixLoadScreen::HandleCommand ( const MetScreenCommand * pCommand)
virtual

Act on a navigation command.

Slot 19, through a six-entry jump table at 0x00807130. Previous and next move the list within the catalogue and show the new row. Left and right walk the button ring and then run OnButtonRingMoved(). A select on a row made on this disc empties the help text, records 2 in MetScreen::mExitChoice, exits the title, help, and data screens, and begins the exit, and a select on any other row plays the error sound. A back empties the help text, clears MetScreen::mExitChoice, exits the title and data screens, and begins the exit.

Parameters
pCommandThe command.
Ghidra address:
NTSC-U/C: 0x0034a2a8
Ghidra address:
PAL: 0x00375c68

Reimplemented from MetScreen.

◆ PlaySlideSound()

virtual void MetRemixLoadScreen::PlaySlideSound ( int nSelector)
virtual

Play the slide sound only while the catalogue has rows.

Slot 20.

A null mRemixes and an empty catalogue both silence the sound. The element count is computed by dividing the vector's byte span by 0x38, which is what settles the row type as MetRemixRecord independently of the list provider.

Parameters
nSelectorThe controller index, which the base body ignores.
Ghidra address:
NTSC-U/C: 0x003526d0
Ghidra address:
PAL: 0x0037e840

Reimplemented from MetScreen.

◆ PlayHighSound()

virtual void MetRemixLoadScreen::PlayHighSound ( int nSelector)
virtual

Play the emphasised-selection sound only while the catalogue has rows.

Slot 22.

The same guard as slot 20.

Parameters
nSelectorThe controller index, which the base body ignores.
Ghidra address:
NTSC-U/C: 0x00352720
Ghidra address:
PAL: 0x0037e890

Reimplemented from MetScreen.

◆ OnEnterFinished()

virtual void MetRemixLoadScreen::OnEnterFinished ( )
virtual

Show the first row on the data screen and the load options on the help screen.

Slot 33. The help layout is remix_load_opt, and the help text is the first line of MetScreen::mHelpKeys at the renderer time.

Ghidra address:
NTSC-U/C: 0x00352770
Ghidra address:
PAL: 0x0037e8e0

Reimplemented from MetScreen.

◆ OnExitFinished()

virtual void MetRemixLoadScreen::OnExitFinished ( )
virtual

Act on the command once the exit has finished.

Slot 36. Both buttons are hidden. After a back, jam mode returns through MetLeftGizmoScreen to MetRemixTypeScreen, and any other mode to MetSoloStagesScreen. After a select, the selected record becomes the loading game's level, script template 0x267 runs with 1, and the record goes to MetRemixManager. With three or more personas the last arena is taken and the load continues on MetLoadGameScreen. Otherwise MetFrontEndState::mReturnScreen records this screen and the load continues on MetArenasScreen with MetHelpScreen. MetRemixManager::BeginRemixLoad() then runs with this screen, the title, data, and help screens to restore, and whether the factory catalogue was chosen. The list entries are hidden last.

Ghidra address:
NTSC-U/C: 0x0034cbd0
Ghidra address:
PAL: 0x00378920

Reimplemented from MetScreen.

◆ ResolveContainerViews()

virtual void MetRemixLoadScreen::ResolveContainerViews ( )
virtual

Resolve the two buttons and the two row fonts.

Slot 38. The button list is emptied, and mcrl_SAVED.but and mcrl_FACTORY.but are added with the configuration code 0x258 labels rl_saved and rl_factory. font1_pink_2 and font1_pinkgrey_2 are resolved into mThisDiscFont and mOtherFont.

Ghidra address:
NTSC-U/C: 0x00349fc8
Ghidra address:
PAL: 0x003758e0

Reimplemented from MetScreen.

◆ ProvideText()

virtual int MetRemixLoadScreen::ProvideText ( int nItem,
int nColumn,
Rnd::Text * pText,
int nContext )
virtual

Show the name of one row of mRemixes, in mThisDiscFont when the row's albumNumber matches GetAlbumJukeboxValue() and in mOtherFont otherwise.

An index past the end of mRemixes empties the text instead. The column and the context are not read.

Parameters
nItemThe row of mRemixes.
nColumnThe cell index, which the body does not read.
pTextThe cell.
nContextThe list context, which the body does not read.
Returns
Always 1.
Ghidra address:
NTSC-U/C: 0x0034d8b0
Ghidra address:
PAL: 0x00379888

Implements ListDataProvider.

◆ ProvideMesh()

virtual int MetRemixLoadScreen::ProvideMesh ( int nItem,
int nColumn,
Rnd::Mesh * pMesh,
int nContext )
virtual

Leave the cell as it is.

Parameters
nItemThe row, which the body does not read.
nColumnThe cell index, which the body does not read.
pMeshThe cell, which the body does not read.
nContextThe list context, which the body does not read.
Returns
Always 1.
Ghidra address:
NTSC-U/C: 0x00352588
Ghidra address:
PAL: 0x0037e6f8

Implements ListDataProvider.


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