#include <src/orxonox/objects/worldentities/ParticleSpawner.h>
Public Member Functions | |
void | configure (float lifetime=0, float startdelay=0, float destroydelay=0, bool autodestroy=true) |
void | destroy () |
bool | getAutoStart () const |
bool | getDestroyAfterLife () const |
float | getDestroydelay () const |
float | getLifetime () const |
bool | getLoop () const |
float | getStartdelay () const |
ParticleSpawner (BaseObject *creator) | |
virtual void | processEvent (Event &event) |
void | setAutoStart (bool autostart) |
void | setDestroyAfterLife (bool destroy) |
void | setDestroydelay (float destroydelay) |
void | setLifetime (float lifetime) |
void | setLoop (bool loop) |
void | setStartdelay (float startdelay) |
void | spawn () |
virtual void | XMLPort (Element &xmlelement, XMLPort::Mode mode) |
XML loading and saving. | |
virtual | ~ParticleSpawner () |
Private Member Functions | |
void | destroyParticleSpawner () |
void | fireParticleSpawner () |
void | startParticleSpawner () |
void | stopParticleSpawner () |
Private Attributes | |
bool | bAutoDestroy_ |
bool | bAutostart_ |
bool | bForceDestroy_ |
bool | bLoop_ |
bool | bSuppressStart_ |
float | destroydelay_ |
float | lifetime_ |
float | startdelay_ |
Timer< ParticleSpawner > | timer_ |
orxonox::ParticleSpawner::ParticleSpawner | ( | BaseObject * | creator | ) |
References bAutoDestroy_, bAutostart_, bForceDestroy_, bLoop_, bSuppressStart_, destroydelay_, lifetime_, RegisterObject, startdelay_, and startParticleSpawner().
orxonox::ParticleSpawner::~ParticleSpawner | ( | ) | [virtual] |
void orxonox::ParticleSpawner::configure | ( | float | lifetime = 0 , |
|
float | startdelay = 0 , |
|||
float | destroydelay = 0 , |
|||
bool | autodestroy = true | |||
) |
References bAutoDestroy_, destroydelay_, lifetime_, and startdelay_.
void orxonox::ParticleSpawner::destroy | ( | ) | [inline] |
void orxonox::ParticleSpawner::destroyParticleSpawner | ( | ) | [private] |
Referenced by stopParticleSpawner().
void orxonox::ParticleSpawner::fireParticleSpawner | ( | ) | [private] |
References orxonox::createExecutor(), lifetime_, orxonox::BaseObject::setActive(), stopParticleSpawner(), and timer_.
Referenced by startParticleSpawner().
bool orxonox::ParticleSpawner::getAutoStart | ( | ) | const [inline] |
Referenced by XMLPort().
bool orxonox::ParticleSpawner::getDestroyAfterLife | ( | ) | const [inline] |
Referenced by XMLPort().
float orxonox::ParticleSpawner::getDestroydelay | ( | ) | const [inline] |
Referenced by XMLPort().
float orxonox::ParticleSpawner::getLifetime | ( | ) | const [inline] |
Referenced by XMLPort().
bool orxonox::ParticleSpawner::getLoop | ( | ) | const [inline] |
Referenced by XMLPort().
float orxonox::ParticleSpawner::getStartdelay | ( | ) | const [inline] |
Referenced by XMLPort().
void orxonox::ParticleSpawner::processEvent | ( | Event & | event | ) | [virtual] |
void orxonox::ParticleSpawner::setAutoStart | ( | bool | autostart | ) | [inline] |
Referenced by XMLPort().
void orxonox::ParticleSpawner::setDestroyAfterLife | ( | bool | destroy | ) | [inline] |
void orxonox::ParticleSpawner::setDestroydelay | ( | float | destroydelay | ) | [inline] |
Referenced by XMLPort().
void orxonox::ParticleSpawner::setLifetime | ( | float | lifetime | ) | [inline] |
void orxonox::ParticleSpawner::setLoop | ( | bool | loop | ) | [inline] |
Referenced by XMLPort().
void orxonox::ParticleSpawner::setStartdelay | ( | float | startdelay | ) | [inline] |
Referenced by XMLPort().
void orxonox::ParticleSpawner::spawn | ( | ) | [inline] |
Referenced by processEvent().
void orxonox::ParticleSpawner::startParticleSpawner | ( | ) | [private] |
References bForceDestroy_, bSuppressStart_, orxonox::createExecutor(), fireParticleSpawner(), orxonox::ParticleEmitter::particles_, orxonox::BaseObject::setActive(), startdelay_, and timer_.
Referenced by ParticleSpawner(), and stopParticleSpawner().
void orxonox::ParticleSpawner::stopParticleSpawner | ( | ) | [private] |
References bAutoDestroy_, bForceDestroy_, bLoop_, orxonox::createExecutor(), destroydelay_, destroyParticleSpawner(), orxonox::WorldEntity::detachFromParent(), orxonox::WorldEntity::getWorldPosition(), orxonox::BaseObject::setActive(), orxonox::StaticEntity::setPosition(), startParticleSpawner(), and timer_.
Referenced by fireParticleSpawner().
void orxonox::ParticleSpawner::XMLPort | ( | Element & | xmlelement, | |
XMLPort::Mode | mode | |||
) | [virtual] |
XML loading and saving.
xmlelement | The XML-element | |
loading | Loading (true) or saving (false) |
Reimplemented from orxonox::ParticleEmitter.
References getAutoStart(), getDestroyAfterLife(), getDestroydelay(), getLifetime(), getLoop(), getStartdelay(), setAutoStart(), setDestroyAfterLife(), setDestroydelay(), setLifetime(), setLoop(), setStartdelay(), SUPER, and XMLPortParam.
bool orxonox::ParticleSpawner::bAutoDestroy_ [private] |
Referenced by configure(), ParticleSpawner(), and stopParticleSpawner().
bool orxonox::ParticleSpawner::bAutostart_ [private] |
Referenced by ParticleSpawner().
bool orxonox::ParticleSpawner::bForceDestroy_ [private] |
Referenced by ParticleSpawner(), startParticleSpawner(), and stopParticleSpawner().
bool orxonox::ParticleSpawner::bLoop_ [private] |
Referenced by ParticleSpawner(), and stopParticleSpawner().
bool orxonox::ParticleSpawner::bSuppressStart_ [private] |
Referenced by ParticleSpawner(), and startParticleSpawner().
float orxonox::ParticleSpawner::destroydelay_ [private] |
Referenced by configure(), ParticleSpawner(), and stopParticleSpawner().
float orxonox::ParticleSpawner::lifetime_ [private] |
Referenced by configure(), fireParticleSpawner(), and ParticleSpawner().
float orxonox::ParticleSpawner::startdelay_ [private] |
Referenced by configure(), ParticleSpawner(), and startParticleSpawner().
Timer<ParticleSpawner> orxonox::ParticleSpawner::timer_ [private] |
Referenced by fireParticleSpawner(), startParticleSpawner(), and stopParticleSpawner().