Changeset 11060 for code/branches/cpp11_v3/src/orxonox/items
- Timestamp:
- Jan 13, 2016, 10:40:06 PM (9 years ago)
- Location:
- code/branches/cpp11_v3/src/orxonox/items
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/cpp11_v3/src/orxonox/items/ShipPart.cc
r11054 r11060 182 182 } 183 183 184 void ShipPart::setDamageAbsorption(float value)185 {186 this->damageAbsorption_ = value;187 }188 189 184 void ShipPart::setParent(ModularSpaceShip* ship) 190 185 { 191 186 this->parent_ = ship; 192 }193 194 /**195 @brief196 Sets the health of the ShipPart.197 */198 void ShipPart::setHealth(float health)199 {200 this->health_ = health;201 187 } 202 188 -
code/branches/cpp11_v3/src/orxonox/items/ShipPart.h
r11054 r11060 64 64 PartDestructionEvent* getDestructionEvent(unsigned int index); 65 65 66 virtual void setDamageAbsorption(float value); 67 inline float getDamageAbsorption() 66 inline void setDamageAbsorption(float value) 67 { this->damageAbsorption_ = value; } 68 inline float getDamageAbsorption() const 68 69 { return this->damageAbsorption_; } 69 70 70 71 void setParent(ModularSpaceShip* ship); 71 inline ModularSpaceShip* getParent() 72 inline ModularSpaceShip* getParent() const 72 73 { return this->parent_; } 73 74 74 75 inline void setEventExecution(bool var) 75 76 { this->eventExecution_ = var; } 76 inline bool isEventExecution() 77 inline bool isEventExecution() const 77 78 { return this->eventExecution_; } 78 79 79 virtual void setHealth(float health); 80 inline void setHealth(float health) 81 { this->health_ = health; } 80 82 inline void addHealth(float health) 81 83 { this->setHealth(this->health_ + health); }
Note: See TracChangeset
for help on using the changeset viewer.