Commits

md_5 authored 9a1f5ee80a8
Update to Minecraft 1.12.2
No tags

nms-patches/BlockEnderPortal.patch

Modified
5 5 import javax.annotation.Nullable;
6 6
7 7 +import org.bukkit.event.entity.EntityPortalEnterEvent; // CraftBukkit
8 8 +
9 9 public class BlockEnderPortal extends BlockTileEntity {
10 10
11 11 protected static final AxisAlignedBB a = new AxisAlignedBB(0.0D, 0.0D, 0.0D, 1.0D, 0.75D, 1.0D);
12 12 @@ -37,6 +39,10 @@
13 13
14 14 public void a(World world, BlockPosition blockposition, IBlockData iblockdata, Entity entity) {
15 - if (!entity.isPassenger() && !entity.isVehicle() && entity.bf() && !world.isClientSide && entity.getBoundingBox().c(iblockdata.e(world, blockposition).a(blockposition))) {
15 + if (!world.isClientSide && !entity.isPassenger() && !entity.isVehicle() && entity.bf() && entity.getBoundingBox().c(iblockdata.e(world, blockposition).a(blockposition))) {
16 16 + // CraftBukkit start - Entity in portal
17 17 + EntityPortalEnterEvent event = new EntityPortalEnterEvent(entity.getBukkitEntity(), new org.bukkit.Location(world.getWorld(), blockposition.getX(), blockposition.getY(), blockposition.getZ()));
18 18 + world.getServer().getPluginManager().callEvent(event);
19 19 + // CraftBukkit end
20 20 entity.b(1);
21 21 }
22 22

Everything looks good. We'll let you know here if there's anything you should know about.

Add shortcut