Isle
|
[AI] Base class for game state blocks which encapsulate serializable and/or resettable aspects of the game's state. More...
#include <legostate.h>
Classes | |
struct | Playlist |
[AI] Playlist structure representing an indexed list of object IDs with next-item selection strategies (loop, once, random etc). More... | |
Public Types | |
enum | ScoreColor { e_grey = 0 , e_yellow , e_blue , e_red } |
[AI] Score coloring values for in-game display feedback or logic. More... | |
Public Member Functions | |
~LegoState () override | |
[AI] Virtual destructor to allow subclass cleanup. More... | |
virtual MxBool | IsSerializable () |
[AI] Returns if this state can be serialized (for game saving/loading support). More... | |
virtual MxBool | Reset () |
[AI] Hook for returning object to default (empty) state; not implemented in this base. More... | |
virtual MxResult | Serialize (LegoStorage *p_storage) |
[AI] Serialize state to a storage (for save/load). More... | |
const char * | ClassName () const override |
[AI] Gets this class's name for RTTI/IsA functionality. More... | |
MxBool | IsA (const char *p_name) const override |
[AI] Tests if this object is of a given class name, directly or through inheritance. More... | |
![]() | |
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... | |
[AI] Base class for game state blocks which encapsulate serializable and/or resettable aspects of the game's state.
[AI]
LegoState is a polymorphic base for objects representing state relevant to LEGO Island's scripting/game logic. It allows derived states to be serialized, reset, and identifies themselves via RTTI-style interface. [AI]
Definition at line 17 of file legostate.h.
[AI] Score coloring values for in-game display feedback or logic.
[AI]
Enumerator | |
---|---|
e_grey | [AI] Default/neutral color (0) [AI] |
e_yellow | [AI] First colored highlight (1) [AI] |
e_blue | [AI] Second color, e.g. better score (2) [AI] |
e_red | [AI] Warning/critical color (3) [AI] |
Definition at line 22 of file legostate.h.
|
inlineoverride |
|
inlineoverridevirtual |
[AI] Gets this class's name for RTTI/IsA functionality.
[AI]
Reimplemented from MxCore.
Reimplemented in PizzaMissionState, PizzeriaState, PoliceState, RadioState, ScoreState, and TowTrackMissionState.
Definition at line 155 of file legostate.h.
|
inlineoverridevirtual |
[AI] Tests if this object is of a given class name, directly or through inheritance.
[AI]
p_name | Class name string to compare [AI] |
Reimplemented from MxCore.
Reimplemented in PizzaMissionState, PizzeriaState, PoliceState, RadioState, ScoreState, and TowTrackMissionState.
Definition at line 169 of file legostate.h.
|
inlinevirtual |
[AI] Returns if this state can be serialized (for game saving/loading support).
[AI]
Reimplemented in Act3State, HelicopterState, InfocenterState, JukeBoxState, LegoAct2State, RadioState, and ScoreState.
Definition at line 124 of file legostate.h.
|
inlinevirtual |
[AI] Hook for returning object to default (empty) state; not implemented in this base.
[AI]
Reimplemented in HelicopterState, Act1State, AnimState, and ScoreState.
Definition at line 131 of file legostate.h.
|
inlinevirtual |
[AI] Serialize state to a storage (for save/load).
[AI]
p_storage | Stream/abstraction for state IO (see LegoStorage) [AI] |
[AI] In write mode, stores class name; designed for override in derived classes. [AI]
Reimplemented in AmbulanceMissionState, GasStationState, HospitalState, Act1State, AnimState, LegoVehicleBuildState, RaceState, PizzaMissionState, PizzeriaState, PoliceState, and TowTrackMissionState.
Definition at line 141 of file legostate.h.