add missing call to EntityInsideBlockEvent
Dieser Commit ist enthalten in:
Ursprung
59060aaec3
Commit
e325e37268
@ -6,10 +6,10 @@ Subject: [PATCH] Add EntityInsideBlockEvent
|
||||
|
||||
diff --git a/src/main/java/io/papermc/paper/event/entity/EntityInsideBlockEvent.java b/src/main/java/io/papermc/paper/event/entity/EntityInsideBlockEvent.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..447fed3d39d68f13fd6cd94332c7ec7553d8e0df
|
||||
index 0000000000000000000000000000000000000000..109dd7e6d0e7bb0a83fc4c5230f7d5dc122f2bb5
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/io/papermc/paper/event/entity/EntityInsideBlockEvent.java
|
||||
@@ -0,0 +1,83 @@
|
||||
@@ -0,0 +1,84 @@
|
||||
+package io.papermc.paper.event.entity;
|
||||
+
|
||||
+import org.bukkit.block.Block;
|
||||
@ -41,6 +41,7 @@ index 0000000000000000000000000000000000000000..447fed3d39d68f13fd6cd94332c7ec75
|
||||
+ * <li>Hopper</li>
|
||||
+ * <li>Detector rails</li>
|
||||
+ * <li>Nether portals</li>
|
||||
+ * <li>Pitcher crop</li>
|
||||
+ * <li>Powdered snow</li>
|
||||
+ * <li>Pressure plates</li>
|
||||
+ * <li>Sweet berry bush</li>
|
||||
|
@ -196,6 +196,18 @@ index 69f34c566bf825259253abbefd7d7ba2e847231b..a6ab0d0defc05e56a91084c498970596
|
||||
if (entity.canChangeDimensions()) {
|
||||
// CraftBukkit start - Entity in portal
|
||||
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/PitcherCropBlock.java b/src/main/java/net/minecraft/world/level/block/PitcherCropBlock.java
|
||||
index 94e0bf98753d3dee5ad275e4783682025f687ddf..593eae04ecf6dee86c9c3664ddcdc3f86d042e66 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/block/PitcherCropBlock.java
|
||||
+++ b/src/main/java/net/minecraft/world/level/block/PitcherCropBlock.java
|
||||
@@ -96,6 +96,7 @@ public class PitcherCropBlock extends DoublePlantBlock implements BonemealableBl
|
||||
|
||||
@Override
|
||||
public 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
|
||||
if (entity instanceof Ravager && world.getGameRules().getBoolean(GameRules.RULE_MOBGRIEFING)) {
|
||||
world.destroyBlock(pos, true, entity);
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/world/level/block/PowderSnowBlock.java b/src/main/java/net/minecraft/world/level/block/PowderSnowBlock.java
|
||||
index 47f54002654d198a56a85884de34e305e545eb4b..518d3832c36c9ecf1ed9267ffc1f926dc84b7989 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/block/PowderSnowBlock.java
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren