From f8328346b522bf9e03f299b7b179d707cb584e2f Mon Sep 17 00:00:00 2001 From: "madmaxoft@gmail.com" Date: Wed, 30 May 2012 18:20:38 +0000 Subject: Lua plugins can now query the world for various queue sizes ( http://forum.mc-server.org/showthread.php?tid=432 ) git-svn-id: http://mc-server.googlecode.com/svn/trunk@524 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/cWorld.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source/cWorld.h') diff --git a/source/cWorld.h b/source/cWorld.h index 5e448d79b..bd5e741cf 100644 --- a/source/cWorld.h +++ b/source/cWorld.h @@ -275,6 +275,11 @@ public: /// Returns the number of chunks loaded and dirty, and in the lighting queue void GetChunkStats(int & a_NumValid, int & a_NumDirty, int & a_NumInLightingQueue); + // Various queues length queries (cannot be const, they lock their CS): + inline int GetGeneratorQueueLength (void) { return m_Generator.GetQueueLength(); } // tolua_export + inline int GetLightingQueueLength (void) { return m_Lighting.GetQueueLength(); } // tolua_export + inline int GetStorageLoadQueueLength(void) { return m_Storage.GetLoadQueueLength(); } // tolua_export + inline int GetStorageSaveQueueLength(void) { return m_Storage.GetSaveQueueLength(); } // tolua_export void Tick(float a_Dt); -- cgit v1.2.3