mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 23:38:25 +01:00
Fix double dropping xp now that Spigot fixed it
This commit is contained in:
parent
4b04144770
commit
24f4c7016a
1 changed files with 8 additions and 7 deletions
|
@ -5,15 +5,16 @@ Subject: [PATCH] PlayerDeathEvent#shouldDropExperience
|
|||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/EntityPlayer.java b/src/main/java/net/minecraft/server/EntityPlayer.java
|
||||
index f28de40a7..0888f268f 100644
|
||||
index f28de40a7..1ec29f157 100644
|
||||
--- a/src/main/java/net/minecraft/server/EntityPlayer.java
|
||||
+++ b/src/main/java/net/minecraft/server/EntityPlayer.java
|
||||
@@ -0,0 +0,0 @@ public class EntityPlayer extends EntityHuman implements ICrafting {
|
||||
}
|
||||
|
||||
this.setSpectatorTarget(this); // Remove spectated target
|
||||
+ if (event.shouldDropExperience()) this.dropExperience(); // Paper - drop experience
|
||||
// CraftBukkit end
|
||||
|
||||
// CraftBukkit - Get our scores instead
|
||||
this.releaseShoulderEntities();
|
||||
// SPIGOT-5478 must be called manually now
|
||||
- this.dropExperience();
|
||||
+ if (event.shouldDropExperience()) this.dropExperience(); // Paper - tie to event
|
||||
// we clean the player's inventory after the EntityDeathEvent is called so plugins can get the exact state of the inventory.
|
||||
if (!event.getKeepInventory()) {
|
||||
// Paper start - replace logic
|
||||
--
|
Loading…
Reference in a new issue