Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-11-15 20:40:07 +01:00
19de9af63c
Functional GUI fix added by billygalbreath
33 Zeilen
1.3 KiB
Diff
33 Zeilen
1.3 KiB
Diff
From fe9d2d7e016e997976674ae65da333ca710c2809 Mon Sep 17 00:00:00 2001
|
|
From: BillyGalbreath <Blake.Galbreath@GMail.com>
|
|
Date: Mon, 31 Jul 2017 01:45:19 -0500
|
|
Subject: [PATCH] Reset spawner timer when spawner event is cancelled
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/MobSpawnerAbstract.java b/src/main/java/net/minecraft/server/MobSpawnerAbstract.java
|
|
index 8384a2cbf..258e96ba5 100644
|
|
--- a/src/main/java/net/minecraft/server/MobSpawnerAbstract.java
|
|
+++ b/src/main/java/net/minecraft/server/MobSpawnerAbstract.java
|
|
@@ -140,6 +140,9 @@ public abstract class MobSpawnerAbstract {
|
|
{
|
|
entity.fromMobSpawner = true;
|
|
}
|
|
+
|
|
+ flag = true; // Paper
|
|
+
|
|
if (org.bukkit.craftbukkit.event.CraftEventFactory.callSpawnerSpawnEvent(entity, blockposition).isCancelled()) {
|
|
Entity vehicle = entity.getVehicle();
|
|
if (vehicle != null) {
|
|
@@ -157,7 +160,7 @@ public abstract class MobSpawnerAbstract {
|
|
((EntityInsentient) entity).doSpawnEffect();
|
|
}
|
|
|
|
- flag = true;
|
|
+ /*flag = true;*/ // Paper - moved up above cancellable event
|
|
}
|
|
}
|
|
|
|
--
|
|
2.25.0.windows.1
|
|
|