wavelength 1.0.0
Loading...
Searching...
No Matches
Gizmo Class Reference

The projector the front end moves between the menu screens. More...

#include <gizmo.h>

Collaboration diagram for Gizmo:

Public Member Functions

 Gizmo (int nUnused)
 Construct the gizmo from the loaded gizmo.view, gizmo.mesh, gizmo movie.mov, and freqscreen.mat, showing the movie.
virtual ~Gizmo ()
 Destroy the gizmo.
virtual void Draw ()
 Draw the gizmo, rendering the avatar first while the gizmo shows it.
virtual void Poll (float fTime)
 Advance the gizmo's move and its animations to a time, and place its mesh.
void SetShowing (bool bShowing)
 Show or hide the gizmo's view.
bool IsShowing () const
 Report whether the gizmo's view shows.
void SetShowAvatar (bool bShowAvatar)
 Show the avatar texture or the movie on the gizmo's screen.
bool IsShowingAvatar () const
 Report whether the gizmo's screen shows the avatar texture.
Transform WorldXfm () const
 Report the world transform of the gizmo's mesh.
void MoveTo (const Vector3 &position, const Quat &orientation, float fTime)
 Show the gizmo and start moving it from where it stands to a position and an orientation.
void SetTo (const Vector3 &position, const Quat &orientation)
 Place the gizmo at a position and an orientation.

Static Public Member Functions

static void Init (DataArray *pConfig)
 Read the frames of the move from the freq_screen section.

Public Attributes

Vector3 mPos
Quat mRot
Vector3 mFromPos
Quat mFromRot

Detailed Description

The projector the front end moves between the menu screens.

The RTTI includes the class name and records no base. The object is 0xa0 bytes, allocated with the global operator new. The vptr follows the members at +0x94, and the vtable at 0x003d00d0 runs the type function, the destructor, Draw(), and Poll().

The metagame creates the one instance and stores it in Metagame::mGizmo. Each FreqScreen records where the gizmo stands while the screen shows, and MoveTo() eases the gizmo there along an arctangent over the frames the freq_screen section of the metagame configuration gives. The gizmo's screen shows either its movie or, while it shows the avatar, the avatar texture.

Constructor & Destructor Documentation

◆ Gizmo()

Gizmo::Gizmo ( int nUnused)
explicit

Construct the gizmo from the loaded gizmo.view, gizmo.mesh, gizmo movie.mov, and freqscreen.mat, showing the movie.

Parameters
nUnusedStored at +0x40. No routine reads it, and the metagame passes 0.
Ghidra address:
NTSC-U/C: 0x001a4f20
Ghidra address:
PAL: 0x001acc10

◆ ~Gizmo()

virtual Gizmo::~Gizmo ( )
virtual

Destroy the gizmo.

Ghidra address:
NTSC-U/C: 0x001a5140
Ghidra address:
PAL: 0x001ace30

Member Function Documentation

◆ Draw()

virtual void Gizmo::Draw ( )
virtual

Draw the gizmo, rendering the avatar first while the gizmo shows it.

Ghidra address:
NTSC-U/C: 0x001a5240
Ghidra address:
PAL: 0x001acf30

◆ Poll()

virtual void Gizmo::Poll ( float fTime)
virtual

Advance the gizmo's move and its animations to a time, and place its mesh.

Nothing happens while the gizmo is hidden.

Parameters
fTimeThe front-end time.
Ghidra address:
NTSC-U/C: 0x001a5290
Ghidra address:
PAL: 0x001acf80

◆ Init()

void Gizmo::Init ( DataArray * pConfig)
static

Read the frames of the move from the freq_screen section.

Parameters
pConfigThe metagame section of the configuration, which must have freq_screen.
Ghidra address:
NTSC-U/C: 0x001a4e80
Ghidra address:
PAL: 0x001acb70

◆ SetShowing()

void Gizmo::SetShowing ( bool bShowing)

Show or hide the gizmo's view.

Parameters
bShowingWhether the view shows.
Ghidra address:
NTSC-U/C: 0x001a5180
Ghidra address:
PAL: 0x001ace70

◆ IsShowing()

bool Gizmo::IsShowing ( ) const

Report whether the gizmo's view shows.

Returns
Whether the view shows.
Ghidra address:
NTSC-U/C: 0x001a51b0
Ghidra address:
PAL: 0x001acea0

◆ SetShowAvatar()

void Gizmo::SetShowAvatar ( bool bShowAvatar)

Show the avatar texture or the movie on the gizmo's screen.

The avatar texture draws with source alpha blending and the movie additively.

Parameters
bShowAvatarWhether the screen shows the avatar texture.
Ghidra address:
NTSC-U/C: 0x001a51c0
Ghidra address:
PAL: 0x001aceb0

◆ IsShowingAvatar()

bool Gizmo::IsShowingAvatar ( ) const

Report whether the gizmo's screen shows the avatar texture.

Returns
Whether the screen's material blends with source alpha.
Ghidra address:
NTSC-U/C: 0x001a5228
Ghidra address:
PAL: 0x001acf18

◆ WorldXfm()

Transform Gizmo::WorldXfm ( ) const

Report the world transform of the gizmo's mesh.

Returns
The transform.
Ghidra address:
NTSC-U/C: 0x001a54a8
Ghidra address:
PAL: 0x001ad198

◆ MoveTo()

void Gizmo::MoveTo ( const Vector3 & position,
const Quat & orientation,
float fTime )

Show the gizmo and start moving it from where it stands to a position and an orientation.

Parameters
positionThe position.
orientationThe orientation.
fTimeThe front-end time the move starts at.
Ghidra address:
NTSC-U/C: 0x001a54d8
Ghidra address:
PAL: 0x001ad1c8

◆ SetTo()

void Gizmo::SetTo ( const Vector3 & position,
const Quat & orientation )

Place the gizmo at a position and an orientation.

A move under way continues towards the new place.

Parameters
positionThe position.
orientationThe orientation.
Ghidra address:
NTSC-U/C: 0x001a5540
Ghidra address:
PAL: 0x001ad230

Member Data Documentation

◆ mPos

Vector3 Gizmo::mPos

The position the gizmo stands at or moves to.

◆ mRot

Quat Gizmo::mRot

The orientation the gizmo has or turns to.

◆ mFromPos

Vector3 Gizmo::mFromPos

The position the move started from.

◆ mFromRot

Quat Gizmo::mFromRot

The orientation the move started from.


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