3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-11-15 20:40:07 +01:00
Paper/Spigot-Server-Patches/0400-only-add-passanger-entities-once-from-spawners.patch
Aikar e4d10a6d67
Updated Upstream (Bukkit/CraftBukkit)
Upstream has released updates that appears to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
122289ff Add FaceAttachable interface to handle Grindstone facing in common with Switches
a6db750e SPIGOT-5647: ZombieVillager entity should have getVillagerType()

CraftBukkit Changes:
bbe3d58e SPIGOT-5650: Lectern.setPage(int) causes a NullPointerException
3075579f Add FaceAttachable interface to handle Grindstone facing in common with Switches
95bd4238 SPIGOT-5647: ZombieVillager entity should have getVillagerType()
4d975ac3 SPIGOT-5617: setBlockData does not work when NotPlayEvent is called by redstone current
2020-04-02 17:09:17 -04:00

23 Zeilen
1014 B
Diff

From 15089fad66207986bd6e4c8d5c13e2703257c2f9 Mon Sep 17 00:00:00 2001
From: kickash32 <kickash32@gmail.com>
Date: Wed, 21 Aug 2019 23:57:32 +0500
Subject: [PATCH] only add passanger entities once from spawners
diff --git a/src/main/java/net/minecraft/server/MobSpawnerAbstract.java b/src/main/java/net/minecraft/server/MobSpawnerAbstract.java
index 41001b02a6..df494d37be 100644
--- a/src/main/java/net/minecraft/server/MobSpawnerAbstract.java
+++ b/src/main/java/net/minecraft/server/MobSpawnerAbstract.java
@@ -196,7 +196,7 @@ public abstract class MobSpawnerAbstract {
}
private void a(Entity entity) {
- if (this.a().addEntity(entity, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.SPAWNER)) { // CraftBukkit
+ if (entity.valid || this.a().addEntity(entity, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.SPAWNER)) { // CraftBukkit // Paper
Iterator iterator = entity.getPassengers().iterator();
while (iterator.hasNext()) {
--
2.25.1