Changeset 11065 for code/branches/cpp11_v3/src/modules/weapons
- Timestamp:
- Jan 17, 2016, 1:59:00 PM (8 years ago)
- Location:
- code/branches/cpp11_v3/src/modules/weapons
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/cpp11_v3/src/modules/weapons/projectiles/MineProjectile.cc
r11054 r11065 112 112 modelRing4_->yaw(Degree(270)); 113 113 114 emitter_ = NULL;114 emitter_ = nullptr; 115 115 116 116 if (GameMode::isMaster()) … … 217 217 { 218 218 // Damage all pawns within the damage radius 219 for ( ObjectList<Pawn>::iterator it = ObjectList<Pawn>().begin(); it; ++it)219 for (Pawn* pawn : ObjectList<Pawn>()) 220 220 { 221 Vector3 distanceVector = it->getWorldPosition()-this->getWorldPosition();221 Vector3 distanceVector = pawn->getWorldPosition()-this->getWorldPosition(); 222 222 if(distanceVector.length()< damageRadius_) 223 223 { 224 it->hit(this->getShooter(), it->getWorldPosition(), NULL, this->getDamage(), this->getHealthDamage(), this->getShieldDamage());224 pawn->hit(this->getShooter(), pawn->getWorldPosition(), nullptr, this->getDamage(), this->getHealthDamage(), this->getShieldDamage()); 225 225 } 226 226 } -
code/branches/cpp11_v3/src/modules/weapons/projectiles/MineProjectile.h
r11064 r11065 57 57 virtual ~MineProjectile(); 58 58 59 virtual void XMLEventPort(Element& xmlelement, XMLPort::Mode mode) ;59 virtual void XMLEventPort(Element& xmlelement, XMLPort::Mode mode) override; 60 60 61 61 void setMaxTimeUntilExplosion(float maxTimeUntilExplosion); -
code/branches/cpp11_v3/src/modules/weapons/weaponmodes/MineGun.h
r11052 r11065 59 59 virtual ~MineGun(); 60 60 61 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode) ;62 virtual void fire() ;61 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode) override; 62 virtual void fire() override; 63 63 64 64 inline float getMaxTimeUntilExplosion() const
Note: See TracChangeset
for help on using the changeset viewer.