Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 14, 2008, 11:26:34 AM (16 years ago)
Author:
rgrieder
Message:

added TickableReal to tick objects that shouldn't be affected by setTimeFactor

Location:
code/branches/input/src/core
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • code/branches/input/src/core/InputBuffer.h

    r1259 r1271  
    4343  {};
    4444
    45   class _CoreExport InputBuffer : public KeyHandler, public Tickable
     45  class _CoreExport InputBuffer : public KeyHandler, public TickableReal
    4646  {
    4747    struct InputBufferListenerTuple
  • code/branches/input/src/core/InputManager.h

    r1259 r1271  
    5151  */
    5252  class _CoreExport InputManager
    53         : public Tickable,
     53        : public TickableReal,
    5454          public OIS::KeyListener, public OIS::MouseListener, public OIS::JoyStickListener
    5555  {
  • code/branches/input/src/core/Tickable.cc

    r1062 r1271  
    4040        RegisterRootObject(Tickable);
    4141    }
     42
     43    /**
     44        @brief Constructor: Registers the object in the TickableReal-list
     45    */
     46    TickableReal::TickableReal()
     47    {
     48        RegisterRootObject(TickableReal);
     49    }
    4250}
  • code/branches/input/src/core/Tickable.h

    r1062 r1271  
    6262    };
    6363
     64    //! The Tickable interface provides a tick(dt) function, that gets called every frame.
     65    class _CoreExport TickableReal : virtual public OrxonoxClass
     66    {
     67        public:
     68            /**
     69                @brief Gets called every frame.
     70                @param dt The time since the last frame in seconds
     71            */
     72            virtual void tick(float dt) = 0;
     73
     74        protected:
     75            TickableReal();
     76    };
     77
    6478}
    6579
Note: See TracChangeset for help on using the changeset viewer.