Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 10316 in orxonox.OLD


Ignore:
Timestamp:
Jan 24, 2007, 1:12:07 AM (17 years ago)
Author:
patrick
Message:

fixed the fps loading problem. shaking still on

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/world_entities/creatures/fps_player.cc

    r10114 r10316  
    124124  dynamic_cast<Element2D*>(this->getWeaponManager().getFixedTarget())->setVisibility( false);
    125125
    126   Weapon* wpRight = new FPSSniperRifle(0);
    127   wpRight->setName("testGun Right");
    128 /*  Weapon* wpLeft = new TestGun(1);*/
    129 //   Weapon* wpLeft = new Turret();
    130 //   wpLeft->setName("testGun Left");
    131 
    132 //   this->addWeapon(wpLeft, 1, 0);
    133126  if( State::isOnline())
     127  {
     128    Weapon* wpRight = new FPSSniperRifle(0);
     129    wpRight->setName("testGun Right");
    134130    this->addWeapon(wpRight,1, 0);
     131
     132    this->aimingSystem = new AimingSystem(this);
     133    wpRight->addChild(this->aimingSystem);
     134
     135    this->toList( OM_PLAYERS );
     136  }
     137
     138
    135139  this->getWeaponManager().changeWeaponConfig(1);
    136 
    137140  this->getWeaponManager().setSlotCount(2);
    138141  this->getWeaponManager().setSlotDirection(0, Quaternion(M_PI_4*-0.55f, Vector(0,0,1)));
     
    142145  this->getWeaponManager().setSlotPosition(1, Vector(5.0, 0.0, 0.0));
    143146
    144 //   this->getWeaponManager().getFixedTarget()->setRelDir(Quaternion(M_PI_4*-0.6f, Vector(0,0,1)));
    145 
    146 
    147147  this->getWeaponManager().setParentNode(&this->cameraNode);
    148148  this->cameraNode.addNodeFlags(PNODE_PROHIBIT_CHILD_DELETE);
     
    150150  this->getWeaponManager().getFixedTarget()->setParent(&this->cameraNode);
    151151  this->getWeaponManager().getFixedTarget()->setRelCoor(1000,0,0);
    152 
    153   this->aimingSystem = new AimingSystem(this);
    154   //this->addChild(this->aimingSystem);
    155   wpRight->addChild(this->aimingSystem);
    156 //   this->getWeaponManager().sl
    157152
    158153
     
    171166  this->initWeapon = false;
    172167  this->damageTicker = 0.0f;
    173 
    174   if( State::isOnline())
    175     toList( OM_PLAYERS );
    176168}
    177169
     
    185177  Playable::loadParams(root);
    186178}
     179
    187180
    188181void FPSPlayer::setPlayDirection(const Quaternion& quat, float speed)
Note: See TracChangeset for help on using the changeset viewer.