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

Beam a ship fires at a gem, a line that two waves ripple along. More...

#include <beam.h>

Public Member Functions

 Beam ()
 Construct an idle beam, creating its line and its material.
 ~Beam ()
 Destroy the line and the material of the beam.
void Configure (const BeamParams *pParams)
 Take the look of a family of beams.
void Start (Ship *pOwner, std::list< Ship::BeamData > *pOwnerList, float fStart, float fEnd)
 Fire the beam for a ship, with waves of random frequencies and periods.
void Stop ()
 Stop the beam and hide it.
bool Update (const Vector3 &direction, const Vector3 &side, const Color &color)
 Ripple the line of the beam between its ends and colour it.
void SetEnd (int nEnd, const float *pPosition)
 Move one end of the beam.
RndLine * GetLine () const
RndMat * GetMat () const
Beam * GetNextFree () const
void SetNextFree (Beam *pNextFree)
float GetStartTime () const
void SetOwner (Ship *pOwner)
std::list< Ship::BeamData > * GetOwnerList () const
void SetOwnerList (std::list< Ship::BeamData > *pOwnerList)

Detailed Description

Beam a ship fires at a gem, a line that two waves ripple along.

The RTTI identifies the class through the beam pools. The object is 0x70 bytes.

Constructor & Destructor Documentation

◆ Beam()

Beam::Beam ( )

Construct an idle beam, creating its line and its material.

Ghidra address:
NTSC-U/C: 0x001ed2d0
Ghidra address:
PAL: 0x001f6070

◆ ~Beam()

Beam::~Beam ( )

Destroy the line and the material of the beam.

Ghidra address:
NTSC-U/C: 0x001ed458
Ghidra address:
PAL: 0x001f61f8

Member Function Documentation

◆ Configure()

void Beam::Configure ( const BeamParams * pParams)

Take the look of a family of beams.

Parameters
pParamsThe look.
Ghidra address:
NTSC-U/C: 0x001ed4e0
Ghidra address:
PAL: 0x001f6280

◆ Start()

void Beam::Start ( Ship * pOwner,
std::list< Ship::BeamData > * pOwnerList,
float fStart,
float fEnd )

Fire the beam for a ship, with waves of random frequencies and periods.

Parameters
pOwnerThe ship.
pOwnerListThe list of the ship that records the beam.
fStartThe time the beam starts.
fEndThe time the beam ends.
Ghidra address:
NTSC-U/C: 0x001ed510
Ghidra address:
PAL: 0x001f62b0

◆ Stop()

void Beam::Stop ( )

Stop the beam and hide it.

Ghidra address:
NTSC-U/C: 0x001ed5c0
Ghidra address:
PAL: 0x001f6360

◆ Update()

bool Beam::Update ( const Vector3 & direction,
const Vector3 & side,
const Color & color )

Ripple the line of the beam between its ends and colour it.

Parameters
directionThe direction the waves lift the line in.
sideThe direction the second wave moves the line in.
colorThe colour an end of no alpha takes.
Returns
Whether the beam has ended. An ended beam is not changed.
Ghidra address:
NTSC-U/C: 0x001ed608
Ghidra address:
PAL: 0x001f63a8

◆ SetEnd()

void Beam::SetEnd ( int nEnd,
const float * pPosition )

Move one end of the beam.

Parameters
nEndThe end, one of BeamParams::End.
pPositionThe position, four floats.
Ghidra address:
NTSC-U/C: 0x001ed9c0
Ghidra address:
PAL: 0x001f6760

◆ GetLine()

RndLine * Beam::GetLine ( ) const
inline
Returns
The line of the beam.

◆ GetMat()

RndMat * Beam::GetMat ( ) const
inline
Returns
The material of the line.

◆ GetNextFree()

Beam * Beam::GetNextFree ( ) const
inline
Returns
The next beam of the free list.

◆ SetNextFree()

void Beam::SetNextFree ( Beam * pNextFree)
inline
Parameters
pNextFreeThe next beam of the free list.

◆ GetStartTime()

float Beam::GetStartTime ( ) const
inline
Returns
The time the beam started.

◆ SetOwner()

void Beam::SetOwner ( Ship * pOwner)
inline
Parameters
pOwnerThe ship that fired the beam.

◆ GetOwnerList()

std::list< Ship::BeamData > * Beam::GetOwnerList ( ) const
inline
Returns
The list of the ship that records the beam.

◆ SetOwnerList()

void Beam::SetOwnerList ( std::list< Ship::BeamData > * pOwnerList)
inline
Parameters
pOwnerListThe list of the ship that records the beam.

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