mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Optimized map saving and sending (server-side)
This commit is contained in:
parent
42fb1ba676
commit
2830095366
7 changed files with 174 additions and 61 deletions
|
@ -250,6 +250,8 @@ public:
|
|||
pending_serialization_version = SER_FMT_VER_INVALID;
|
||||
m_nearest_unsent_d = 0;
|
||||
m_nearest_unsent_reset_timer = 0.0;
|
||||
m_nothing_to_send_counter = 0;
|
||||
m_nothing_to_send_pause_timer = 0;
|
||||
}
|
||||
~RemoteClient()
|
||||
{
|
||||
|
@ -350,6 +352,10 @@ private:
|
|||
This is resetted by PrintInfo()
|
||||
*/
|
||||
u32 m_excess_gotblocks;
|
||||
|
||||
// CPU usage optimization
|
||||
u32 m_nothing_to_send_counter;
|
||||
float m_nothing_to_send_pause_timer;
|
||||
};
|
||||
|
||||
class Server : public con::PeerHandler, public MapEventReceiver,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue