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

Scroller behind MetCreditsScreen that shows each credit while it crosses the screen. More...

#include <creditsroll.h>

Public Member Functions

 CreditsRoll (const HxStr &picturePrefix, const HxStr &textPrefix, Rnd::Cam *pCam, int nFirstIndex)
 Record the naming scheme and the camera, and reset the scroll.
void Reset ()
 Rewind to the first credit, forget which personas were drawn, and fetch the identity list.
int Update ()
 Show the credits in the visible band and hide the ones that have left it.
void HideAll ()
 Hide every picture and every text.
void Build ()
 Find the credits in the render manager and assign the persona names.

Detailed Description

Scroller behind MetCreditsScreen that shows each credit while it crosses the screen.

The class is not polymorphic and emits no RTTI, and no literal names it, so the title is inferred. MetCreditsScreen builds one in its container-view slot as CreditsRoll("cpic_", "ctxt_", credit_cam, 1) and keeps it at +0x8c. The object is 0x64 bytes.

A credit is a numbered pair of objects, a picture mesh cpic_NNN and a text ctxt_NNN, either of which may be missing. Update() walks the credits from the first one still on screen and shows each credit whose extent reaches the visible band. When a credit that carries a persona name first becomes visible, that persona's avatar is rendered into one of the four burn textures and the texture is placed on the picture.

The containers are sized by the number of credits but indexed by credit number, which starts at the first index rather than zero. That is how the image indexes them.

Constructor & Destructor Documentation

◆ CreditsRoll()

CreditsRoll::CreditsRoll ( const HxStr & picturePrefix,
const HxStr & textPrefix,
Rnd::Cam * pCam,
int nFirstIndex )

Record the naming scheme and the camera, and reset the scroll.

Parameters
picturePrefixThe prefix of each picture mesh name.
textPrefixThe prefix of each text name.
pCamThe camera the credits are projected through.
nFirstIndexThe number of the first credit.
Ghidra address:
NTSC-U/C: 0x00164df8
Ghidra address:
PAL: 0x00166ea8

Member Function Documentation

◆ Reset()

void CreditsRoll::Reset ( )

Rewind to the first credit, forget which personas were drawn, and fetch the identity list.

Ghidra address:
NTSC-U/C: 0x00165110
Ghidra address:
PAL: 0x001671f8

◆ Update()

int CreditsRoll::Update ( )

Show the credits in the visible band and hide the ones that have left it.

Credits above the band are hidden and the scroll's starting point moves past them. The walk stops at the first credit below the band.

Returns
One while a credit remains below the band, and zero once the credits run out.
Ghidra address:
NTSC-U/C: 0x00165268
Ghidra address:
PAL: 0x00167350

◆ HideAll()

void CreditsRoll::HideAll ( )

Hide every picture and every text.

Ghidra address:
NTSC-U/C: 0x00165b58
Ghidra address:
PAL: 0x00167c60

◆ Build()

void CreditsRoll::Build ( )

Find the credits in the render manager and assign the persona names.

Numbers from the first index are tried until neither a picture nor a text of that number exists. Missing members of a pair are stored as null.

Ghidra address:
NTSC-U/C: 0x00165c38
Ghidra address:
PAL: 0x00167d40

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