Changeset 11071 for code/trunk/src/orxonox/worldentities/pawns/Pawn.h
- Timestamp:
- Jan 17, 2016, 10:29:21 PM (8 years ago)
- Location:
- code/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk
- Property svn:mergeinfo changed
-
code/trunk/src/orxonox/worldentities/pawns/Pawn.h
r11052 r11071 63 63 virtual ~Pawn(); 64 64 65 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode) ;66 virtual void XMLEventPort(Element& xmlelement, XMLPort::Mode mode) ;67 virtual void tick(float dt) ;65 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode) override; 66 virtual void XMLEventPort(Element& xmlelement, XMLPort::Mode mode) override; 67 virtual void tick(float dt) override; 68 68 69 69 inline bool isAlive() const … … 71 71 72 72 73 v irtual void setHealth(float health);73 void setHealth(float health); 74 74 inline void addHealth(float health) 75 75 { this->setHealth(this->health_ + health); } … … 89 89 { return this->initialHealth_; } 90 90 91 v irtual void setShieldHealth(float shieldHealth);91 void setShieldHealth(float shieldHealth); 92 92 93 93 inline float getShieldHealth() … … 100 100 { return (this->getShieldHealth() > 0); } 101 101 102 v irtual void setMaxShieldHealth(float maxshieldhealth);102 void setMaxShieldHealth(float maxshieldhealth); 103 103 inline float getMaxShieldHealth() const 104 104 { return this->maxShieldHealth_; } … … 119 119 { return this->shieldAbsorption_; } 120 120 121 v irtual void setShieldRechargeRate(float shieldRechargeRate);121 void setShieldRechargeRate(float shieldRechargeRate); 122 122 inline float getShieldRechargeRate() const 123 123 { return this->shieldRechargeRate_; } 124 124 125 v irtual void setShieldRechargeWaitTime(float shieldRechargeWaitTime);125 void setShieldRechargeWaitTime(float shieldRechargeWaitTime); 126 126 inline float getShieldRechargeWaitTime() const 127 127 { return this->shieldRechargeWaitTime_; } … … 133 133 { this->shieldRechargeWaitCountdown_ = this->getShieldRechargeWaitTime(); } // TODO: Implement in Projectile.cc 134 134 135 v irtual void decreaseShieldRechargeCountdownTime(float dt);135 void decreaseShieldRechargeCountdownTime(float dt); 136 136 137 137 /** @brief Sets the state of the pawns vulnerability. @param bVulnerable */ … … 157 157 virtual void kill(); 158 158 159 virtual void fired(unsigned int firemode) ;159 virtual void fired(unsigned int firemode) override; 160 160 virtual void postSpawn(); 161 161 … … 170 170 void addWeaponPackXML(WeaponPack * wPack); 171 171 WeaponPack * getWeaponPack(unsigned int index) const; 172 std::vector<WeaponPack *> * getAllWeaponPacks();173 172 174 173 void addMunitionXML(Munition* munition); … … 201 200 202 201 203 virtual void startLocalHumanControl() ;202 virtual void startLocalHumanControl() override; 204 203 205 204 void setAimPosition( Vector3 position ) … … 208 207 { return this->aimPosition_; } 209 208 210 virtual const Vector3& getCarrierPosition(void) const 209 virtual const Vector3& getCarrierPosition(void) const override 211 210 { return this->getWorldPosition(); }; 212 211 213 virtual void changedVisibility() ;212 virtual void changedVisibility() override; 214 213 215 214 void setExplosionSound(const std::string& engineSound); 216 215 const std::string& getExplosionSound(); 217 216 218 virtualconst WeaponSystem* getWeaponSystem() const217 inline const WeaponSystem* getWeaponSystem() const 219 218 { return this->weaponSystem_; } 220 219 221 220 protected: 222 virtual void preDestroy() ;223 224 virtual void setPlayer(PlayerInfo* player) ;225 virtual void removePlayer() ;221 virtual void preDestroy() override; 222 223 virtual void setPlayer(PlayerInfo* player) override; 224 virtual void removePlayer() override; 226 225 227 226 virtual void death(); … … 231 230 virtual void spawneffect(); 232 231 233 virtual void damage(float damage, float healthdamage = 0.0f, float shielddamage = 0.0f, Pawn* originator = NULL, const btCollisionShape* cs = NULL);232 virtual void damage(float damage, float healthdamage = 0.0f, float shielddamage = 0.0f, Pawn* originator = nullptr, const btCollisionShape* cs = nullptr); 234 233 235 234 bool bAlive_; 236 235 bool bVulnerable_; ///< If false the pawn may not ged damaged 237 236 238 virtual std::vector<PickupCarrier*>* getCarrierChildren(void) const 237 virtual std::vector<PickupCarrier*>* getCarrierChildren(void) const override 239 238 { return new std::vector<PickupCarrier*>(); } 240 virtual PickupCarrier* getCarrierParent(void) const 241 { return NULL; }239 virtual PickupCarrier* getCarrierParent(void) const override 240 { return nullptr; } 242 241 243 242
Note: See TracChangeset
for help on using the changeset viewer.