diff options
Diffstat (limited to '')
-rw-r--r-- | source/ClientHandle.cpp | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/source/ClientHandle.cpp b/source/ClientHandle.cpp index 1585a08b0..af0f686d1 100644 --- a/source/ClientHandle.cpp +++ b/source/ClientHandle.cpp @@ -962,6 +962,24 @@ bool cClientHandle::HandleHandshake(const AString & a_Username) +void cClientHandle::HandleEntityAction(int a_EntityID, char a_ActionID) +{ + if( a_EntityID != m_Player->GetUniqueID() ) + { + // We should only receive entity actions from the entity that is performing the action + return; + } + + if( a_ActionID == 3 ) // Leave bed + { + m_Player->GetWorld()->BroadcastPlayerAnimation( *m_Player, 3 ); + } +} + + + + + void cClientHandle::SendData(const char * a_Data, int a_Size) { { @@ -1461,6 +1479,15 @@ void cClientHandle::SendBlockBreakAnim(int a_entityID, int a_blockX, int a_block +void cClientHandle::SendUseBed(const cEntity & a_Entity, int a_BlockX, int a_BlockY, int a_BlockZ ) +{ + m_Protocol->SendUseBed(a_Entity, a_BlockX, a_BlockY, a_BlockZ); +} + + + + + void cClientHandle::SendChunkData(int a_ChunkX, int a_ChunkZ, cChunkDataSerializer & a_Serializer) { // Check chunks being sent, erase them from m_ChunksToSend: |