Fix Player#chat for 1.19.3 (#8684)

This commit is contained in:
Jake Potrebic 2022-12-16 09:15:21 -08:00 committed by GitHub
parent 262c08f64f
commit 39d3a03bff
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
23 changed files with 64 additions and 63 deletions

View file

@ -21,7 +21,7 @@ character.
Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com> Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 06d221dcc4091032016c85143cf3432a988780c0..580f126ad3681306bfff24c1e19dab39a6d4e888 100644 index b85545f997447875e737e4d22a8a8dbcf1f8e2c8..4acffc3c509ca247a31a10099829a36a15d044a6 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -2040,7 +2040,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -2040,7 +2040,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
@ -74,7 +74,7 @@ index 06d221dcc4091032016c85143cf3432a988780c0..580f126ad3681306bfff24c1e19dab39
if ( org.spigotmc.SpigotConfig.logCommands ) // Spigot if ( org.spigotmc.SpigotConfig.logCommands ) // Spigot
this.LOGGER.info(this.player.getScoreboardName() + " issued server command: " + s); this.LOGGER.info(this.player.getScoreboardName() + " issued server command: " + s);
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 40c9b6ca9a5b23f11b5b51b6357141d01c20d50e..b000fef0907a4259b42c320ff831857810cc572d 100644 index ecc94c04ba83aff8f232467aef2def69065a1c1e..21479b83bbf8a3fd83d2c28626c70b7ee6e5da83 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -876,6 +876,28 @@ public final class CraftServer implements Server { @@ -876,6 +876,28 @@ public final class CraftServer implements Server {
@ -107,10 +107,10 @@ index 40c9b6ca9a5b23f11b5b51b6357141d01c20d50e..b000fef0907a4259b42c320ff8318578
return true; return true;
} }
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 30bbfb2bf6aeaf311453ccdd72eeee43ae89b972..e13af07709acdbe5060e2959f6762fcffa65fd05 100644 index 2bd04b15330e436dad2bc5006406bf791200d8fd..18ca87ebdc58f1ed2c1dd37e91f7ab3d85f3d014 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -504,7 +504,19 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -504,7 +504,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
public void chat(String msg) { public void chat(String msg) {
if (this.getHandle().connection == null) return; if (this.getHandle().connection == null) return;
@ -122,9 +122,10 @@ index 30bbfb2bf6aeaf311453ccdd72eeee43ae89b972..e13af07709acdbe5060e2959f6762fcf
+ if (msg.startsWith("/")) { + if (msg.startsWith("/")) {
+ this.getHandle().connection.handleCommand(msg); + this.getHandle().connection.handleCommand(msg);
+ } else { + } else {
+ // TODO text filtering + final PlayerChatMessage playerChatMessage = PlayerChatMessage.system(msg).withResult(new net.minecraft.network.chat.ChatDecorator.ModernResult(Component.literal(msg), true, false));
+ // TODO chat decorating + // TODO chat decorating
+ this.getHandle().connection.chat(msg, PlayerChatMessage.system(msg), false); + // TODO text filtering
+ this.getHandle().connection.chat(msg, playerChatMessage, false);
+ } + }
+ } + }
+ // Paper end + // Paper end

View file

