Changeset 4639 in orxonox.OLD for orxonox/trunk/src/lib/particles/particle_emitter.cc
- Timestamp:
- Jun 16, 2005, 1:59:25 AM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/lib/particles/particle_emitter.cc
r4597 r4639 42 42 this->setEmissionRate(emissionRate); 43 43 this->setEmissionVelocity(velocity); 44 45 ParticleEngine::getInstance()->addEmitter(this); 44 46 } 45 47 … … 129 131 { 130 132 if (!strcmp(type, "plane")) 131 this-> type = EMITTER_PLANE;133 this->setType(EMITTER_PLANE); 132 134 else if (!strcmp(type, "cube")) 133 this-> type = EMITTER_CUBE;135 this->setType(EMITTER_CUBE); 134 136 else if (!strcmp(type, "sphere")) 135 this->type = EMITTER_SPHERE; 136 else 137 this->type = EMITTER_DOT; 137 this->setType(EMITTER_SPHERE); 138 else 139 this->setType(EMITTER_DOT); 140 } 141 142 const char* ParticleEmitter::getTypeC(void) const 143 { 144 if (this->type == EMITTER_PLANE) 145 return "EMITTER_PLANE"; 146 else if (this->type == EMITTER_CUBE) 147 return "EMITTER_CUBE"; 148 else if (this->type == EMITTER_SPHERE) 149 return "EMITTER_SPHERE"; 150 else 151 return "EMITTER_DOT"; 152 153 138 154 } 139 155 … … 262 278 \brief outputs some nice debug information 263 279 */ 264 void ParticleEmitter::debug(void) 280 void ParticleEmitter::debug(void) const 265 281 { 266 282 PRINT(0)(" Emitter %s\n", this->getName()); 267 } 283 PRINT(0)(" EmissionRate: %f, Speed: %f, SpreadAngle: %f\n", this->getEmissionRate(), this->getEmissionVelocity(), this->getSpread()); 284 PRINT(0)(" Size %f, Type: %s\n", this->getSize(), this->getTypeC()); 285 }
Note: See TracChangeset
for help on using the changeset viewer.