Richard Boegli's CnC_Generals_Zero_Hour Fork WIP
This is documentation of Richard Boegil's Zero Hour Fork
 
Loading...
Searching...
No Matches
RTS2DScene Class Reference

#include <W3DScene.h>

Inherits SimpleSceneClass, and SubsystemInterface.

Public Member Functions

 RTS2DScene ()
 
 ~RTS2DScene ()
 
virtual void Customized_Render (RenderInfoClass &rinfo)
 customizable renderer for the RTS2DScene
 
void init ()
 
void update ()
 
void draw ()
 
void reset ()
 
void doRender (CameraClass *cam)
 
- Public Member Functions inherited from SimpleSceneClass
 SimpleSceneClass (void)
 
virtual ~SimpleSceneClass (void)
 
virtual int Get_Scene_ID (void)
 
virtual void Add_Render_Object (RenderObjClass *obj)
 
virtual void Remove_Render_Object (RenderObjClass *obj)
 
virtual void Remove_All_Render_Objects (void)
 
virtual void Register (RenderObjClass *obj, RegType for_what)
 
virtual void Unregister (RenderObjClass *obj, RegType for_what)
 
virtual SceneIteratorCreate_Iterator (bool onlyvisible=false)
 
virtual void Destroy_Iterator (SceneIterator *it)
 
virtual void Visibility_Check (CameraClass *camera)
 
virtual float Compute_Point_Visibility (RenderInfoClass &rinfo, const Vector3 &point)
 
- Public Member Functions inherited from SceneClass
 SceneClass (void)
 
virtual ~SceneClass (void)
 
virtual int Get_Scene_ID (void) const
 
virtual void Set_Ambient_Light (const Vector3 &color)
 
virtual const Vector3Get_Ambient_Light (void)
 
virtual void Set_Fog_Enable (bool set)
 
virtual bool Get_Fog_Enable (void)
 
virtual void Set_Fog_Color (const Vector3 &color)
 
virtual const Vector3Get_Fog_Color (void)
 
virtual void Set_Fog_Range (float start, float end)
 
virtual void Get_Fog_Range (float *start, float *end)
 
void Set_Polygon_Mode (PolyRenderType mode)
 
PolyRenderType Get_Polygon_Mode (void)
 
void Set_Extra_Pass_Polygon_Mode (ExtraPassPolyRenderType mode)
 
ExtraPassPolyRenderType Get_Extra_Pass_Polygon_Mode (void)
 
virtual void Save (ChunkSaveClass &csave)
 
virtual void Load (ChunkLoadClass &cload)
 
- Public Member Functions inherited from RefCountClass
 RefCountClass (void)
 
 RefCountClass (const RefCountClass &)
 
void Add_Ref (void) const
 
WWINLINE void Release_Ref (void) const
 
int Num_Refs (void) const
 
virtual void Delete_This (void)
 
- Public Member Functions inherited from SubsystemInterface
 SubsystemInterface ()
 
virtual ~SubsystemInterface ()
 
virtual void postProcessLoad ()
 
void UPDATE (void)
 
void DRAW (void)
 
AsciiString getName (void)
 
void setName (AsciiString name)
 

Protected Attributes

RenderObjClassm_status
 
CameraClassm_camera
 
- Protected Attributes inherited from SimpleSceneClass
bool Visibility_Checked
 
RefRenderObjListClass RenderList
 
RefRenderObjListClass UpdateList
 
RefRenderObjListClass LightList
 
RefRenderObjListClass ReleaseList
 
- Protected Attributes inherited from SceneClass
Vector3 AmbientLight
 
PolyRenderType PolyRenderMode
 
ExtraPassPolyRenderType ExtraPassPolyRenderMode
 
bool FogEnabled
 
Vector3 FogColor
 
float FogStart
 
float FogEnd
 
- Protected Attributes inherited from SubsystemInterface
AsciiString m_name
 

Additional Inherited Members

- Public Types inherited from SceneClass
enum  { SCENE_ID_UNKOWN = 0xFFFFFFFF , SCENE_ID_SCENE = 0 , SCENE_ID_SIMPLE , SCENE_ID_LAST = 0x0000FFFF }
 
