diff options
Diffstat (limited to 'src/libjin/Time/je_timer.h')
-rw-r--r-- | src/libjin/Time/je_timer.h | 44 |
1 files changed, 42 insertions, 2 deletions
diff --git a/src/libjin/Time/je_timer.h b/src/libjin/Time/je_timer.h index e5488cc..82b4b52 100644 --- a/src/libjin/Time/je_timer.h +++ b/src/libjin/Time/je_timer.h @@ -11,19 +11,49 @@ namespace JinEngine namespace Time { + /// + /// + /// class Timers { public: typedef void(*timer_callback)(void* prameters); + /// + /// + /// Timers(); + + /// + /// + /// ~Timers(); + + /// + /// + /// void update(int ms); + + /// + /// + /// void every(int ms, timer_callback callback, void* paramters); + + /// + /// + /// void after(int ms, timer_callback callback, void* paramters); + + /// + /// + /// void repeat(int ms, int count, timer_callback callback, void* paramters); private: + + /// + /// + /// class Timer { public: @@ -48,7 +78,10 @@ namespace JinEngine std::vector<Timer*> timers; }; - + + /// + /// + /// inline void sleep(int ms) { #if LIBJIN_TIME_SDL @@ -56,6 +89,9 @@ namespace JinEngine #endif } + /// + /// + /// inline double getSecond() { #if LIBJIN_TIME_SDL @@ -63,6 +99,9 @@ namespace JinEngine #endif } + /// + /// + /// inline double getMilliSecond() { #if LIBJIN_TIME_SDL @@ -74,4 +113,5 @@ namespace JinEngine } // namespace JinEngine #endif // LIBJIN_MODULES_TIME -#endif // __JE_TIMER_H + +#endif // __JE_TIMER_H
\ No newline at end of file |