Isle
Loading...
Searching...
No Matches
Radio Class Reference

[AI] High-level manager for the in-game radio, handling notifications, playing/stopping, and state synchronization. More...

#include <radio.h>

Inheritance diagram for Radio:
Collaboration diagram for Radio:

Public Member Functions

 Radio ()
 [AI] Constructs a new Radio, registering for notifications and control events. More...
 
 ~Radio () override
 [AI] Destructor; shuts down radio playback and unregisters events. More...
 
MxLong Notify (MxParam &p_param) override
 [AI] Handles system notifications (end actions, control events) relevant to the radio. More...
 
const char * ClassName () const override
 [AI] Returns the runtime class name for Radio objects. More...
 
MxBool IsA (const char *p_name) const override
 [AI] Type check for the Radio class and its ancestors. More...
 
void Initialize (MxBool p_und)
 [AI] Sets radio system as enabled/disabled and resets state if changed. More...
 
void CreateState ()
 [AI] Creates or retrieves a RadioState object in the game state manager. More...
 
void Play ()
 [AI] Starts playing radio music if it is not already active. More...
 
void Stop ()
 [AI] Stops radio playback if currently active and updates audio state. More...
 
RadioStateGetState ()
 [AI] Returns the current RadioState for this radio. More...
 
- Public Member Functions inherited from MxCore
 MxCore ()
 [AI] Constructs a new MxCore object and assigns it a unique id. More...
 
virtual ~MxCore ()
 [AI] Virtual destructor. Required for correct polymorphic cleanup in derived classes. More...
 
virtual MxLong Notify (MxParam &p_param)
 [AI] Virtual callback notification mechanism. More...
 
virtual MxResult Tickle ()
 [AI] Called by tickle managers to allow the object to update itself. More...
 
virtual const char * ClassName () const
 [AI] Returns the runtime class name of this object. More...
 
virtual MxBool IsA (const char *p_name) const
 [AI] Checks whether this object's class type or parents match the given name. More...
 
MxU32 GetId ()
 [AI] Gets the unique (per-process) id assigned to this object instance. More...
 

Detailed Description

[AI] High-level manager for the in-game radio, handling notifications, playing/stopping, and state synchronization.

[AI] Listens for player interaction and game events. Orchestrates radio playback and persists state through RadioState. []

Definition at line 77 of file radio.h.

Constructor & Destructor Documentation

◆ Radio()

Radio::Radio ( )

[AI] Constructs a new Radio, registering for notifications and control events.

Definition at line 62 of file radio.cpp.

◆ ~Radio()

Radio::~Radio ( )
override

[AI] Destructor; shuts down radio playback and unregisters events.

Definition at line 72 of file radio.cpp.

Member Function Documentation

◆ ClassName()

const char * Radio::ClassName ( ) const
inlineoverridevirtual

[AI] Returns the runtime class name for Radio objects.

Reimplemented from MxCore.

Definition at line 90 of file radio.h.

◆ CreateState()

void Radio::CreateState ( )

[AI] Creates or retrieves a RadioState object in the game state manager.

Definition at line 201 of file radio.cpp.

◆ GetState()

RadioState * Radio::GetState ( )
inline

[AI] Returns the current RadioState for this radio.

Returns
Pointer to the managed RadioState. [AI]

Definition at line 118 of file radio.h.

◆ Initialize()

void Radio::Initialize ( MxBool  p_und)

[AI] Sets radio system as enabled/disabled and resets state if changed.

Parameters
p_undIf TRUE, enables; if FALSE, disables and refreshes. [AI]

Definition at line 192 of file radio.cpp.

◆ IsA()

MxBool Radio::IsA ( const char *  p_name) const
inlineoverridevirtual

[AI] Type check for the Radio class and its ancestors.

Parameters
p_nameClass to test for. [AI]

Reimplemented from MxCore.

Definition at line 98 of file radio.h.

◆ Notify()

MxLong Radio::Notify ( MxParam p_param)
overridevirtual

[AI] Handles system notifications (end actions, control events) relevant to the radio.

Parameters
p_paramNotification parameters [AI]

[AI] Dispatches to control or end-action handlers as required by notification type.

Reimplemented from MxCore.

Definition at line 85 of file radio.cpp.

◆ Play()

void Radio::Play ( )

[AI] Starts playing radio music if it is not already active.

Definition at line 105 of file radio.cpp.

◆ Stop()

void Radio::Stop ( )

[AI] Stops radio playback if currently active and updates audio state.

Definition at line 126 of file radio.cpp.


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