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

FreQ icon of one player's badge on the head-up display, with a pulse that marks the player. More...

#include <hudfreq.h>

Public Member Functions

 HudFreq (Player *pPlayer, int nIndex)
 Resolve the icon's objects for one player.
void SetPulsing (int nPulsing)
 Start or stop the icon's pulse.
void SetShowing (int nShowing)
 Show or hide the icon.
void SetFrame (float flFrame)
 Advance the icon animation and the pulse.

Detailed Description

FreQ icon of one player's badge on the head-up display, with a pulse that marks the player.

The class is not polymorphic, emits no RTTI, and is never allocated on its own. No descriptor, allocation tag, or file path identifies it, and its name is inferred from the s freqd family of objects its constructor resolves. It occupies +0x10 to +0x27 of HudBadge.

Constructor & Destructor Documentation

◆ HudFreq()

HudFreq::HudFreq ( Player * pPlayer,
int nIndex )

Resolve the icon's objects for one player.

Resolves <layout> freq<p>.tnm, HUD freq pulse.mnm, HUD freq<p>.mat, and <layout> freq<n>.mesh, where <p> is the player's identifier. Sets the material's emissive colour to HudColorFromName() of the player's colour name, gives its second stage the persona burn texture for the badge number, and puts it on the mesh. The mesh is shown except in a jukebox session. The icon starts without its pulse.

Parameters
pPlayerThe player the icon shows.
nIndexThe badge number that fills <n> and selects the persona burn texture.
Ghidra address:
NTSC-U/C: 0x00419b40
Ghidra address:
PAL: 0x00454268

Member Function Documentation

◆ SetPulsing()

void HudFreq::SetPulsing ( int nPulsing)

Start or stop the icon's pulse.

Overlay::OnLeaderChanged() pulses the leader's icon, and Overlay's JuiceAmountMsg handler pulses the icon of a solo player whose juice passes 0.85. Both write the word through an inlined copy of this routine. The title is inferred.

Parameters
nPulsingNon-zero to pulse.
Ghidra address:
NTSC-U/C: 0x0042a348
Ghidra address:
PAL: 0x00465698

◆ SetShowing()

void HudFreq::SetShowing ( int nShowing)
inline

Show or hide the icon.

Overlay's PlaybackToggleMsg handler at 0x0041f9a8 inlines the body, and the out-of-line copy has no caller. The mesh is reached through its Rnd::Drawable subobject, whose vptr is at +0x10. The title is inferred.

Parameters
nShowingNon-zero to show the icon.
Ghidra address:
NTSC-U/C: 0x0042a3f0
Ghidra address:
PAL: 0x00465740

◆ SetFrame()

void HudFreq::SetFrame ( float flFrame)

Advance the icon animation and the pulse.

The icon animation follows the frame for its first 500 ticks. The pulse loops every 480 ticks, 80 ticks ahead of the frame, and restarts its loop count only while pulsing is on. HudBadge::SetFrame() inlines the body, and this copy has no caller.

Parameters
flFrameThe song position, in MIDI ticks.
Ghidra address:
NTSC-U/C: 0x0042a350
Ghidra address:
PAL: 0x004656a0

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