From a48b906896b6d425346c0ff37195fe0a886dd421 Mon Sep 17 00:00:00 2001 From: Zach Brown <1254957+zachbr@users.noreply.github.com> Date: Sat, 30 Jul 2016 17:04:39 -0500 Subject: [PATCH] Send a fake team as needed for the collision rule --- .../Configurable-Player-Collision.patch | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/Spigot-Server-Patches/Configurable-Player-Collision.patch b/Spigot-Server-Patches/Configurable-Player-Collision.patch index aca9f1f80..4c5905a93 100644 --- a/Spigot-Server-Patches/Configurable-Player-Collision.patch +++ b/Spigot-Server-Patches/Configurable-Player-Collision.patch @@ -31,4 +31,22 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 packetdataserializer.writeByte(this.g); } +diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java +index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 +--- a/src/main/java/net/minecraft/server/PlayerList.java ++++ b/src/main/java/net/minecraft/server/PlayerList.java +@@ -0,0 +0,0 @@ public abstract class PlayerList { + public void sendScoreboard(ScoreboardServer scoreboardserver, EntityPlayer entityplayer) { + HashSet hashset = Sets.newHashSet(); + Iterator iterator = scoreboardserver.getTeams().iterator(); ++ ++ // Paper start - Send a fake team to the client to initialize collision rule if no others exist ++ if (!com.destroystokyo.paper.PaperConfig.enablePlayerCollisions && !iterator.hasNext()) { ++ entityplayer.playerConnection.sendPacket(new PacketPlayOutScoreboardTeam(new ScoreboardTeam(scoreboardserver, "collideRule"), 0)); ++ return; ++ } ++ // Paper end + + while (iterator.hasNext()) { + ScoreboardTeam scoreboardteam = (ScoreboardTeam) iterator.next(); -- \ No newline at end of file