enum  PolyRenderType { POINT , LINE , FILL }
 
enum  ExtraPassPolyRenderType { EXTRA_PASS_DISABLE , EXTRA_PASS_LINE , EXTRA_PASS_CLEAR_LINE }
 
enum  RegType { ON_FRAME_UPDATE = 0 , LIGHT , RELEASE }
 
- Static Public Member Functions inherited from RefCountClass
static int Total_Refs (void)
 
static RefCountClassAdd_Active_Ref (RefCountClass *obj)
 
static RefCountClassSet_Ref_Owner (RefCountClass *obj, char *file, int line)
 
static void Remove_Active_Ref (RefCountClass *obj)
 
static bool Validate_Active_Ref (RefCountClass *obj)
 
- Public Attributes inherited from RefCountClass
RefCountNodeClass ActiveRefNode
 
ActiveRefStruct ActiveRefInfo
 
- Static Public Attributes inherited from RefCountClass
static RefCountListClass ActiveRefList
 
- Protected Member Functions inherited from SimpleSceneClass
virtual void Post_Render_Processing (RenderInfoClass &rinfo)
 
- Protected Member Functions inherited from SceneClass
virtual void Render (RenderInfoClass &rinfo)
 
 SceneClass (const SceneClass &)
 
SceneClassoperator== (const SceneClass &)
 
- Protected Member Functions inherited from RefCountClass
virtual ~RefCountClass (void)
 

Detailed Description

Scene management for 2D overlay on top of 3D scene

Definition at line 149 of file W3DScene.h.

Constructor & Destructor Documentation

◆ RTS2DScene()

RTS2DScene::RTS2DScene ( )

Definition at line 1745 of file W3DScene.cpp.

◆ ~RTS2DScene()

RTS2DScene::~RTS2DScene ( )

Definition at line 1757 of file W3DScene.cpp.

Member Function Documentation

◆ Customized_Render()

void RTS2DScene::Customized_Render ( RenderInfoClass & rinfo)
virtual

customizable renderer for the RTS2DScene

Customized render for the 2d scene management

Reimplemented from SimpleSceneClass.

Definition at line 1768 of file W3DScene.cpp.

◆ doRender()

void RTS2DScene::doRender ( CameraClass * cam)

Render the scene

Definition at line 1781 of file W3DScene.cpp.

◆ draw()

void RTS2DScene::draw ( void )
virtual

Customized render for the 2d scene management

Reimplemented from SubsystemInterface.

Definition at line 1795 of file W3DScene.cpp.

◆ init()

void RTS2DScene::init ( )
inlinevirtual
  • Assign any default values to data required for the class
    • Allocate any memory and resources needed throughout the lifetime of the class

Implements SubsystemInterface.

Definition at line 159 of file W3DScene.h.

◆ reset()

void RTS2DScene::reset ( )
inlinevirtual
  • Any system should be able to reset all data and go back to an empty state that is ready to accept a completely new set of data. Reset() can expect to be used in the context of resetting the engine in order to start or load a new game.
    • Do NOT free and re-allocate resources needed, where possible reorganize and re-initialize the resources already allocated.
    • After a reset, the system does not need to be in EXACTLY the same state as a fresh instantiation. If there are persistent state information for the system make sure you maintain it while restoring or re-initializing other transient parts.

Implements SubsystemInterface.

Definition at line 162 of file W3DScene.h.

◆ update()

void RTS2DScene::update ( )
inlinevirtual
  • Update methods are the place to do system per frame processing. You should call the system update once each time through the game loop to service the system.
    • Note that currently the GameClient and GameLogic will be updating at different rates where the logic is running real time, and the client will adjust how many loops can be done during one server time slice in order to improve performance on low end machines.

Implements SubsystemInterface.

Definition at line 160 of file W3DScene.h.

Member Data Documentation

◆ m_camera

CameraClass* RTS2DScene::m_camera
protected

Definition at line 167 of file W3DScene.h.

◆ m_status

RenderObjClass* RTS2DScene::m_status
protected

Definition at line 166 of file W3DScene.h.


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