Changeset 9104 in orxonox.OLD for branches/presentation
- Timestamp:
- Jul 4, 2006, 5:06:02 AM (19 years ago)
- Location:
- branches/presentation/src/world_entities
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/presentation/src/world_entities/creatures/fps_player.cc
r9103 r9104 149 149 registerVar( new SynchronizeableFloat( &heading, &heading, "heading", PERMISSION_OWNER ) ); 150 150 registerVar( new SynchronizeableFloat( &attitude, &attitude, "attitude", PERMISSION_OWNER ) ); 151 152 153 // collision reaction registration154 this->subscribeReaction(CREngine::CR_PHYSICS_GROUND_WALK, CL_BSP_ENTITY);155 151 } 156 152 … … 225 221 { 226 222 this->bPosBut = false; 227 printf("mechanic:walkTo( %f, mheight, %f)\n",this->getAbsCoorX(),this->getAbsCoorZ());223 printf("mechanic:walkTo( %f, %f, %f)\n",this->getAbsCoorX(),this->getAbsCoorY(),this->getAbsCoorZ()); 228 224 } 229 225 … … 275 271 velocity *= 100; 276 272 277 if(velocity.len() != 0.0f) 273 if( this->bJump && likely(this->getModel(0) != NULL)) 274 { 275 if( ((InteractiveModel*)this->getModel(0))->getAnimation() != JUMP) 276 ((InteractiveModel*)this->getModel(0))->setAnimation(JUMP); 277 } 278 else if(velocity.len() != 0.0f) 278 279 { 279 280 if( ((InteractiveModel*)this->getModel(0))->getAnimation() != RUN) … … 316 317 317 318 318 if( this->bJump && likely(this->getModel(0) != NULL)) 319 { 320 if( ((InteractiveModel*)this->getModel(0))->getAnimation() != JUMP) 321 ((InteractiveModel*)this->getModel(0))->setAnimation(JUMP); 322 } 319 323 320 324 321 // else if( this->bFire && likely(this->getModel(0) != NULL)) … … 376 373 } 377 374 else if( event.type == KeyMapper::PEV_JUMP) 375 this->bJump = event.bPressed; 378 376 this->bPosBut = event.bPressed; 379 377 } -
branches/presentation/src/world_entities/playable.cc
r9078 r9104 67 67 this->bDead = false; 68 68 69 //subscribe to collision reaction 69 70 this->subscribeReaction(CREngine::CR_PHYSICS_GROUND_WALK, CL_BSP_ENTITY); 70 71
Note: See TracChangeset
for help on using the changeset viewer.