@ -16,10 +16,10 @@ The wanted destination was on top of the emerald block however the player ended
This only is the case if the player is teleporting between worlds. This only is the case if the player is teleporting between worlds.
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index d7177eb9c3cf65cacc90752215d591058b8106b8..af4e9891da2584c791ce85f5eb6315a06fcc77e8 100644 index 3a2fe558d04959dce225b889c0e700134bd677b6..854983a0bc0be2920aa22add675fef0ed507f0a2 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -1131,7 +1131,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1132,7 +1132,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
if (fromWorld == toWorld) { if (fromWorld == toWorld) {
entity.connection.teleport(to); entity.connection.teleport(to);
} else { } else {

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Complete resource pack API
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 580f126ad3681306bfff24c1e19dab39a6d4e888..8f21a18d2ba6e9fc1c8d3076ca668c885a9ba19e 100644 index 4acffc3c509ca247a31a10099829a36a15d044a6..8bdf7adb60206a87216b503ead0758ca59a9b377 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -1764,8 +1764,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -1764,8 +1764,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
@ -23,7 +23,7 @@ index 580f126ad3681306bfff24c1e19dab39a6d4e888..8f21a18d2ba6e9fc1c8d3076ca668c88
@Override @Override
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index af4e9891da2584c791ce85f5eb6315a06fcc77e8..921c00c2a5e7d3487c35ee27714ae6bb6666f86f 100644 index 854983a0bc0be2920aa22add675fef0ed507f0a2..79ade05094db16acc07bec28b6b0fd8038fc7a10 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -152,6 +152,7 @@ import org.bukkit.plugin.Plugin; @@ -152,6 +152,7 @@ import org.bukkit.plugin.Plugin;
@ -45,7 +45,7 @@ index af4e9891da2584c791ce85f5eb6315a06fcc77e8..921c00c2a5e7d3487c35ee27714ae6bb
public CraftPlayer(CraftServer server, ServerPlayer entity) { public CraftPlayer(CraftServer server, ServerPlayer entity) {
super(server, entity); super(server, entity);
@@ -2208,6 +2213,45 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -2209,6 +2214,45 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
public boolean getAffectsSpawning() { public boolean getAffectsSpawning() {
return this.getHandle().affectsSpawning; return this.getHandle().affectsSpawning;
} }

View file

@ -44,10 +44,10 @@ index 29495ff2d2c31f6b6ef6e2817662d143e538f926..b2871726eb4dd7f16d161097cbf0f287
} }
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 921c00c2a5e7d3487c35ee27714ae6bb6666f86f..dcf6d675d9bb7befe022e722aba365d30c2ce705 100644 index 79ade05094db16acc07bec28b6b0fd8038fc7a10..2d6dc2dd74e8461bb379f64ebd40f2189844a8ec 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -2013,6 +2013,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -2014,6 +2014,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
} }
public void setRealHealth(double health) { public void setRealHealth(double health) {

View file

@ -14,10 +14,10 @@ public net.minecraft.world.entity.ExperienceOrb durabilityToXp(I)I
public net.minecraft.world.entity.ExperienceOrb xpToDurability(I)I public net.minecraft.world.entity.ExperienceOrb xpToDurability(I)I
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 70e5ef461f02e6aa8a73363753687d0cf5e7c4fb..865ba836d8a62fa08786e41f8434eb322885e965 100644 index 0cac7dea99a60bf393b8e41f0c05ec79d4b7c658..d2803455c9456523f8cc324e79c692595fa2420e 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -1446,7 +1446,37 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1447,7 +1447,37 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
} }
@Override @Override

View file

