diff options
author | Perttu Ahola <celeron55@gmail.com> | 2010-12-20 14:04:31 +0200 |
---|---|---|
committer | Perttu Ahola <celeron55@gmail.com> | 2010-12-20 14:04:31 +0200 |
commit | 5a36956f75959887f75fda90c39d56181cd1f196 (patch) | |
tree | 7532418d0f0343bde620932e226446bb75408f86 /src/server.h | |
parent | ab7477c4c3e2a3647dc4fb65c71567946d33b0e3 (diff) | |
download | minetest-5a36956f75959887f75fda90c39d56181cd1f196.tar.gz minetest-5a36956f75959887f75fda90c39d56181cd1f196.tar.bz2 minetest-5a36956f75959887f75fda90c39d56181cd1f196.zip |
working time-of-day sending from server to client
Diffstat (limited to 'src/server.h')
-rw-r--r-- | src/server.h | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/server.h b/src/server.h index c20189eb1..fddb097d0 100644 --- a/src/server.h +++ b/src/server.h @@ -265,9 +265,11 @@ public: void GetNextBlocks(Server *server, float dtime, core::array<PrioritySortedBlockTransfer> &dest); - // Connection and environment should be locked when this is called - // steps() objects of blocks not found in active_blocks, then - // adds those blocks to active_blocks + /* + Connection and environment should be locked when this is called. + steps() objects of blocks not found in active_blocks, then + adds those blocks to active_blocks + */ void SendObjectData( Server *server, float dtime, @@ -281,14 +283,6 @@ public: void SetBlockNotSent(v3s16 p); void SetBlocksNotSent(core::map<v3s16, MapBlock*> &blocks); - //void BlockEmerged(); - - /*bool IsSendingBlock(v3s16 p) - { - JMutexAutoLock lock(m_blocks_sending_mutex); - return (m_blocks_sending.find(p) != NULL); - }*/ - s32 SendingCount() { JMutexAutoLock lock(m_blocks_sending_mutex); @@ -457,6 +451,12 @@ private: // Nodes that are destinations of flowing liquid at the moment core::map<v3s16, u8> m_flow_active_nodes; + + // 0-23999 + MutexedVariable<u32> m_time_of_day; + // Used to buffer dtime for adding to m_time_of_day + float m_time_counter; + float m_time_of_day_send_timer; friend class EmergeThread; friend class RemoteClient; |