Changeset 6054 in orxonox.OLD for trunk/src/world_entities/weapons/guided_missile.cc
- Timestamp:
- Dec 11, 2005, 6:23:42 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/world_entities/weapons/guided_missile.cc
r5994 r6054 152 152 { 153 153 //Vector v = *this->flightDirection * ( this->speed * time * 1000 + 0.1); 154 if (target != NULL && target->getParent() != NullParent::getInstance())154 if (target.getParent() != NullParent::getInstance()) 155 155 { 156 velocity += ((target ->getAbsCoor() - this->getAbsCoor()).getNormalized())*agility;156 velocity += ((target.getAbsCoor() - this->getAbsCoor()).getNormalized())*agility; 157 157 float speed = velocity.len(); 158 158 if (speed > this->maxVelocity)
Note: See TracChangeset
for help on using the changeset viewer.