diff options
author | Perttu Ahola <celeron55@gmail.com> | 2010-12-23 12:10:46 +0200 |
---|---|---|
committer | Perttu Ahola <celeron55@gmail.com> | 2010-12-23 12:10:46 +0200 |
commit | a55850e4dcc3440fdadb9fc94df3f2ef02f5a34d (patch) | |
tree | acd394bb791dc81aff2515083351e23e25346430 /src/client.h | |
parent | 03d67af9e85b9641556c8ea2276aa07f6fca175e (diff) | |
download | dragonfireclient-a55850e4dcc3440fdadb9fc94df3f2ef02f5a34d.tar.xz |
fixed crack animation timing in client
Diffstat (limited to 'src/client.h')
-rw-r--r-- | src/client.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/client.h b/src/client.h index bfec7730d..3c8bbfaf6 100644 --- a/src/client.h +++ b/src/client.h @@ -251,6 +251,15 @@ public: v3s16 blockpos = ((ClientMap&)m_env.getMap()).clearTempMod(p); m_env.getMap().updateMeshes(blockpos, m_env.getDayNightRatio()); } + + float getAvgRtt() + { + JMutexAutoLock lock(m_con_mutex); + con::Peer *peer = m_con.GetPeerNoEx(PEER_ID_SERVER); + if(peer == NULL) + return 0.0; + return peer->avg_rtt; + } private: |