diff --git a/patches/api/Clarify-the-Javadocs-for-Entity.getEntitySpawnReason.patch b/patches/api/Clarify-the-Javadocs-for-Entity.getEntitySpawnReason.patch deleted file mode 100644 index 1a8bebb465..0000000000 --- a/patches/api/Clarify-the-Javadocs-for-Entity.getEntitySpawnReason.patch +++ /dev/null @@ -1,19 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: Aurora -Date: Sat, 3 Oct 2020 16:28:41 +0200 -Subject: [PATCH] Clarify the Javadocs for Entity.getEntitySpawnReason() - - -diff --git a/src/main/java/org/bukkit/entity/Entity.java b/src/main/java/org/bukkit/entity/Entity.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/org/bukkit/entity/Entity.java -+++ b/src/main/java/org/bukkit/entity/Entity.java -@@ -0,0 +0,0 @@ public interface Entity extends Metadatable, CommandSender, Nameable, Persistent - } - - /** -- * @return The {@link org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason} that spawned this entity. -+ * @return The {@link org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason} that initially spawned this entity. - */ - @NotNull - org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason getEntitySpawnReason(); diff --git a/patches/api/Entity-getEntitySpawnReason.patch b/patches/api/Entity-getEntitySpawnReason.patch index 01af933d1f..cdb6d8cd80 100644 --- a/patches/api/Entity-getEntitySpawnReason.patch +++ b/patches/api/Entity-getEntitySpawnReason.patch @@ -9,6 +9,8 @@ Pre existing entities will return NATURAL if it was a non persistenting Living Entity, SPAWNER for spawners, or DEFAULT since data was not stored. +Co-authored-by: Aurora + diff --git a/src/main/java/org/bukkit/entity/Entity.java b/src/main/java/org/bukkit/entity/Entity.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/org/bukkit/entity/Entity.java @@ -19,7 +21,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 } + + /** -+ * @return The {@link org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason} that spawned this entity. ++ * @return The {@link org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason} that initially spawned this entity. + */ + @NotNull + org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason getEntitySpawnReason(); diff --git a/patches/server/Fix-a-bunch-of-vanilla-bugs.patch b/patches/server/Fix-a-bunch-of-vanilla-bugs.patch index ff66994bf7..2624ffab1c 100644 --- a/patches/server/Fix-a-bunch-of-vanilla-bugs.patch +++ b/patches/server/Fix-a-bunch-of-vanilla-bugs.patch @@ -29,26 +29,13 @@ https://bugs.mojang.com/browse/MC-191591 https://bugs.mojang.com/browse/MC-258360 Fix items equipped on AbstractHorse losing NBT -https://bugs.mojang.com/browse/MC-121048 - by: MelnCat - This moves the setHealth call to below the recordDamage call to prevent - recordDamage from clearing the CombatTracker, since recordDamage will - clear the CombatTracker if the entity is dead. This fixes death messages - such as the "doomed to fall" messages. - -https://bugs.mojang.com/browse/MC-257875 - by: Jake Potrebic - Fixes server not consuming fire charges when igniting a creeper - -https://bugs.mojang.com/browse/MC-258535 - by: Jake Potrebic - Fixes certain explosion damage not scaling with difficulty - https://bugs.mojang.com/browse/MC-259571 Fix changeGameModeForPlayer to use gameModeForPlayer +https://bugs.mojang.com/browse/MC-260219 + Play sniffer eat sound for the last item + Co-authored-by: William Blake Galbreath -Co-authored-by: MelnCat diff --git a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 @@ -180,6 +167,22 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 if (!player.getAbilities().instabuild) { stack.shrink(1); } +diff --git a/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java b/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java +index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 +--- a/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java ++++ b/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java +@@ -0,0 +0,0 @@ public class Sniffer extends Animal { + @Override + public InteractionResult mobInteract(Player player, InteractionHand hand) { + ItemStack itemstack = player.getItemInHand(hand); ++ boolean wasFood = this.isFood(itemstack); // Paper - Fix MC-260219 + InteractionResult enuminteractionresult = super.mobInteract(player, hand); + +- if (enuminteractionresult.consumesAction() && this.isFood(itemstack)) { ++ if (enuminteractionresult.consumesAction() && wasFood) { // Paper - Fix MC-260219 + this.level.playSound((Player) null, (Entity) this, this.getEatingSound(itemstack), SoundSource.NEUTRAL, 1.0F, Mth.randomBetween(this.level.random, 0.8F, 1.2F)); + } + diff --git a/src/main/java/net/minecraft/world/entity/npc/CatSpawner.java b/src/main/java/net/minecraft/world/entity/npc/CatSpawner.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/net/minecraft/world/entity/npc/CatSpawner.java