From 40d295da26c9628478d89369f65e53568feb2a5b Mon Sep 17 00:00:00 2001 From: madmaxoft Date: Mon, 16 Sep 2013 09:25:23 +0200 Subject: cWorld:QueueTickBlock takes the delay in ticks. --- source/World.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'source/World.h') diff --git a/source/World.h b/source/World.h index dac30e6aa..5381dc614 100644 --- a/source/World.h +++ b/source/World.h @@ -530,17 +530,19 @@ public: /// Stops threads that belong to this world (part of deinit) void Stop(void); - void TickQueuedBlocks(float a_Dt); + /// Processes the blocks queued for ticking with a delay (m_BlockTickQueue[]) + void TickQueuedBlocks(void); struct BlockTickQueueItem { int X; int Y; int Z; - float ToWait; + int TicksToWait; }; - void QueueBlockForTick(int a_BlockX, int a_BlockY, int a_BlockZ, float a_TimeToWait); // tolua_export + /// Queues the block to be ticked after the specified number of game ticks + void QueueBlockForTick(int a_BlockX, int a_BlockY, int a_BlockZ, int a_TicksToWait); // tolua_export // tolua_begin /// Casts a thunderbolt at the specified coords @@ -633,7 +635,7 @@ private: std::vector m_RSList; std::vector m_BlockTickQueue; - std::vector m_BlockTickQueueCopy; //Second is for safely removing the objects from the queue + std::vector m_BlockTickQueueCopy; // Second is for safely removing the objects from the queue cSimulatorManager * m_SimulatorManager; cSandSimulator * m_SandSimulator; -- cgit v1.2.3