summaryrefslogtreecommitdiffstats
path: root/src/Broadcaster.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/Broadcaster.cpp25
1 files changed, 19 insertions, 6 deletions
diff --git a/src/Broadcaster.cpp b/src/Broadcaster.cpp
index 98759a58b..c8d2de615 100644
--- a/src/Broadcaster.cpp
+++ b/src/Broadcaster.cpp
@@ -171,6 +171,19 @@ void cWorld::BroadcastBlockEntity(Vector3i a_BlockPos, const cClientHandle * a_E
+void cWorld::BroadcastBossBarUpdateHealth(const cEntity & a_Entity, UInt32 a_UniqueID, float a_FractionFilled)
+{
+ ForClientsWithEntity(a_Entity, *this, nullptr, [&](cClientHandle & a_Client)
+ {
+ a_Client.SendBossBarUpdateHealth(a_UniqueID, a_FractionFilled);
+ }
+ );
+}
+
+
+
+
+
void cWorld::BroadcastChat(const AString & a_Message, const cClientHandle * a_Exclude, eMessageType a_ChatPrefix)
{
ForClientsInWorld(*this, a_Exclude, [&](cClientHandle & a_Client)
@@ -444,11 +457,11 @@ void cWorld::BroadcastPlayerListRemovePlayer(const cPlayer & a_Player, const cCl
-void cWorld::BroadcastPlayerListUpdateGameMode(const cPlayer & a_Player, const cClientHandle * a_Exclude)
+void cWorld::BroadcastPlayerListUpdateDisplayName(const cPlayer & a_Player, const AString & a_CustomName, const cClientHandle * a_Exclude)
{
ForClientsInWorld(*this, a_Exclude, [&](cClientHandle & a_Client)
{
- a_Client.SendPlayerListUpdateGameMode(a_Player);
+ a_Client.SendPlayerListUpdateDisplayName(a_Player, a_CustomName);
}
);
}
@@ -457,11 +470,11 @@ void cWorld::BroadcastPlayerListUpdateGameMode(const cPlayer & a_Player, const c
-void cWorld::BroadcastPlayerListUpdatePing(const cPlayer & a_Player, const cClientHandle * a_Exclude)
+void cWorld::BroadcastPlayerListUpdateGameMode(const cPlayer & a_Player, const cClientHandle * a_Exclude)
{
ForClientsInWorld(*this, a_Exclude, [&](cClientHandle & a_Client)
{
- a_Client.SendPlayerListUpdatePing(a_Player);
+ a_Client.SendPlayerListUpdateGameMode(a_Player);
}
);
}
@@ -470,11 +483,11 @@ void cWorld::BroadcastPlayerListUpdatePing(const cPlayer & a_Player, const cClie
-void cWorld::BroadcastPlayerListUpdateDisplayName(const cPlayer & a_Player, const AString & a_CustomName, const cClientHandle * a_Exclude)
+void cWorld::BroadcastPlayerListUpdatePing(const cPlayer & a_Player, const cClientHandle * a_Exclude)
{
ForClientsInWorld(*this, a_Exclude, [&](cClientHandle & a_Client)
{
- a_Client.SendPlayerListUpdateDisplayName(a_Player, a_CustomName);
+ a_Client.SendPlayerListUpdatePing(a_Player);
}
);
}