@ -27,7 +27,7 @@ index bb5c4ecd43aa344dfe9cca8ab7c2ebf9760e94cf..203786383387765d1f5a2d2ccce79d79
playerName = gameProfile.getName(); playerName = gameProfile.getName();
uniqueId = gameProfile.getId(); uniqueId = gameProfile.getId();
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index fb1e740b2a44c5f4b2d638303fc4f30b6aac08a2..5a43e1bd537ac4431b3a7f508ec0b3ca48c8150f 100644 index d2803455c9456523f8cc324e79c692595fa2420e..afa2e62732ba7b9c08fc24bc95b81b0f30d0ad05 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -81,6 +81,7 @@ import net.minecraft.world.entity.ai.attributes.Attributes; @@ -81,6 +81,7 @@ import net.minecraft.world.entity.ai.attributes.Attributes;
@ -50,7 +50,7 @@ index fb1e740b2a44c5f4b2d638303fc4f30b6aac08a2..5a43e1bd537ac4431b3a7f508ec0b3ca
@Override @Override
public InetSocketAddress getAddress() { public InetSocketAddress getAddress() {
if (this.getHandle().connection == null) return null; if (this.getHandle().connection == null) return null;
@@ -1579,8 +1575,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1580,8 +1576,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
this.hiddenEntities.put(entity.getUniqueId(), hidingPlugins); this.hiddenEntities.put(entity.getUniqueId(), hidingPlugins);
// Remove this entity from the hidden player's EntityTrackerEntry // Remove this entity from the hidden player's EntityTrackerEntry
@ -67,7 +67,7 @@ index fb1e740b2a44c5f4b2d638303fc4f30b6aac08a2..5a43e1bd537ac4431b3a7f508ec0b3ca
ChunkMap.TrackedEntity entry = tracker.entityMap.get(other.getId()); ChunkMap.TrackedEntity entry = tracker.entityMap.get(other.getId());
if (entry != null) { if (entry != null) {
entry.removePlayer(this.getHandle()); entry.removePlayer(this.getHandle());
@@ -1593,8 +1596,6 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1594,8 +1597,6 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
this.getHandle().connection.send(new ClientboundPlayerInfoRemovePacket(List.of(otherPlayer.getUUID()))); this.getHandle().connection.send(new ClientboundPlayerInfoRemovePacket(List.of(otherPlayer.getUUID())));
} }
} }
@ -76,7 +76,7 @@ index fb1e740b2a44c5f4b2d638303fc4f30b6aac08a2..5a43e1bd537ac4431b3a7f508ec0b3ca
} }
@Override @Override
@@ -1631,8 +1632,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1632,8 +1633,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
} }
this.hiddenEntities.remove(entity.getUniqueId()); this.hiddenEntities.remove(entity.getUniqueId());
@ -93,7 +93,7 @@ index fb1e740b2a44c5f4b2d638303fc4f30b6aac08a2..5a43e1bd537ac4431b3a7f508ec0b3ca
if (other instanceof ServerPlayer) { if (other instanceof ServerPlayer) {
ServerPlayer otherPlayer = (ServerPlayer) other; ServerPlayer otherPlayer = (ServerPlayer) other;
@@ -1643,9 +1651,51 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1644,9 +1652,51 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
if (entry != null && !entry.seenBy.contains(this.getHandle().connection)) { if (entry != null && !entry.seenBy.contains(this.getHandle().connection)) {
entry.updatePlayer(this.getHandle()); entry.updatePlayer(this.getHandle());
} }

View file

@ -9,7 +9,7 @@ e.g. servers which allow and support the usage of mod packs.
provide an optional flag to disable this check, at your own risk. provide an optional flag to disable this check, at your own risk.
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 32170da591ac2430ac08e327d759e3d7ea70f2df..ef923eb5aedfe93cc8746a89b63bdee5f4aaac72 100644 index afa2e62732ba7b9c08fc24bc95b81b0f30d0ad05..bc8738811465d61e41580c5718d85c34e11b609b 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -175,6 +175,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -175,6 +175,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@ -20,7 +20,7 @@ index 32170da591ac2430ac08e327d759e3d7ea70f2df..ef923eb5aedfe93cc8746a89b63bdee5
// Paper end // Paper end
public CraftPlayer(CraftServer server, ServerPlayer entity) { public CraftPlayer(CraftServer server, ServerPlayer entity) {
@@ -1895,7 +1896,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1896,7 +1897,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
// Paper end // Paper end
public void addChannel(String channel) { public void addChannel(String channel) {

View file

@ -173,10 +173,10 @@ index 7ea4a2d4e691e0a0a4d9ef3189a29a4a4ca4374b..883b6245f44f3fb82d7678e1092177ca
@Override @Override
public boolean isBlocking() { public boolean isBlocking() {
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index b09643ee16b049d9fab2ea36ca76837cac580149..ff910a539a119a45e06fc2934f034a83395f9843 100644 index bc8738811465d61e41580c5718d85c34e11b609b..5057a65e1f9b4f5646db83b4311636c963c39515 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -1160,7 +1160,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1161,7 +1161,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
// Close any foreign inventory // Close any foreign inventory
if (this.getHandle().containerMenu != this.getHandle().inventoryMenu) { if (this.getHandle().containerMenu != this.getHandle().inventoryMenu) {

View file

@ -5,10 +5,10 @@ Subject: [PATCH] Expose attack cooldown methods for Player
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 00cabbfb53b4b1b427a9483332a5ffdb8172fd6b..6a8494e8b49094a3235b25415a02014ff6c71b33 100644 index 5057a65e1f9b4f5646db83b4311636c963c39515..7465d8de698d9eed71c96019fc55d6efdd13269c 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -2648,6 +2648,21 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -2649,6 +2649,21 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
return this.adventure$pointers; return this.adventure$pointers;
} }

View file

@ -74,7 +74,7 @@ index cd392d316f35ac488c49ad8c34c0273bbccc6a1c..db02d7938c79995b8acc4184c1be2fe3
} }
} }
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index d825dd9a990f52e378755e86c02c6a35f3bb3659..785d5196c7e6de95e0507c959352ba57fb50d1c4 100644 index dc78b04128c5eb2375a049948133aa05fff2c022..d9b2f2e230abd3ee5b7d77c76472a86cb38255a4 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -263,6 +263,7 @@ public abstract class LivingEntity extends Entity { @@ -263,6 +263,7 @@ public abstract class LivingEntity extends Entity {
@ -314,10 +314,10 @@ index f70f75867a8f03d42f240a0d007d2221269f2fdb..e463ae13ce6f65675c2b6d553ecf91db
this.gameEvent(GameEvent.ENTITY_DIE); this.gameEvent(GameEvent.ENTITY_DIE);
} }
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 1b5d713ea7f184b90ad050d758cbdfc5ca76a5b5..9ba067e28a6c533b5e611a31dd6d4b3e83656b93 100644 index 7465d8de698d9eed71c96019fc55d6efdd13269c..03f9d58fa5158b50e12edd6a91ff263e08555870 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -2155,7 +2155,14 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -2156,7 +2156,14 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
} }
public void sendHealthUpdate() { public void sendHealthUpdate() {

View file

@ -16,7 +16,7 @@ intent to remove) and replace it with two new methods, clearly named and
documented as to their purpose. documented as to their purpose.
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
index c7fe091d13349348b7288c0aa8bdde046dc47fa4..8aac8dd53b171f05559fb233d47bf1c9e5815a03 100644 index 5be2158d720014fb2088351edeb692acb5d933ab..1cce4fabcf635d4d7600fc1b931f3789f5417bf3 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -235,6 +235,7 @@ public class ServerPlayer extends Player { @@ -235,6 +235,7 @@ public class ServerPlayer extends Player {
@ -106,7 +106,7 @@ index e7442952ef1f03969949014492a7ddc6d0796ba5..d7823d7dc88cfba6f6ac9dae220e03de
public Location getLastDeathLocation() { public Location getLastDeathLocation() {
if (this.getData().contains("LastDeathLocation", 10)) { if (this.getData().contains("LastDeathLocation", 10)) {
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 15da4358e46547fa979dd5023ec6eb5d1358bcb5..7e4cdc2ff30bd85e2ddd271f7b0a531100fdce36 100644 index 03f9d58fa5158b50e12edd6a91ff263e08555870..e693b7c94bd0c35260969266a7fa9c606d91f5b4 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -176,6 +176,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -176,6 +176,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@ -117,7 +117,7 @@ index 15da4358e46547fa979dd5023ec6eb5d1358bcb5..7e4cdc2ff30bd85e2ddd271f7b0a5311
// Paper end // Paper end
public CraftPlayer(CraftServer server, ServerPlayer entity) { public CraftPlayer(CraftServer server, ServerPlayer entity) {
@@ -1767,6 +1768,18 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1768,6 +1769,18 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
this.firstPlayed = firstPlayed; this.firstPlayed = firstPlayed;
} }
@ -136,7 +136,7 @@ index 15da4358e46547fa979dd5023ec6eb5d1358bcb5..7e4cdc2ff30bd85e2ddd271f7b0a5311
public void readExtraData(CompoundTag nbttagcompound) { public void readExtraData(CompoundTag nbttagcompound) {
this.hasPlayedBefore = true; this.hasPlayedBefore = true;
if (nbttagcompound.contains("bukkit")) { if (nbttagcompound.contains("bukkit")) {
@@ -1789,6 +1802,8 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1790,6 +1803,8 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
} }
public void setExtraData(CompoundTag nbttagcompound) { public void setExtraData(CompoundTag nbttagcompound) {
@ -145,7 +145,7 @@ index 15da4358e46547fa979dd5023ec6eb5d1358bcb5..7e4cdc2ff30bd85e2ddd271f7b0a5311
if (!nbttagcompound.contains("bukkit")) { if (!nbttagcompound.contains("bukkit")) {
nbttagcompound.put("bukkit", new CompoundTag()); nbttagcompound.put("bukkit", new CompoundTag());
} }
@@ -1803,6 +1818,16 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1804,6 +1819,16 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
data.putLong("firstPlayed", this.getFirstPlayed()); data.putLong("firstPlayed", this.getFirstPlayed());
data.putLong("lastPlayed", System.currentTimeMillis()); data.putLong("lastPlayed", System.currentTimeMillis());
data.putString("lastKnownName", handle.getScoreboardName()); data.putString("lastKnownName", handle.getScoreboardName());

View file

@ -12,10 +12,10 @@ Player we will look at limiting the scope of this change. It appears to
be unintentional in the few cases we've seen so far. be unintentional in the few cases we've seen so far.
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index fc468d79fb18fdc5e06aedb51868ac94c1979c11..4fe360a8ac16a30f696b6e09e5e056dfa18256d7 100644 index e693b7c94bd0c35260969266a7fa9c606d91f5b4..b238b8ae5fd53c109ee3437a8a9b6a018a62da39 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -2695,6 +2695,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -2696,6 +2696,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
public void resetCooldown() { public void resetCooldown() {
getHandle().resetAttackStrengthTicker(); getHandle().resetAttackStrengthTicker();
} }

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Brand support
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 508a6e062de1994f26393d33e8b41ea245e0c3d0..40423a24eac6675c8b9ddb843c910e324709ebe4 100644 index c88e6ca7ee28ebaf235e11bbe70b13c90508924e..39fe98d65f3029efa2f54c2b6dbf1e53c1957b6e 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -298,6 +298,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -298,6 +298,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
@ -56,10 +56,10 @@ index 508a6e062de1994f26393d33e8b41ea245e0c3d0..40423a24eac6675c8b9ddb843c910e32
return (!this.player.joining && !this.connection.isConnected()) || this.processedDisconnect; // Paper return (!this.player.joining && !this.connection.isConnected()) || this.processedDisconnect; // Paper
} }
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 89411cc4a774e85d79aec44cb4136679e9513329..ca12956fe9eb0ade9f78980210ec7421266ba554 100644 index c7629ce42389d7ae15516f94cbca636181e62c88..08d1dc46190a6cfea869ca247e675e5996969a0b 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -2823,6 +2823,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -2824,6 +2824,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
// Paper end // Paper end
}; };

View file

@ -5,10 +5,10 @@ Subject: [PATCH] Fix Player spawnParticle x/y/z precision loss
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 025886ef9fc2d992cffb94b172a44ec123432e60..6a342a897893355160d9f064236d775452e9b752 100644 index 2cbce5cd4656f3dd38c0d35e43f17a29451f7248..a101756ee42c920aa8b13f263dc4a63ad5b08701 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -2348,7 +2348,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -2349,7 +2349,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
if (data != null && !particle.getDataType().isInstance(data)) { if (data != null && !particle.getDataType().isInstance(data)) {
throw new IllegalArgumentException("data should be " + particle.getDataType() + " got " + data.getClass()); throw new IllegalArgumentException("data should be " + particle.getDataType() + " got " + data.getClass());
} }

View file

@ -142,10 +142,10 @@ index 4e71a80a6cc163d72001804de6ed3ba8167101b4..d056dbdf89284b120e28002bcca463c6
} }
} }
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 0c25992fe12be2c1259b706ccdf9af37da149908..3ae87757f4a3bf865514055d1d6fcb6fff38354d 100644 index 8ea298852fd39cfb0110250cb4330fd88b2ef451..f1fd1cc8ec08f81e2e58052154ede76c3a7c134f 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -1471,7 +1471,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1472,7 +1472,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
throw new IllegalArgumentException("Mode cannot be null"); throw new IllegalArgumentException("Mode cannot be null");
} }

View file

@ -129,10 +129,10 @@ index 37e111589134d80fdfd7a04d624b8c1d58a2d664..53b35f003034e7f4c9dd8ccfaf773891
} }
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index a5516f18c4bf4cfe745551d889053d7c49e81210..1dafacba3c5102ce4035f74ae7e103957a3085a7 100644 index 5e980ea6e076698eb52ce9e3b08e420e368fe825..67ed1ef8f19d208a407add3f4808dd0e0ff69e0d 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -1291,9 +1291,9 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1292,9 +1292,9 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@Override @Override
public void setBedSpawnLocation(Location location, boolean override) { public void setBedSpawnLocation(Location location, boolean override) {
if (location == null) { if (location == null) {

View file

@ -5,10 +5,10 @@ Subject: [PATCH] Add player health update API
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 1dafacba3c5102ce4035f74ae7e103957a3085a7..fdd9ade27e01608dcf35ee5c9c7c7d1e8428eccf 100644 index 67ed1ef8f19d208a407add3f4808dd0e0ff69e0d..c8ae6651cc66aea77a5ab5236e4d4a33b5b60b2f 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -2227,9 +2227,11 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -2228,9 +2228,11 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
this.getHandle().maxHealthCache = getMaxHealth(); this.getHandle().maxHealthCache = getMaxHealth();
} }
@ -22,7 +22,7 @@ index 1dafacba3c5102ce4035f74ae7e103957a3085a7..fdd9ade27e01608dcf35ee5c9c7c7d1e
if (this.getHandle().queueHealthUpdatePacket) { if (this.getHandle().queueHealthUpdatePacket) {
this.getHandle().queuedHealthUpdatePacket = packet; this.getHandle().queuedHealthUpdatePacket = packet;
} else { } else {
@@ -2237,7 +2239,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -2238,7 +2240,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
} }
// Paper end // Paper end
} }

View file

@ -25,10 +25,10 @@ index 0d851e197e65ec79386ad1f981f6d1d38b65124a..24c677e80af652952263253409c05064
public void write(FriendlyByteBuf buf) { public void write(FriendlyByteBuf buf) {
buf.writeLong(this.sectionPos.asLong()); buf.writeLong(this.sectionPos.asLong());
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index fdd9ade27e01608dcf35ee5c9c7c7d1e8428eccf..0cda054d342972ef6ffa993786a7baa1c1e1f460 100644 index c8ae6651cc66aea77a5ab5236e4d4a33b5b60b2f..737f9530fc88d84b8833c1701dd22b88c49f5e25 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -929,6 +929,35 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -930,6 +930,35 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
this.getHandle().connection.send(packet); this.getHandle().connection.send(packet);
} }

View file

@ -71,10 +71,10 @@ index 32b9816283c8c1de929d5664733553277cf6bf3c..32c724060a532e551f0ab4e7277831bb
// Let the server handle cross world teleports // Let the server handle cross world teleports
if (location.getWorld() != null && !location.getWorld().equals(this.getWorld())) { if (location.getWorld() != null && !location.getWorld().equals(this.getWorld())) {
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 0cda054d342972ef6ffa993786a7baa1c1e1f460..4d3d6ecada4d8d7202498f4b3c68c35546d3f1df 100644 index 737f9530fc88d84b8833c1701dd22b88c49f5e25..f1a77e2f6172f419eb14c01d894e5851f568d68d 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -1184,13 +1184,92 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1185,13 +1185,92 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@Override @Override
public void setRotation(float yaw, float pitch) { public void setRotation(float yaw, float pitch) {
@ -168,7 +168,7 @@ index 0cda054d342972ef6ffa993786a7baa1c1e1f460..4d3d6ecada4d8d7202498f4b3c68c355
location.checkFinite(); location.checkFinite();
ServerPlayer entity = this.getHandle(); ServerPlayer entity = this.getHandle();
@@ -1203,7 +1282,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1204,7 +1283,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
return false; return false;
} }
@ -177,7 +177,7 @@ index 0cda054d342972ef6ffa993786a7baa1c1e1f460..4d3d6ecada4d8d7202498f4b3c68c355
return false; return false;
} }
@@ -1221,7 +1300,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1222,7 +1301,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
} }
// If this player is riding another entity, we must dismount before teleporting. // If this player is riding another entity, we must dismount before teleporting.
@ -186,7 +186,7 @@ index 0cda054d342972ef6ffa993786a7baa1c1e1f460..4d3d6ecada4d8d7202498f4b3c68c355
// SPIGOT-5509: Wakeup, similar to riding // SPIGOT-5509: Wakeup, similar to riding
if (this.isSleeping()) { if (this.isSleeping()) {
@@ -1243,7 +1322,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1244,7 +1323,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
// Check if the fromWorld and toWorld are the same. // Check if the fromWorld and toWorld are the same.
if (fromWorld == toWorld) { if (fromWorld == toWorld) {

View file

@ -5,10 +5,10 @@ Subject: [PATCH] Add custom destroyerIdentity to sendBlockDamage
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 81d986eeb355087dc1ff45c2c44b9d34b04f02f1..275101311ea56e5947377dad1ba17f1c4b449285 100644 index 3200bd56923af252e3e6cfb2c88bc4563230cd05..f872f0e955b11cc50c239f98e02dfac47908d8c7 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -1014,13 +1014,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -1015,13 +1015,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@Override @Override
public void sendBlockDamage(Location loc, float progress) { public void sendBlockDamage(Location loc, float progress) {

View file

@ -5,10 +5,10 @@ Subject: [PATCH] Elder Guardian appearance API
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 275101311ea56e5947377dad1ba17f1c4b449285..fa6a627f61bf7d47ee426231f2beea07a5ff9be1 100644 index f872f0e955b11cc50c239f98e02dfac47908d8c7..968892831bcbfd40a0630018f9a5dd2ff2761836 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -2995,6 +2995,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -2996,6 +2996,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
} }
// Paper end // Paper end

View file

@ -10,10 +10,10 @@ public net.minecraft.world.entity.monster.warden.WardenSpawnTracker cooldownTick
public net.minecraft.world.entity.monster.warden.WardenSpawnTracker increaseWarningLevel()V public net.minecraft.world.entity.monster.warden.WardenSpawnTracker increaseWarningLevel()V
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index fa6a627f61bf7d47ee426231f2beea07a5ff9be1..c628cbff6302e4b559964824fa61a1566b83cd9f 100644 index 968892831bcbfd40a0630018f9a5dd2ff2761836..f8ba66e6711dfd83e28fff02ea8ca351fc29a25a 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -3000,6 +3000,41 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -3001,6 +3001,41 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
public void showElderGuardian(boolean silent) { public void showElderGuardian(boolean silent) {
if (getHandle().connection != null) getHandle().connection.send(new ClientboundGameEventPacket(ClientboundGameEventPacket.GUARDIAN_ELDER_EFFECT, silent ? 0F : 1F)); if (getHandle().connection != null) getHandle().connection.send(new ClientboundGameEventPacket(ClientboundGameEventPacket.GUARDIAN_ELDER_EFFECT, silent ? 0F : 1F));
} }

View file

@ -6,10 +6,10 @@ Subject: [PATCH] fix Instruments
properly handle Player#playNote properly handle Player#playNote
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index c628cbff6302e4b559964824fa61a1566b83cd9f..52071101c16ae84f69f1a00857b4895f328f6edd 100644 index f8ba66e6711dfd83e28fff02ea8ca351fc29a25a..5b18b560d94a1f36bcb0b962a93ba81236f767ac 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -766,62 +766,18 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -767,62 +767,18 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
public void playNote(Location loc, Instrument instrument, Note note) { public void playNote(Location loc, Instrument instrument, Note note) {
if (this.getHandle().connection == null) return; if (this.getHandle().connection == null) return;