class: ege::Environement
Description:
class:
Constructor and Destructor:
+ Environement (void );
+ virtual ~Environement (void );
Synopsis:
+ void addCreator (const std::string & _type,
ege::createElement_tf _creator);
+ ege::ElementGame* createElement (const std::string & _type,
bool _autoAddElement,
enum ege::property _property,
void* _value);
+ ege::ElementGame* createElement (const std::string & _type,
std::string & _description,
bool _autoAddElement);
+ ege::ElementGame* createElement (const std::string & _type,
ejson::Value* _value,
bool _autoAddElement);
+ ege::ElementGame* createElement (const std::string & _type,
exml::Node* _node,
bool _autoAddElement);
+ void setDynamicWorld (btDynamicsWorld* _newWorld);
+ btDynamicsWorld* getDynamicWorld (void );
+ std::vector<ege::ElementGame*> & getElementGame (void );
+ ege::ElementGame* getElementNearest (ege::ElementGame* _sourceRequest,
float & _distance);
+ void getElementNearest (const vec3 & _sourcePosition,
float _distanceMax,
std::vector<ege::Environement::ResultNearestElement> & _resultList);
+ void getElementNearestFixed (const vec3 & _sourcePosition,
float _distanceMax,
std::vector<ege::Environement::ResultNearestElement> & _resultList);
+ void addElementGame (ege::ElementGame* _newElement);
+ void rmElementGame (ege::ElementGame* _removeElement);
+ void getOrderedElementForDisplay (std::vector<ege::Environement::ResultNearestElement> & _resultList,
const vec3 & _position,
const vec3 & _direction);
+ void generateInteraction (ege::ElementInteraction & _event);
+ ege::ParticuleEngine & getParticuleEngine (void );
Detail:
Environement
+ Environement (void );
~Environement
+ virtual ~Environement (void );
addCreator
+ void addCreator (const std::string & _type,
ege::createElement_tf _creator);
add a creator element system
createElement
+ ege::ElementGame* createElement (const std::string & _type,
bool _autoAddElement,
enum ege::property _property,
void* _value);
Create an element on the curent scene.
Note: Pointer is return in case of setting properties on it...
Parameter [input]: | _type | Type of the element that might be created. |
Parameter [input]: | _description | String that describe the content of the element properties. |
Parameter [input]: | _autoAddElement | this permit to add the element if it is created == > no more action ... |
Return: | | NULL if an error occured OR the pointer on the element and it is already added on the system. |
createElement
+ ege::ElementGame* createElement (const std::string & _type,
std::string & _description,
bool _autoAddElement);
createElement
+ ege::ElementGame* createElement (const std::string & _type,
ejson::Value* _value,
bool _autoAddElement);
createElement
+ ege::ElementGame* createElement (const std::string & _type,
exml::Node* _node,
bool _autoAddElement);
setDynamicWorld
+ void setDynamicWorld (btDynamicsWorld* _newWorld);
set the curent world
getDynamicWorld
+ btDynamicsWorld* getDynamicWorld (void );
get the curent world
Return: | | pointer on the current world |
getElementGame
+ std::vector<ege::ElementGame*> & getElementGame (void );
getElementNearest
+ ege::ElementGame* getElementNearest (ege::ElementGame* _sourceRequest,
float & _distance);
get the nearest Element
getElementNearest
+ void getElementNearest (const vec3 & _sourcePosition,
float _distanceMax,
std::vector<ege::Environement::ResultNearestElement> & _resultList);
getElementNearestFixed
+ void getElementNearestFixed (const vec3 & _sourcePosition,
float _distanceMax,
std::vector<ege::Environement::ResultNearestElement> & _resultList);
addElementGame
+ void addElementGame (ege::ElementGame* _newElement);
add an element on the list availlable.
Parameter [input]: | _newElement | Element to add. |
rmElementGame
+ void rmElementGame (ege::ElementGame* _removeElement);
remove an element on the list availlable.
Parameter [input]: | _removeElement | Element to remove. |
getOrderedElementForDisplay
+ void getOrderedElementForDisplay (std::vector<ege::Environement::ResultNearestElement> & _resultList,
const vec3 & _position,
const vec3 & _direction);
get the element order from the nearest to the farest, and remove all element that are not in the camera angle and axes.
Parameter [input] [output]: | _resultList | List of the element ordered. |
Parameter [input]: | _position | Camera position in the space. |
Parameter [input]: | _direction | Camera direction of the view. |
generateInteraction
+ void generateInteraction (ege::ElementInteraction & _event);
generate an event on all the sub element of the game == > usefull for explosion, or lazer fire ...
getParticuleEngine
+ ege::ParticuleEngine & getParticuleEngine (void );
get the particule engine reference.
Return: | | The requested reference on the engine |