Changeset 8776 in orxonox.OLD for trunk/src/world_entities/creatures
- Timestamp:
- Jun 25, 2006, 11:47:54 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/world_entities/creatures/fps_player.cc
r8731 r8776 22 22 #include "src/lib/util/loading/factory.h" 23 23 24 #include "weapons/weapon_manager.h" 25 #include "weapons/test_gun.h" 26 #include "weapons/turret.h" 27 #include "weapons/cannon.h" 28 24 29 #include "key_mapper.h" 25 30 … … 63 68 this->setClassID(CL_FPS_PLAYER, "FPSPlayer"); 64 69 65 this->getWeaponManager().changeWeaponConfig(1);66 70 67 71 this->bLeft = false; … … 92 96 registerEvent(EV_MOUSE_MOTION); 93 97 94 this->getWeaponManager().setSlotCount(0); 95 96 98 99 100 // weapon manager for the fps 97 101 dynamic_cast<Element2D*>(this->getWeaponManager().getFixedTarget())->setVisibility( false); 102 103 Weapon* wpRight = new TestGun(0); 104 wpRight->setName("testGun Right"); 105 Weapon* wpLeft = new TestGun(1); 106 // Weapon* wpLeft = new Turret(); 107 wpLeft->setName("testGun Left"); 108 109 this->addWeapon(wpLeft, 1, 0); 110 this->addWeapon(wpRight,1 ,1); 111 this->getWeaponManager().changeWeaponConfig(1); 112 113 this->getWeaponManager().setSlotCount(2); 114 this->getWeaponManager().setSlotPosition(0, Vector(-0.5, .2, -1.9)); 115 this->getWeaponManager().setSlotCapability(0, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL); 116 this->getWeaponManager().setSlotPosition(1, Vector(-0.5, .2, 1.9)); 117 this->getWeaponManager().setSlotDirection(1, Quaternion(M_PI_4*.5, Vector(1,0,0))); 118 119 this->getWeaponManager().getFixedTarget()->setParent(&this->cameraNode); 120 this->getWeaponManager().getFixedTarget()->setRelCoor(1000,0,0); 121 98 122 99 123 // network registration … … 103 127 registerVar( new SynchronizeableBool( &bBackward, &bBackward, "bBackward", PERMISSION_OWNER ) ); 104 128 // registerVar( new SynchronizeableQuaternion( &mouseDir, &mouseDir, "mouseDir", PERMISSION_OWNER ) ); 129 105 130 106 131 // collision reaction registration
Note: See TracChangeset
for help on using the changeset viewer.