Changeset 9709 in orxonox.OLD for branches/new_class_id/src/world_entities/projectiles/boomerang_projectile.cc
- Timestamp:
- Aug 31, 2006, 10:51:08 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/new_class_id/src/world_entities/projectiles/boomerang_projectile.cc
r9235 r9709 20 20 21 21 #include "state.h" 22 #include "class_list.h"23 22 24 23 #include "dot_emitter.h" … … 27 26 #include "debug.h" 28 27 29 CREATE_FAST_FACTORY_STATIC(BoomerangProjectile, CL_BOOMERANG_PROJECTILE); 28 #include "class_id.h" 29 NewObjectListDefinitionID(BoomerangProjectile, CL_BOOMERANG_PROJECTILE); 30 CREATE_FAST_FACTORY_STATIC(BoomerangProjectile); 30 31 31 32 /** … … 34 35 BoomerangProjectile::BoomerangProjectile () : Projectile() 35 36 { 36 this-> setClassID(CL_BOOMERANG_PROJECTILE, "BoomerangProjectile");37 this->registerObject(this, BoomerangProjectile::_objectList); 37 38 38 39 this->loadModel("models/projectiles/orx-rocket.obj", 2.0); … … 60 61 61 62 /* this is normaly done by World.cc by deleting the ParticleEngine */ 62 if (BoomerangProjectile::trailParticles != NULL && ClassList::getList(CL_BOOMERANG_PROJECTILE)->size() <= 1)63 { 64 if ( ClassList::exists(BoomerangProjectile::trailParticles, CL_PARTICLE_SYSTEM))63 if (BoomerangProjectile::trailParticles != NULL && BoomerangProjectile::objectList().size() <= 1) 64 { 65 if (ParticleSystem::objectList().exists(BoomerangProjectile::trailParticles)) 65 66 delete BoomerangProjectile::trailParticles; 66 67 BoomerangProjectile::trailParticles = NULL; 67 68 } 68 if (BoomerangProjectile::explosionParticles != NULL && ClassList::getList(CL_BOOMERANG_PROJECTILE)->size() <= 1)69 { 70 if ( ClassList::exists(BoomerangProjectile::explosionParticles, CL_PARTICLE_SYSTEM))69 if (BoomerangProjectile::explosionParticles != NULL && BoomerangProjectile::objectList().size() <= 1) 70 { 71 if (ParticleSystem::objectList().exists(BoomerangProjectile::explosionParticles)) 71 72 delete BoomerangProjectile::explosionParticles; 72 73 BoomerangProjectile::explosionParticles = NULL;
Note: See TracChangeset
for help on using the changeset viewer.