Timer.pkg 961 B

12345678910111213141516171819202122232425262728293031323334
  1. $#include "Core/Timer.h"
  2. class Time : public Object
  3. {
  4. unsigned GetFrameNumber() const;
  5. float GetTimeStep() const;
  6. unsigned GetTimerPeriod() const;
  7. float GetElapsedTime();
  8. static unsigned GetSystemTime();
  9. static unsigned GetTimeSinceEpoch();
  10. static String GetTimeStamp();
  11. static void Sleep(unsigned mSec);
  12. tolua_readonly tolua_property__get_set unsigned frameNumber;
  13. tolua_readonly tolua_property__get_set float timeStep;
  14. tolua_readonly tolua_property__get_set unsigned timerPeriod;
  15. tolua_readonly tolua_property__get_set float elapsedTime;
  16. };
  17. Time* GetTime();
  18. tolua_readonly tolua_property__get_set Time* time;
  19. ${
  20. #define TOLUA_DISABLE_tolua_CoreLuaAPI_GetTime00
  21. static int tolua_CoreLuaAPI_GetTime00(lua_State* tolua_S)
  22. {
  23. return ToluaGetSubsystem<Time>(tolua_S);
  24. }
  25. #define TOLUA_DISABLE_tolua_get_time_ptr
  26. #define tolua_get_time_ptr tolua_CoreLuaAPI_GetTime00
  27. $}