From: Perttu Ahola Date: Fri, 21 Oct 2011 08:52:26 +0000 (+0300) Subject: Some tuning in m_max_packets_per_second algorithm X-Git-Tag: 0.3.dev-20111021~2 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=7f2518393624e37e0dad6379a49084c89f7cd177;p=oweals%2Fminetest.git Some tuning in m_max_packets_per_second algorithm --- diff --git a/src/connection.cpp b/src/connection.cpp index 1c424839f..d941f368a 100644 --- a/src/connection.cpp +++ b/src/connection.cpp @@ -469,8 +469,9 @@ void Peer::reportRTT(float rtt) if(m_max_packets_per_second < 100) m_max_packets_per_second += 2; } else { - if(m_max_packets_per_second > 5) - m_max_packets_per_second *= 0.5; + m_max_packets_per_second *= 0.8; + if(m_max_packets_per_second < 10) + m_max_packets_per_second = 10; } }