Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 28, 2006, 6:02:33 PM (19 years ago)
Author:
patrick
Message:

door animation even nicer implemented

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/single_player_map/src/world_entities/door.cc

    r8879 r8880  
    2222
    2323#include "interactive_model.h"
    24 #include "md2/md2Model.h"
     24
    2525
    2626#include "door.h"
     
    3232
    3333CREATE_FACTORY(Door, CL_DOOR);
     34
     35
     36
     37//! list of all different animations a std md2model supports
     38sAnim Door::animationList[2] =
     39{
     40 // begin, end, fps, interruptable
     41  {   0,  15,  9,  0 },   //!< OPEN
     42  {   15, 30,  9,  0 }    //!< CLOSE
     43};
     44
    3445
    3546
     
    7889 * sets the animatin of this entity
    7990 */
    80 void  Door::setAnimation(int firstFrame, int lastFrame, int fps, int bStoppable, int animPlayback)
     91void  Door::setAnimation(int animNum, int playbackMode)
    8192{
    8293  if( likely(this->getModel(0) != NULL))
     
    108119    return;
    109120
    110   this->setAnimation(0, 1, 5, 0, MD2_ANIM_ONCE);
     121  this->setAnimation(DOOR_OPEN, MD2_ANIM_ONCE);
    111122
    112123}
Note: See TracChangeset for help on using the changeset viewer.