#include <S2_Universe.h>
Public Member Functions | |
Universe () | |
virtual | ~Universe () |
Universe Creation and Destruction. | |
void | BigBang (unsigned int max_obj=S2_UNIVERSE_DEFAULT_MAX_OBJ) |
void | BigCrunch () |
System creation, destruction and configuration. | |
System * | CreateSystem () |
void | DestroySystem (System *p_sys) |
System creation and destruction. | |
Object * | CreateObject (Model::ModelType natural_model_type, System *natural_sys=NULL) |
void | DestroyObject (Object *p_obj) |
Consultors. | |
unsigned int | GetNumObjects () const |
unsigned int | GetNumSystems () const |
Simulation methods | |
void | Update (Real dt) |
Private Member Functions | |
Memory allocation related methods | |
Object * | AllocObject () |
void | DeallocObject (Object *p_obj) |
Private Attributes | |
UniverseID | m_id |
std::vector< System * > | m_vecSystems |
std::vector< Object > | m_vecObjects |
std::list< Object * > | m_listFreeObjects |
Objects unattached to any. |
Represents a closed universe inhabited by animated objects.
Contains a set of Objects organized into Systems for their simulation and offers methods to create and manipulate them.
The Universe is the highest level of the collision detection test between Object geometries/shapes. Anything in a Universe can collide with everything else, except for disabled Objects/Systems/groups.
Funcionalities:
|
|
|
|
|
|
|
Experienced god required, candidates send CV to draven@users.sf.net |
|
Goodbye cruel world... |
|
Creates a new Object in the Universe.
|
|
Creates a new System in the Universe. |
|
|
|
Destroys an Object.
|
|
Destroys a System in a Universe.
|
|
|
|
|
|
Advances a timestep of dt for all the Objects currently simulated in this Universe. |
|
|
|
Objects unattached to any.
|
|
|
|
|