Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3757 in orxonox.OLD for orxonox/trunk/src/world_entities/test_gun.cc


Ignore:
Timestamp:
Apr 8, 2005, 1:01:24 AM (20 years ago)
Author:
patrick
Message:

orxonox/trunk: weapon projectile now spawn at the right place

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/world_entities/test_gun.cc

    r3755 r3757  
    4747  this->leftRight = leftRight;
    4848
     49  if( this->leftRight == 0)
     50    this->projOffset = new Vector(1.0, 0.0, -0.35);
     51  else if( this->leftRight == 1)
     52    this->projOffset = new Vector(1.0, 0.0, 0.5);
     53
    4954  this->animator = SimpleAnimation::getInstance();
    5055  this->dummy1 = new WorldEntity(); /* a world entity that is not drawed: use this for the weapon */
     
    117122  Projectile* pj = new TestBullet(this);
    118123
    119   pj->setAbsCoor(this->getAbsCoor());
     124  pj->setAbsCoor(this->getAbsCoor() + *this->projOffset);
    120125  pj->setAbsDir(this->getAbsDir());
    121126
Note: See TracChangeset for help on using the changeset viewer.