Changeset 7008
- Timestamp:
- May 29, 2010, 9:33:33 PM (14 years ago)
- Location:
- code/branches/presentation3
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/presentation3/data/levels/pickups.oxw
r7007 r7008 25 25 <Light type=directional position="0,0,0" direction="0.253, 0.593, -0.765" diffuse="1.0, 0.9, 0.9, 1.0" specular="1.0, 0.9, 0.9, 1.0" /> 26 26 <SpawnPoint position="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff /> 27 28 27 29 28 <!-- Shield pickups --> … … 135 134 <!-- Pickup Collection pickups --> 136 135 137 <PickupSpawner position="-50, 0,-125" triggerDistance="10" respawnTime="30" maxSpawnedItems="10">136 <PickupSpawner position="-50,25,-125" triggerDistance="10" respawnTime="30" maxSpawnedItems="10"> 138 137 <pickup> 139 138 <PickupCollection template=triplehealthspeedinvisibilitypickup /> … … 141 140 </PickupSpawner> 142 141 143 142 <!-- PickupRepresentation for the pickup below, since it is not a standard pickup provided by pickups.oxi --> 144 143 <PickupRepresentation 145 144 pickupName = "Medium Health Pack" … … 153 152 </PickupRepresentation> 154 153 155 <PickupSpawner position="-50, 25,-125" respawnTime="60" triggerDistance="20" maxSpawnedItems="5">154 <PickupSpawner position="-50,0,-125" respawnTime="60" triggerDistance="20" maxSpawnedItems="5"> 156 155 <pickup> 157 <HealthPickup health=50 activationType=onUse durationType= continuous/>156 <HealthPickup health=50 activationType=onUse durationType=once /> 158 157 </pickup> 159 158 </PickupSpawner> -
code/branches/presentation3/src/libraries/core/OrxonoxClass.h
r6524 r7008 173 173 }; 174 174 175 SUPER_FUNCTION(11, OrxonoxClass, clone, true);175 SUPER_FUNCTION(11, OrxonoxClass, clone, false); 176 176 177 177 } -
code/branches/presentation3/src/modules/pickup/Pickup.cc
r7007 r7008 48 48 /*static*/ const std::string Pickup::durationTypeOnce_s = "once"; 49 49 /*static*/ const std::string Pickup::durationTypeContinuous_s = "continuous"; 50 51 CreateUnloadableFactory(Pickup); 50 52 51 53 Pickup::Pickup(BaseObject* creator) : BaseObject(creator) … … 146 148 void Pickup::setActivationType(const std::string& type) 147 149 { 148 if(Pickup::activationTypeImmediate_s.compare(type) )150 if(Pickup::activationTypeImmediate_s.compare(type) == 0) 149 151 { 150 152 this->activationType_ = pickupActivationType::immediate; 151 153 } 152 else if(Pickup::activationTypeOnUse_s.compare(type) )154 else if(Pickup::activationTypeOnUse_s.compare(type) == 0) 153 155 { 154 156 this->activationType_ = pickupActivationType::onUse; -
code/branches/presentation3/src/modules/pickup/Pickup.h
r6728 r7008 77 77 { 78 78 79 p rotected:79 public: 80 80 Pickup(BaseObject* creator); //!< Constructor. 81 82 public:83 81 virtual ~Pickup(); //!< Destructor. 84 82 -
code/branches/presentation3/src/modules/pickup/items/HealthPickup.cc
r6709 r7008 189 189 { 190 190 SUPER(HealthPickup, changedUsed); 191 191 192 192 //! If the pickup is not picked up nothing must be done. 193 193 if(!this->isPickedUp()) … … 290 290 if(item == NULL) 291 291 item = new HealthPickup(this); 292 292 293 293 SUPER(HealthPickup, clone, item); 294 294 295 295 HealthPickup* pickup = dynamic_cast<HealthPickup*>(item); 296 296 pickup->setHealth(this->getHealth());
Note: See TracChangeset
for help on using the changeset viewer.