diff options
author | Howaner <franzi.moos@googlemail.com> | 2014-09-18 18:50:17 +0200 |
---|---|---|
committer | Howaner <franzi.moos@googlemail.com> | 2014-09-18 18:50:17 +0200 |
commit | 43ed690520d3c3b47ed7ff6f48f868e8011565e0 (patch) | |
tree | 7db2b1b7dde37f498e6ed09e90a68ae3faff0718 /src/ClientHandle.cpp | |
parent | 1.8: Simplified item metadata reading. (diff) | |
download | cuberite-43ed690520d3c3b47ed7ff6f48f868e8011565e0.tar cuberite-43ed690520d3c3b47ed7ff6f48f868e8011565e0.tar.gz cuberite-43ed690520d3c3b47ed7ff6f48f868e8011565e0.tar.bz2 cuberite-43ed690520d3c3b47ed7ff6f48f868e8011565e0.tar.lz cuberite-43ed690520d3c3b47ed7ff6f48f868e8011565e0.tar.xz cuberite-43ed690520d3c3b47ed7ff6f48f868e8011565e0.tar.zst cuberite-43ed690520d3c3b47ed7ff6f48f868e8011565e0.zip |
Diffstat (limited to '')
-rw-r--r-- | src/ClientHandle.cpp | 48 |
1 files changed, 42 insertions, 6 deletions
diff --git a/src/ClientHandle.cpp b/src/ClientHandle.cpp index df6847767..487ef3867 100644 --- a/src/ClientHandle.cpp +++ b/src/ClientHandle.cpp @@ -127,7 +127,7 @@ cClientHandle::~cClientHandle() if (!m_Username.empty() && (World != NULL)) { // Send the Offline PlayerList packet: - World->BroadcastPlayerListItem(*m_Player, 4, this); + World->BroadcastPlayerListRemovePlayer(*m_Player, this); } if (World != NULL) { @@ -364,10 +364,10 @@ void cClientHandle::Authenticate(const AString & a_Name, const AString & a_UUID, m_Player->SendExperience(); // Send player list items - SendPlayerListItem(*m_Player, 0); - World->BroadcastPlayerListItem(*m_Player, 0); + SendPlayerListAddPlayer(*m_Player); + World->BroadcastPlayerListAddPlayer(*m_Player); World->SendPlayerList(m_Player); - + m_Player->Initialize(*World); m_State = csAuthenticated; @@ -2408,9 +2408,45 @@ void cClientHandle::SendPlayerAbilities() -void cClientHandle::SendPlayerListItem(const cPlayer & a_Player, char a_Action) +void cClientHandle::SendPlayerListAddPlayer(const cPlayer & a_Player) +{ + m_Protocol->SendPlayerListAddPlayer(a_Player); +} + + + + + +void cClientHandle::SendPlayerListRemovePlayer(const cPlayer & a_Player) +{ + m_Protocol->SendPlayerListRemovePlayer(a_Player); +} + + + + + +void cClientHandle::SendPlayerListUpdateGameMode(const cPlayer & a_Player) +{ + m_Protocol->SendPlayerListUpdateGameMode(a_Player); +} + + + + + +void cClientHandle::SendPlayerListUpdatePing(const cPlayer & a_Player) +{ + m_Protocol->SendPlayerListUpdatePing(a_Player); +} + + + + + +void cClientHandle::SendPlayerListUpdateDisplayName(const cPlayer & a_Player, const AString & a_OldListName) { - m_Protocol->SendPlayerListItem(a_Player, a_Action); + m_Protocol->SendPlayerListUpdateDisplayName(a_Player, a_OldListName); } |