Home | Namespaces | Hierarchy | Alphabetical List | Class list | Files | Namespace Members | Class members | File members |
#include <ILevelNode.hpp>
Public Member Functions | |
virtual void | addChild (ILevelNode *child) |
virtual ILevelNode * | clone (ILevelNode *newParent=0, ILevelManager *newManager=0) |
Creates a clone of this level node and its children. | |
virtual void | drawDebugData () |
Draws the node's debug data based on its DebugDataVisible member. | |
list< ILevelNode * > & | getChildren () |
Returns a const reference to the list of all children. | |
virtual s32 | getID () const |
Returns the id of the level node. This id can be used to identify the node. | |
virtual const c8 * | getName () const |
ILevelNode * | getParent () const |
Returns the parent of this level node. | |
virtual E_LEVEL_NODE_TYPE | getType () const |
Returns type of the level node. | |
ILevelNode (ILevelNode *parent, ILevelManager *lmgr, s32 id=-1) | |
Constructor. | |
E_DEBUG_LEVEL_TYPE | isDebugDataVisible () const |
Returns if debug data are drawed. | |
virtual bool | isIdle () const |
Returns true if the node is Idle. | |
virtual void | OnEvent (const NGEReceiver *event) |
virtual void | OnRegisterLevelNode () |
This method is called just before the processing of the node. | |
virtual void | process ()=0 |
Process the node. | |
virtual void | remove () |
Removes this level node from the level, deleting it. | |
virtual bool | removeChild (ILevelNode *child) |
virtual void | removeChildren () |
Removes all children of this level node. | |
virtual void | setDebugDataVisible (E_DEBUG_LEVEL_TYPE Visible) |
Sets if and which debug data should be drawn. | |
virtual void | setID (s32 id) |
Sets the id of the level node. This id can be used to identify the node. | |
virtual void | setIdle (bool isIdle) |
Sets if the node should be idle or not. All children of this node won't be processed too if this node is idle. | |
virtual void | setName (const c8 *name) |
virtual void | setParent (ILevelNode *newParent) |
Changes the parent of the level node. | |
virtual | ~ILevelNode () |
Destructor. | |
Protected Member Functions | |
void | cloneMembers (ILevelNode *toCopyFrom, ILevelManager *newManager) |
This method should be used by clone() implementations of derived classes. | |
void | processEvent (const NGEReceiver *event) |
Protected Attributes | |
list< ILevelNode * > | Children |
List of all children of this node. | |
E_DEBUG_LEVEL_TYPE | DebugDataVisible |
Flag if debug data should be drawn. | |
s32 | ID |
Id of the node. | |
bool | IsIdle |
Is the node Idle? | |
ILevelManager * | LevelManager |
Pointer to the level manager. | |
stringc | Name |
Name of the level node. | |
ILevelNode * | Parent |
Pointer to the parent. |
Definition at line 18 of file ILevelNode.hpp.
nge::engine::ILevelNode::ILevelNode | ( | ILevelNode * | parent, | |
ILevelManager * | lmgr, | |||
s32 | id = -1 | |||
) | [inline] |
virtual nge::engine::ILevelNode::~ILevelNode | ( | ) | [inline, virtual] |
virtual void nge::engine::ILevelNode::addChild | ( | ILevelNode * | child | ) | [inline, virtual] |
Adds a child to this level node. If the level node already has got a parent, it is removed from there as child.
Definition at line 129 of file ILevelNode.hpp.
References Children, irr::IReferenceCounted::grab(), Parent, and remove().
Referenced by ILevelNode(), and setParent().
virtual ILevelNode* nge::engine::ILevelNode::clone | ( | ILevelNode * | newParent = 0 , |
|
ILevelManager * | newManager = 0 | |||
) | [inline, virtual] |
void nge::engine::ILevelNode::cloneMembers | ( | ILevelNode * | toCopyFrom, | |
ILevelManager * | newManager | |||
) | [inline, protected] |
This method should be used by clone() implementations of derived classes.
Definition at line 241 of file ILevelNode.hpp.
References Children, DebugDataVisible, ID, IsIdle, LevelManager, and Name.
virtual void nge::engine::ILevelNode::drawDebugData | ( | ) | [inline, virtual] |
Draws the node's debug data based on its DebugDataVisible member.
Reimplemented in nge::engine::IRegionLevelNode.
Definition at line 70 of file ILevelNode.hpp.
References Children.
Referenced by nge::engine::IRegionLevelNode::drawDebugData().
list<ILevelNode*>& nge::engine::ILevelNode::getChildren | ( | ) | [inline] |
Returns a const reference to the list of all children.
Definition at line 196 of file ILevelNode.hpp.
References Children.
Referenced by nge::engine::IRegionLevelNode::setIdle().
virtual s32 nge::engine::ILevelNode::getID | ( | ) | const [inline, virtual] |
Returns the id of the level node. This id can be used to identify the node.
Definition at line 114 of file ILevelNode.hpp.
References ID.
Referenced by nge::engine::IRegionLevelNode::drawDebugData().
virtual const c8* nge::engine::ILevelNode::getName | ( | ) | const [inline, virtual] |
Returns the name of the node.
Definition at line 84 of file ILevelNode.hpp.
References Name.
Referenced by nge::engine::IRegionLevelNode::drawDebugData().
ILevelNode* nge::engine::ILevelNode::getParent | ( | ) | const [inline] |
Returns the parent of this level node.
Definition at line 220 of file ILevelNode.hpp.
References Parent.
virtual E_LEVEL_NODE_TYPE nge::engine::ILevelNode::getType | ( | ) | const [inline, virtual] |
Returns type of the level node.
Reimplemented in nge::game::GameEntity, nge::game::IPlayer, and nge::engine::IRegionLevelNode.
Definition at line 227 of file ILevelNode.hpp.
References nge::engine::ELNT_UNKNOWN.
E_DEBUG_LEVEL_TYPE nge::engine::ILevelNode::isDebugDataVisible | ( | ) | const [inline] |
Returns if debug data are drawed.
Definition at line 189 of file ILevelNode.hpp.
References DebugDataVisible.
virtual bool nge::engine::ILevelNode::isIdle | ( | ) | const [inline, virtual] |
Returns true if the node is Idle.
Definition at line 99 of file ILevelNode.hpp.
References IsIdle.
Referenced by nge::engine::IRegionLevelNode::drawDebugData(), and nge::engine::IRegionLevelNode::OnRegisterLevelNode().
virtual void nge::engine::ILevelNode::OnEvent | ( | const NGEReceiver * | event | ) | [inline, virtual] |
virtual void nge::engine::ILevelNode::OnRegisterLevelNode | ( | ) | [inline, virtual] |
This method is called just before the processing of the node.
Nodes may register themselves in the process pipeline during this call, precalculate everything that should be processed, and prevent their children from being able to register themselves if they are idle by simply not calling their OnRegisterLevelNode() method. If you are implementing your own level node, you should override this method with an implementtion code looking like this:
if(!IsIdle) LevelManager->registerNodeForProcessing(this, pass); ILevelNode::OnRegisterLevelNode();
Reimplemented in nge::game::GameEntity, nge::game::IPlayer, and nge::engine::IRegionLevelNode.
Definition at line 53 of file ILevelNode.hpp.
References Children, and IsIdle.
Referenced by nge::engine::IRegionLevelNode::OnRegisterLevelNode().
virtual void nge::engine::ILevelNode::process | ( | ) | [pure virtual] |
void nge::engine::ILevelNode::processEvent | ( | const NGEReceiver * | event | ) | [inline, protected] |
virtual void nge::engine::ILevelNode::remove | ( | ) | [inline, virtual] |
Removes this level node from the level, deleting it.
Definition at line 174 of file ILevelNode.hpp.
References Parent, and removeChild().
Referenced by addChild().
virtual bool nge::engine::ILevelNode::removeChild | ( | ILevelNode * | child | ) | [inline, virtual] |
Removes a child from this level node.
Definition at line 143 of file ILevelNode.hpp.
References Children.
Referenced by remove().
virtual void nge::engine::ILevelNode::removeChildren | ( | ) | [inline, virtual] |
Removes all children of this level node.
Definition at line 160 of file ILevelNode.hpp.
References Children.
Referenced by ~ILevelNode().
virtual void nge::engine::ILevelNode::setDebugDataVisible | ( | E_DEBUG_LEVEL_TYPE | Visible | ) | [inline, virtual] |
Sets if and which debug data should be drawn.
Definition at line 182 of file ILevelNode.hpp.
References DebugDataVisible.
virtual void nge::engine::ILevelNode::setID | ( | s32 | id | ) | [inline, virtual] |
Sets the id of the level node. This id can be used to identify the node.
Definition at line 121 of file ILevelNode.hpp.
References ID.
virtual void nge::engine::ILevelNode::setIdle | ( | bool | isIdle | ) | [inline, virtual] |
Sets if the node should be idle or not. All children of this node won't be processed too if this node is idle.
Reimplemented in nge::engine::IRegionLevelNode.
Definition at line 107 of file ILevelNode.hpp.
References IsIdle.
Referenced by nge::engine::IRegionLevelNode::setIdle().
virtual void nge::engine::ILevelNode::setName | ( | const c8 * | name | ) | [inline, virtual] |
Sets the name of the node.
name,: | New name of the level node. |
Definition at line 92 of file ILevelNode.hpp.
References Name.
virtual void nge::engine::ILevelNode::setParent | ( | ILevelNode * | newParent | ) | [inline, virtual] |
Changes the parent of the level node.
Definition at line 203 of file ILevelNode.hpp.
References addChild(), irr::IReferenceCounted::drop(), irr::IReferenceCounted::grab(), and Parent.
list<ILevelNode*> nge::engine::ILevelNode::Children [protected] |
List of all children of this node.
Definition at line 280 of file ILevelNode.hpp.
Referenced by addChild(), cloneMembers(), drawDebugData(), getChildren(), OnRegisterLevelNode(), processEvent(), removeChild(), removeChildren(), and nge::engine::IRegionLevelNode::setIdle().
Flag if debug data should be drawn.
Definition at line 292 of file ILevelNode.hpp.
Referenced by cloneMembers(), nge::engine::IRegionLevelNode::drawDebugData(), isDebugDataVisible(), and setDebugDataVisible().
s32 nge::engine::ILevelNode::ID [protected] |
Id of the node.
Definition at line 283 of file ILevelNode.hpp.
Referenced by cloneMembers(), getID(), and setID().
bool nge::engine::ILevelNode::IsIdle [protected] |
Is the node Idle?
Definition at line 289 of file ILevelNode.hpp.
Referenced by cloneMembers(), isIdle(), OnRegisterLevelNode(), and setIdle().
ILevelManager* nge::engine::ILevelNode::LevelManager [protected] |
Pointer to the level manager.
Definition at line 286 of file ILevelNode.hpp.
Referenced by nge::engine::IRegionLevelNode::addGridSceneNode(), nge::engine::IRegionLevelNode::addNUSoftwareIntroSceneNode(), nge::engine::IRegionLevelNode::addSoundEmitterSceneNode(), cloneMembers(), and nge::engine::IRegionLevelNode::drawDebugData().
stringc nge::engine::ILevelNode::Name [protected] |
Name of the level node.
Definition at line 274 of file ILevelNode.hpp.
Referenced by cloneMembers(), getName(), and setName().
ILevelNode* nge::engine::ILevelNode::Parent [protected] |
Pointer to the parent.
Definition at line 277 of file ILevelNode.hpp.
Referenced by addChild(), getParent(), ILevelNode(), remove(), setParent(), and nge::engine::IRegionLevelNode::~IRegionLevelNode().
The NUSoftware Game Engine Documentation © 2007-2008 by Tomer Nosrati. Generated
on Sat Apr 26 16:52:35 2008 by Doxygen
(1.5.5) |