Changeset 728 for code/branches/FICN/src/orxonox/particle
- Timestamp:
- Dec 30, 2007, 6:56:58 PM (17 years ago)
- Location:
- code/branches/FICN/src/orxonox/particle
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/FICN/src/orxonox/particle/ParticleInterface.cc
r715 r728 67 67 { 68 68 //Abgleichen der anderen Emitter an die Variabeln 69 for (int i=1; i <numberOfEmitters_; i++) {69 for (int i=1; i < numberOfEmitters_; i++) { 70 70 particleSystem_->getEmitter(i)->setColour( colour_ ); 71 71 particleSystem_->getEmitter(i)->setTimeToLive( distance_ ); … … 130 130 void ParticleInterface::setDirection ( Vector3 direction ) 131 131 { 132 for(int i=0; i <numberOfEmitters_; i++) {132 for(int i=0; i < numberOfEmitters_; i++) { 133 133 particleSystem_->getEmitter(i)->setDirection(direction); 134 134 } … … 137 137 void ParticleInterface::switchEnable(){ 138 138 bool enable=(!(particleSystem_->getEmitter(0)->getEnabled())); 139 for(int i=0; i <numberOfEmitters_; i++) {139 for(int i=0; i < numberOfEmitters_; i++) { 140 140 particleSystem_->getEmitter(i)->setEnabled(enable); 141 141 } -
code/branches/FICN/src/orxonox/particle/ParticleInterface.h
r716 r728 28 28 ~ParticleInterface( void ); 29 29 30 void inline addToSceneNode( Ogre::SceneNode* sceneNode ) { sceneNode_ = sceneNode; sceneNode_->attachObject(particleSystem_);}; 31 void inline detachFromSceneNode( void ) { sceneNode_->detachObject(particleSystem_); sceneNode_ = NULL;}; 30 inline void addToSceneNode( Ogre::SceneNode* sceneNode ) 31 { sceneNode_ = sceneNode; sceneNode_->attachObject(particleSystem_);}; 32 inline void detachFromSceneNode( void ) 33 { sceneNode_->detachObject(particleSystem_); sceneNode_ = NULL;}; 32 34 33 35 Ogre::ParticleEmitter* getEmitter ( int emitterNr ); … … 35 37 36 38 Vector3 getPositionOfEmitter ( int emitterNr ); 37 inline void setPositionOfEmitter ( int emitterNr, Vector3 position ) { particleSystem_->getEmitter(emitterNr)->setPosition(position); }; 39 inline void setPositionOfEmitter ( int emitterNr, Vector3 position ) 40 { particleSystem_->getEmitter(emitterNr)->setPosition(position); }; 38 41 39 inline Vector3 getDirection ( void ) { return particleSystem_->getEmitter(0)->getDirection(); }; 42 inline Vector3 getDirection ( void ) 43 { return particleSystem_->getEmitter(0)->getDirection(); }; 40 44 void setDirection ( Vector3 direction ); 41 45 42 inline Real getVelocity() {return velocity_; }; 46 inline Real getVelocity() 47 {return velocity_; }; 43 48 void setVelocity( Real v ); 44 49 45 inline int getRate() { return rate_; }; 50 inline int getRate() 51 { return rate_; }; 46 52 void setRate( int r ); 47 53 48 inline Real getDistance() { return distance_; }; 54 inline Real getDistance() 55 { return distance_; }; 49 56 void setDistance( Real d ); 50 57 51 inline ColourValue getColour( void ) {return colour_;}; 58 inline ColourValue getColour( void ) 59 {return colour_;}; 52 60 void setColour( ColourValue colour ); 53 61 54 62 void switchEnable(); 55 63 56 inline Ogre::ParticleSystem* getParticleSystem() { return this->particleSystem_; }; 64 inline Ogre::ParticleSystem* getParticleSystem() 65 { return this->particleSystem_; }; 57 66 58 67 private:
Note: See TracChangeset
for help on using the changeset viewer.