mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-25 00:30:25 +01:00
f956f185c8
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: 47b9cf30 SPIGOT-4372: LightningStrikeEvent cause API a9ceda75 Include the plugin channel name in the exception message CraftBukkit Changes:a4bdecff
SPIGOT-4372: LightningStrikeEvent cause API34caaf6d
SPIGOT-4371: Trident damaged when event cancelled97315374
SPIGOT-4369: Handle cancelled trident eventbf1c8273
SPIGOT-4370: Remove vehicle if its passenger spawn event was cancelled Spigot Changes: 6b015b4b SPIGOT-4370: Remove vehicle if its passenger spawn event was cancelled
32 lines
1.3 KiB
Diff
32 lines
1.3 KiB
Diff
From 149f17e8532b98f9cb33ac5061035509aa3ae066 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 72b12d869e..408ef423e9 100644
|
|
--- a/src/main/java/net/minecraft/server/MobSpawnerAbstract.java
|
|
+++ b/src/main/java/net/minecraft/server/MobSpawnerAbstract.java
|
|
@@ -121,6 +121,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) {
|
|
@@ -138,7 +141,7 @@ public abstract class MobSpawnerAbstract {
|
|
entityinsentient.doSpawnEffect();
|
|
}
|
|
|
|
- flag = true;
|
|
+ /*flag = true;*/ // Paper - moved up above cancellable event
|
|
}
|
|
}
|
|
|
|
--
|
|
2.19.0
|
|
|