Changeset 9705 in orxonox.OLD for branches/new_class_id/src/world_entities/power_ups
- Timestamp:
- Aug 25, 2006, 9:44:53 PM (18 years ago)
- Location:
- branches/new_class_id/src/world_entities/power_ups
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/new_class_id/src/world_entities/power_ups/param_power_up.cc
r9656 r9705 27 27 28 28 29 29 #include "class_id.h" 30 30 CREATE_FACTORY(ParamPowerUp, CL_PARAM_POWER_UP); 31 NewObjectListDefinitionID(ParamPowerUp, CL_PARAM_POWER_UP); 31 32 32 33 const char* ParamPowerUp::paramTypes[] = { … … 58 59 void ParamPowerUp::init() 59 60 { 60 this-> setClassID(CL_PARAM_POWER_UP, "ParamPowerUp");61 this->registerObject(this, ParamPowerUp::_objectList); 61 62 this->value = 0; 62 63 this->max_value = 0; -
branches/new_class_id/src/world_entities/power_ups/param_power_up.h
r7954 r9705 20 20 21 21 class ParamPowerUp : public PowerUp { 22 NewObjectListDeclaration(ParamPowerUp); 22 23 23 24 public: -
branches/new_class_id/src/world_entities/power_ups/power_up.cc
r9406 r9705 25 25 26 26 27 NewObjectListDefinition(PowerUp); 27 28 28 29 PowerUp::PowerUp(float r, float g, float b) 29 30 { 30 this-> setClassID(CL_POWER_UP, "PowerUp");31 this->registerObject(this, PowerUp::_objectList); 31 32 32 33 this->respawnType = RESPAWN_TIME; … … 120 121 void PowerUp::collidesWith (WorldEntity* entity, const Vector& location) 121 122 { 122 if(this->collider != entity && entity->isA( CL_EXTENDABLE))123 if(this->collider != entity && entity->isA(Extendable::classID())) 123 124 { 124 125 this->collider = entity; -
branches/new_class_id/src/world_entities/power_ups/power_up.h
r7954 r9705 21 21 22 22 class PowerUp : public WorldEntity { 23 NewObjectListDeclaration(PowerUp); 23 24 24 25 public: -
branches/new_class_id/src/world_entities/power_ups/weapon_power_up.cc
r9406 r9705 27 27 28 28 29 29 #include "class_id.h" 30 30 CREATE_FACTORY(WeaponPowerUp, CL_WEAPON_POWER_UP); 31 NewObjectListDefinitionID(WeaponPowerUp, CL_WEAPON_POWER_UP); 31 32 32 33 WeaponPowerUp::WeaponPowerUp(const TiXmlElement* root) : PowerUp(1.0, 1.0, 0.0) … … 45 46 void WeaponPowerUp::init() 46 47 { 47 this-> setClassID(CL_WEAPON_POWER_UP, "WeaponPowerUp");48 this->registerObject(this, WeaponPowerUp::_objectList); 48 49 this->loadPickupSound("sound/powerups/whats this2.wav"); 49 50 -
branches/new_class_id/src/world_entities/power_ups/weapon_power_up.h
r7954 r9705 14 14 15 15 class WeaponPowerUp : public PowerUp { 16 16 NewObjectListDeclaration(WeaponPowerUp); 17 17 public: 18 18 WeaponPowerUp(const TiXmlElement* root = NULL);
Note: See TracChangeset
for help on using the changeset viewer.