Changeset 10758 in orxonox.OLD for branches/presentation/src/world_entities/world_entity.cc
- Timestamp:
- Jun 21, 2007, 1:37:21 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/presentation/src/world_entities/world_entity.cc
r10757 r10758 354 354 // extract the mount points 355 355 // Patrick: they get extracted automaticaly now within the model finalization process 356 /*356 357 357 358 358 if(model != NULL) … … 362 362 PRINTF(0)("Worldentity %s has no mount points", (this->getName()).c_str()); 363 363 return; 364 } */364 } 365 365 366 366 // first get all mount points from the model … … 823 823 * @returns the shield left (this->shieldMax - shiled + this->shield) 824 824 */ 825 float WorldEntity::increaseShield(float shi led)825 float WorldEntity::increaseShield(float shield) 826 826 { 827 827 this->shield += shield; … … 1007 1007 if ( !damageable ) 1008 1008 return; 1009 1010 this->decreaseHealth(damage); 1009 1010 if (this->getShieldActive()) 1011 damage = this->decreaseShield(damage*2); 1012 this->decreaseHealth(damage/2); 1011 1013 1012 1014 if( this->getHealth() > 0) … … 1187 1189 1188 1190 void WorldEntity::regen(float time){ 1189 static float tmp; 1190 increaseHealth(time * this->healthRegen); 1191 increaseShield(time * this->shieldRegen); 1191 1192 printf("regen: %f, %f, %f ****************** ", time, this->healthRegen, this->shieldRegen); 1193 float tmp; 1194 this->increaseHealth(time * this->healthRegen); 1195 this->increaseShield(time * this->shieldRegen); 1192 1196 1193 1197
Note: See TracChangeset
for help on using the changeset viewer.