summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormadmaxoft <github@xoft.cz>2013-08-20 21:13:28 +0200
committermadmaxoft <github@xoft.cz>2013-08-20 21:13:28 +0200
commit654c34705c1745f2bf5eb6b6266b8cd0df05caea (patch)
tree8b24b59853823d46926c72a6c064612caedc6d60
parentFixed a warning on closing invalid plugins. (diff)
downloadcuberite-654c34705c1745f2bf5eb6b6266b8cd0df05caea.tar
cuberite-654c34705c1745f2bf5eb6b6266b8cd0df05caea.tar.gz
cuberite-654c34705c1745f2bf5eb6b6266b8cd0df05caea.tar.bz2
cuberite-654c34705c1745f2bf5eb6b6266b8cd0df05caea.tar.lz
cuberite-654c34705c1745f2bf5eb6b6266b8cd0df05caea.tar.xz
cuberite-654c34705c1745f2bf5eb6b6266b8cd0df05caea.tar.zst
cuberite-654c34705c1745f2bf5eb6b6266b8cd0df05caea.zip
-rw-r--r--source/ClientHandle.cpp10
-rw-r--r--source/Protocol/Protocol132.cpp3
2 files changed, 10 insertions, 3 deletions
diff --git a/source/ClientHandle.cpp b/source/ClientHandle.cpp
index 57830f63c..319640eea 100644
--- a/source/ClientHandle.cpp
+++ b/source/ClientHandle.cpp
@@ -1522,6 +1522,16 @@ void cClientHandle::SendChat(const AString & a_Message)
void cClientHandle::SendChunkData(int a_ChunkX, int a_ChunkZ, cChunkDataSerializer & a_Serializer)
{
+ ASSERT(m_Player != NULL);
+
+ if ((m_State == csAuthenticated) || (m_State == csDownloadingWorld))
+ {
+ if ((a_ChunkX == m_Player->GetChunkX()) && (a_ChunkZ == m_Player->GetChunkZ()))
+ {
+ m_Protocol->SendPlayerMoveLook();
+ }
+ }
+
// Check chunks being sent, erase them from m_ChunksToSend:
bool Found = false;
{
diff --git a/source/Protocol/Protocol132.cpp b/source/Protocol/Protocol132.cpp
index 2e5c305cc..26a1a9fad 100644
--- a/source/Protocol/Protocol132.cpp
+++ b/source/Protocol/Protocol132.cpp
@@ -340,9 +340,6 @@ void cProtocol132::SendLogin(const cPlayer & a_Player, const cWorld & a_World)
Flush();
SendCompass(a_World);
-
- // Send the initial position (so that confirmation works, FS #245):
- SendPlayerMoveLook();
}