Changeset 3980 in orxonox.OLD for orxonox/trunk/src/world_entities
- Timestamp:
- Apr 26, 2005, 2:48:43 AM (20 years ago)
- Location:
- orxonox/trunk/src/world_entities
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/world_entities/player.cc
r3966 r3980 52 52 //weapons: 53 53 this->weaponMan = new WeaponManager(); 54 Weapon* wpRight = new TestGun(this, Vector(-2.6, 0.1, 3.0), Quaternion(), 0);54 Weapon* wpRight = new TestGun(this, Vector(-2.6, 0.1, 3.0), Quaternion(), 0); 55 55 Weapon* wpLeft = new TestGun(this, Vector(-2.6, 0.1, -3.0), Quaternion(), 1); 56 56 -
orxonox/trunk/src/world_entities/test_gun.cc
r3888 r3980 49 49 this->objectComponent1 = new PNode(); 50 50 this->animation1 = new Animation3D(this->objectComponent1); 51 //this->animation2 = new Animation3D(this); 51 52 parent->addChild(this->objectComponent1, PNODE_ALL); 52 53 53 54 this->animation1->setInfinity(ANIM_INF_CONSTANT); 54 // ANIM_LINEAR was ANIM_NEG_EXP55 //this->animation2->setInfinity(ANIM_INF_CONSTANT); 55 56 if( this->leftRight == W_LEFT) 56 57 { … … 60 61 this->animation1->addKeyFrame(Vector(-3.0, 0.1, 3.0), Quaternion(), 0.5, ANIM_LINEAR); 61 62 this->animation1->addKeyFrame(Vector(-2.6, 0.1, 3.0), Quaternion(), 0.1, ANIM_LINEAR); 63 64 //this->animation2->addKeyFrame(Vector(-2.6, 0.1, 3.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_LINEAR); 65 //this->animation2->addKeyFrame(Vector(-2.6, 0.1, 1.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_LINEAR); 62 66 } 63 67 else if( this->leftRight == W_RIGHT) … … 65 69 this->projectileOffset = Vector(1.0, 0.0, 0.5); 66 70 67 this->animation1->addKeyFrame(Vector(-2.6, 0.1, -2.5), Quaternion(), 0.1, ANIM_ LINEAR);68 this->animation1->addKeyFrame(Vector(-3.0, 0.1, -2.5), Quaternion(), 0.5, ANIM_ LINEAR);69 this->animation1->addKeyFrame(Vector(-2.6, 0.1, -2.5), Quaternion(), 0.1, ANIM_ LINEAR);71 this->animation1->addKeyFrame(Vector(-2.6, 0.1, -2.5), Quaternion(), 0.1, ANIM_NEG_EXP); 72 this->animation1->addKeyFrame(Vector(-3.0, 0.1, -2.5), Quaternion(), 0.5, ANIM_NEG_EXP); 73 this->animation1->addKeyFrame(Vector(-2.6, 0.1, -2.5), Quaternion(), 0.1, ANIM_NEG_EXP); 70 74 } 71 75 } … … 89 93 */ 90 94 void TestGun::activate() 91 {} 95 { 96 printf("ACTIVATE \n"); 97 this->animation2->replay(); 98 } 92 99 93 100 … … 100 107 */ 101 108 void TestGun::deactivate() 102 {} 109 { 110 printf("DEACTIVATE\n"); 111 } 103 112 104 113
Note: See TracChangeset
for help on using the changeset viewer.