From: Perttu Ahola Date: Mon, 29 Nov 2010 17:55:41 +0000 (+0200) Subject: default setting change, random tinkering X-Git-Url: http://81.2.79.47:8989/gitweb/?a=commitdiff_plain;h=c51fef56a89d91f1c014aeb14cc0b3f9d22d81f8;p=zefram%2Fminetest%2Fminetest_engine.git default setting change, random tinkering --- diff --git a/minetest.conf.example b/minetest.conf.example index 16d9ba4e..e6c9832a 100644 --- a/minetest.conf.example +++ b/minetest.conf.example @@ -50,6 +50,6 @@ #active_object_range = 2 -#max_simultaneous_block_sends_per_client = 2 +#max_simultaneous_block_sends_per_client = 1 #max_simultaneous_block_sends_server_total = 4 diff --git a/src/main.cpp b/src/main.cpp index f7b2b2c6..8ce19ed9 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -340,7 +340,7 @@ void set_default_settings() g_settings.set("ravines_amount", "1.0"); g_settings.set("objectdata_interval", "0.2"); g_settings.set("active_object_range", "2"); - g_settings.set("max_simultaneous_block_sends_per_client", "2"); + g_settings.set("max_simultaneous_block_sends_per_client", "1"); g_settings.set("max_simultaneous_block_sends_server_total", "4"); } diff --git a/src/map.h b/src/map.h index 5b04ae9d..edfe5ef2 100644 --- a/src/map.h +++ b/src/map.h @@ -143,10 +143,10 @@ public: */ JMutexAutoLock * waitCaches() { - dstream<<"waitCaches() begin"< BLOCK_SEND_DISABLE_LIMITS_MAX_D) + + u16 maximum_simultaneous_block_sends_now = + maximum_simultaneous_block_sends; + + if(d <= BLOCK_SEND_DISABLE_LIMITS_MAX_D) + maximum_simultaneous_block_sends_now = + maximum_simultaneous_block_sends_setting; + { JMutexAutoLock lock(m_blocks_sending_mutex); // Limit is dynamically lowered when building if(m_blocks_sending.size() - >= maximum_simultaneous_block_sends) + >= maximum_simultaneous_block_sends_now) { /*dstream<<"Not sending more blocks. Queue full. " <