Fix bucket fish having CreatureSpawnEvent.SpawnReason.DEFAULT
Align with SPAWNER_EGG reason in previous versions
This commit is contained in:
parent
43f66f6cb7
commit
8f3da35f71
22
nms-patches/net/minecraft/world/item/MobBucketItem.patch
Normal file
22
nms-patches/net/minecraft/world/item/MobBucketItem.patch
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
--- a/net/minecraft/world/item/MobBucketItem.java
|
||||||
|
+++ b/net/minecraft/world/item/MobBucketItem.java
|
||||||
|
@@ -26,6 +26,10 @@
|
||||||
|
import net.minecraft.world.level.gameevent.GameEvent;
|
||||||
|
import net.minecraft.world.level.material.FluidType;
|
||||||
|
|
||||||
|
+// CraftBukkit start
|
||||||
|
+import org.bukkit.event.entity.CreatureSpawnEvent;
|
||||||
|
+// CraftBukkit end
|
||||||
|
+
|
||||||
|
public class MobBucketItem extends ItemBucket {
|
||||||
|
|
||||||
|
private static final MapCodec<EntityTropicalFish.d> VARIANT_FIELD_CODEC = EntityTropicalFish.d.CODEC.fieldOf("BucketVariantTag");
|
||||||
|
@@ -63,7 +67,7 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
if (entityinsentient != null) {
|
||||||
|
- worldserver.addFreshEntityWithPassengers(entityinsentient);
|
||||||
|
+ worldserver.addFreshEntityWithPassengers(entityinsentient, CreatureSpawnEvent.SpawnReason.SPAWNER_EGG); // CraftBukkit
|
||||||
|
entityinsentient.playAmbientSound();
|
||||||
|
}
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user