mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 07:20:24 +01:00
call EntityInsideBlockEvent for eyeblossom
This commit is contained in:
parent
7d18cb068e
commit
4758f1202f
2 changed files with 13 additions and 0 deletions
|
@ -37,6 +37,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||||
+ * <li>Crops</li>
|
+ * <li>Crops</li>
|
||||||
+ * <li>End Gateway</li>
|
+ * <li>End Gateway</li>
|
||||||
+ * <li>Ender Portal</li>
|
+ * <li>Ender Portal</li>
|
||||||
|
+ * <li>Eye blossom</li>
|
||||||
+ * <li>Fires</li>
|
+ * <li>Fires</li>
|
||||||
+ * <li>Frogspawn</li>
|
+ * <li>Frogspawn</li>
|
||||||
+ * <li>Honey</li>
|
+ * <li>Honey</li>
|
||||||
|
|
|
@ -136,6 +136,18 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||||
if (entity.canUsePortal(false)) {
|
if (entity.canUsePortal(false)) {
|
||||||
// CraftBukkit start - Entity in portal
|
// CraftBukkit start - Entity in portal
|
||||||
EntityPortalEnterEvent event = new EntityPortalEnterEvent(entity.getBukkitEntity(), new org.bukkit.Location(world.getWorld(), pos.getX(), pos.getY(), pos.getZ()));
|
EntityPortalEnterEvent event = new EntityPortalEnterEvent(entity.getBukkitEntity(), new org.bukkit.Location(world.getWorld(), pos.getX(), pos.getY(), pos.getZ()));
|
||||||
|
diff --git a/src/main/java/net/minecraft/world/level/block/EyeblossomBlock.java b/src/main/java/net/minecraft/world/level/block/EyeblossomBlock.java
|
||||||
|
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||||
|
--- a/src/main/java/net/minecraft/world/level/block/EyeblossomBlock.java
|
||||||
|
+++ b/src/main/java/net/minecraft/world/level/block/EyeblossomBlock.java
|
||||||
|
@@ -0,0 +0,0 @@ public class EyeblossomBlock extends FlowerBlock {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void entityInside(BlockState state, Level world, BlockPos pos, Entity entity) {
|
||||||
|
+ if (!new io.papermc.paper.event.entity.EntityInsideBlockEvent(entity.getBukkitEntity(), org.bukkit.craftbukkit.block.CraftBlock.at(world, pos)).callEvent()) { return; } // Paper - Add EntityInsideBlockEvent
|
||||||
|
if (!world.isClientSide()
|
||||||
|
&& world.getDifficulty() != Difficulty.PEACEFUL
|
||||||
|
&& entity instanceof Bee bee
|
||||||
diff --git a/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java b/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java
|
diff --git a/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java b/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java
|
||||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||||
--- a/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java
|
--- a/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java
|
||||||
|
|
Loading…
Reference in a new issue