@@ -1,6 +1,6 @@
|
||||
--- a/net/minecraft/world/level/block/BlockCampfire.java
|
||||
+++ b/net/minecraft/world/level/block/BlockCampfire.java
|
||||
@@ -105,7 +105,7 @@
|
||||
@@ -113,7 +113,7 @@
|
||||
@Override
|
||||
protected void entityInside(IBlockData iblockdata, World world, BlockPosition blockposition, Entity entity) {
|
||||
if ((Boolean) iblockdata.getValue(BlockCampfire.LIT) && entity instanceof EntityLiving) {
|
||||
@@ -9,15 +9,15 @@
|
||||
}
|
||||
|
||||
super.entityInside(iblockdata, world, blockposition, entity);
|
||||
@@ -215,6 +215,11 @@
|
||||
BlockPosition blockposition = movingobjectpositionblock.getBlockPos();
|
||||
@@ -224,6 +224,11 @@
|
||||
|
||||
if (!world.isClientSide && iprojectile.isOnFire() && iprojectile.mayInteract(world, blockposition) && !(Boolean) iblockdata.getValue(BlockCampfire.LIT) && !(Boolean) iblockdata.getValue(BlockCampfire.WATERLOGGED)) {
|
||||
+ // CraftBukkit start
|
||||
+ if (org.bukkit.craftbukkit.event.CraftEventFactory.callBlockIgniteEvent(world, blockposition, iprojectile).isCancelled()) {
|
||||
+ return;
|
||||
+ }
|
||||
+ // CraftBukkit end
|
||||
world.setBlock(blockposition, (IBlockData) iblockdata.setValue(BlockProperties.LIT, true), 11);
|
||||
if (world instanceof WorldServer worldserver) {
|
||||
if (iprojectile.isOnFire() && iprojectile.mayInteract(worldserver, blockposition) && !(Boolean) iblockdata.getValue(BlockCampfire.LIT) && !(Boolean) iblockdata.getValue(BlockCampfire.WATERLOGGED)) {
|
||||
+ // CraftBukkit start
|
||||
+ if (org.bukkit.craftbukkit.event.CraftEventFactory.callBlockIgniteEvent(world, blockposition, iprojectile).isCancelled()) {
|
||||
+ return;
|
||||
+ }
|
||||
+ // CraftBukkit end
|
||||
world.setBlock(blockposition, (IBlockData) iblockdata.setValue(BlockProperties.LIT, true), 11);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user