Changeset 2954 for code/branches/gametypes
- Timestamp:
- May 4, 2009, 5:28:59 PM (16 years ago)
- Location:
- code/branches/gametypes/src/orxonox/objects/worldentities
- Files:
-
- 2 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/gametypes/src/orxonox/objects/worldentities/CMakeLists.txt
r2826 r2954 23 23 PongBall.cc 24 24 PongBat.cc 25 ForceField.cc 25 26 ) 26 27 -
code/branches/gametypes/src/orxonox/objects/worldentities/MobileEntity.cc
r2826 r2954 166 166 } 167 167 168 void MobileEntity::applyCentralForce(const Vector3& force) 169 { 170 if (this->isDynamic()) 171 this->physicalBody_->applyCentralForce(btVector3(force.x * this->getMass(), force.y * this->getMass(), force.z * this->getMass())); 172 } 173 168 174 bool MobileEntity::isCollisionTypeLegal(WorldEntity::CollisionType type) const 169 175 { -
code/branches/gametypes/src/orxonox/objects/worldentities/MobileEntity.h
r2826 r2954 75 75 { return this->angularAcceleration_; } 76 76 77 void applyCentralForce(const Vector3& force); 78 inline void applyCentralForce(float x, float y, float z) 79 { this->applyCentralForce(Vector3(x, y, z)); } 80 77 81 inline void setRotationRate(Degree rate) 78 82 { this->setAngularVelocity(this->getAngularVelocity().normalisedCopy() * rate.valueRadians()); }
Note: See TracChangeset
for help on using the changeset viewer.