mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-05 10:20:53 +01:00
73983e4c16
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: 3dc4cdcd Update to Minecraft 1.14.3-pre4 88b25a8c SPIGOT-5098: Add a method to allow colored sign changes 6d913552 Update to Minecraft 1.14.3-pre4 CraftBukkit Changes:f1f33559
Update to Minecraft 1.14.38a3d3f49
SPIGOT-5098: Add a method to allow colored sign changes533290e2
SPIGOT-5100: Console warning from pig zombie targeting6dde4b9f
SPIGOT-5094: Allow opening merchant for wandering traders and hide the xp bar for custom merchants9af90077
SPIGOT-5097: Bukkit.clearRecipes() no longer working38fa220f
Fix setting game rules via the APIfe3930ce
Update to Minecraft 1.14.3-pre4da071ec5
Remove outdated build delay. Spigot Changes: 4d2f30f1 Update to Minecraft 1.14.3 f16400e3 Update to Minecraft 1.14.3-pre4
33 lines
1.6 KiB
Diff
33 lines
1.6 KiB
Diff
From 35ab8703b02887be4c030eebb0da0c83e50c4bdc Mon Sep 17 00:00:00 2001
|
|
From: Phoenix616 <mail@moep.tv>
|
|
Date: Tue, 18 Sep 2018 23:53:23 +0100
|
|
Subject: [PATCH] PreSpawnerSpawnEvent
|
|
|
|
This adds a separate event before an entity is spawned by a spawner
|
|
which contains the location of the spawner too similarly to how the
|
|
SpawnerSpawnEvent gets called instead of the CreatureSpawnEvent for
|
|
spawners.
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/MobSpawnerAbstract.java b/src/main/java/net/minecraft/server/MobSpawnerAbstract.java
|
|
index 6f5d8b0315..079099e308 100644
|
|
--- a/src/main/java/net/minecraft/server/MobSpawnerAbstract.java
|
|
+++ b/src/main/java/net/minecraft/server/MobSpawnerAbstract.java
|
|
@@ -110,11 +110,11 @@ public abstract class MobSpawnerAbstract {
|
|
|
|
org.bukkit.entity.EntityType type = org.bukkit.entity.EntityType.fromName(key);
|
|
if (type != null) {
|
|
- com.destroystokyo.paper.event.entity.PreCreatureSpawnEvent event;
|
|
- event = new com.destroystokyo.paper.event.entity.PreCreatureSpawnEvent(
|
|
+ com.destroystokyo.paper.event.entity.PreSpawnerSpawnEvent event;
|
|
+ event = new com.destroystokyo.paper.event.entity.PreSpawnerSpawnEvent(
|
|
MCUtil.toLocation(world, d3, d4, d5),
|
|
type,
|
|
- org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.SPAWNER
|
|
+ MCUtil.toLocation(world, blockposition)
|
|
);
|
|
if (!event.callEvent()) {
|
|
flag = true;
|
|
--
|
|
2.22.0
|
|
|