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

Three-target catcher of one player's activator, with its multiplier texture and movie. More...

#include <tnlcatcher.h>

Collaboration diagram for TnlCatcher:

Public Types

enum  { kTargetCount = 3 }
 Number of targets. More...

Public Member Functions

 TnlCatcher (const HxStr &colorName)
 Resolve the view, the targets, the materials, the textures, and the movie.
void SetMultiplied (int nMultiplied)
 Switch the material between the plain and the multiplier texture.
void ResetTargets ()
 Put every target on the "tar up" material.
void Hit (int nTarget)
 Put one target on the "tar dn" material and restart the hit count.
void SetAlpha (float flAlpha)
 Set the alpha of the "act_<c>.mat" material.
void AttachTo (Rnd::View *pParent)
 Parent the view to another view for both transform and drawing.
void Update (float flFrame)
 Advance the multiplier movie, the hit count, and the view.

Public Attributes

Rnd::View * mView
 Catcher view, "catcher_<c>".

Detailed Description

Three-target catcher of one player's activator, with its multiplier texture and movie.

The class is not polymorphic and emits no RTTI, and no allocation tag or file path identifies it. The name is inferred from its view, "catcher_<c>", where <c> is the first letter of the player's colour name.

Hit() swaps one target to the "tar dn" material. Ten updates later every target returns to the "tar up" material, and the view is driven to mTarget * 100 plus twice the updates since the hit, capped at 100.

TnlActivator embeds one, 0x3c bytes, at +0x5c.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum

Number of targets.

Enumerator
kTargetCount 

Constructor & Destructor Documentation

◆ TnlCatcher()

TnlCatcher::TnlCatcher ( const HxStr & colorName)
explicit

Resolve the view, the targets, the materials, the textures, and the movie.

The multiplier starts off, every target starts on the "tar up" material, and both counts start at 100000000.

Parameters
colorNameThe player's colour name, whose first letter selects every object.
Ghidra address:
NTSC-U/C: 0x00439958
Ghidra address:
PAL: 0x004757f8

Member Function Documentation

◆ SetMultiplied()

void TnlCatcher::SetMultiplied ( int nMultiplied)

Switch the material between the plain and the multiplier texture.

Parameters
nMultipliedNon-zero for "act_mult_<c>.tex", zero for "act_<c>.bmp".
Ghidra address:
NTSC-U/C: 0x00455268
Ghidra address:
PAL: 0x00492798

◆ ResetTargets()

void TnlCatcher::ResetTargets ( )

Put every target on the "tar up" material.

Ghidra address:
NTSC-U/C: 0x004553c0
Ghidra address:
PAL: 0x004928f0

◆ Hit()

void TnlCatcher::Hit ( int nTarget)

Put one target on the "tar dn" material and restart the hit count.

Does nothing while the view is hidden. The image has no caller.

Parameters
nTargetThe target, 0 through 2.
Ghidra address:
NTSC-U/C: 0x00455330
Ghidra address:
PAL: 0x00492860

◆ SetAlpha()

void TnlCatcher::SetAlpha ( float flAlpha)

Set the alpha of the "act_<c>.mat" material.

Parameters
flAlphaThe alpha.
Ghidra address:
NTSC-U/C: 0x00455238
Ghidra address:
PAL: 0x00492768

◆ AttachTo()

void TnlCatcher::AttachTo ( Rnd::View * pParent)

Parent the view to another view for both transform and drawing.

The image has no caller.

Parameters
pParentThe parent view.
Ghidra address:
NTSC-U/C: 0x004552d8
Ghidra address:
PAL: 0x00492808

◆ Update()

void TnlCatcher::Update ( float flFrame)

Advance the multiplier movie, the hit count, and the view.

The view frame is written only when flFrame is not negative. The image has no caller.

Parameters
flFrameThe scaled song position TnlActivator::Update() receives.
Ghidra address:
NTSC-U/C: 0x00455418
Ghidra address:
PAL: 0x00492948

Member Data Documentation

◆ mView

Rnd::View* TnlCatcher::mView

Catcher view, "catcher_<c>".

Public because TnlActivator shows and hides it directly and the image has no accessor.


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