Move patches to unapplied
This commit is contained in:
@@ -1,28 +0,0 @@
|
||||
--- a/net/minecraft/world/item/FlintAndSteelItem.java
|
||||
+++ b/net/minecraft/world/item/FlintAndSteelItem.java
|
||||
@@ -37,6 +37,12 @@
|
||||
BlockPos blockposition1 = blockposition.relative(context.getClickedFace());
|
||||
|
||||
if (BaseFireBlock.canBePlacedAt(world, blockposition1, context.getHorizontalDirection())) {
|
||||
+ // CraftBukkit start - Store the clicked block
|
||||
+ if (org.bukkit.craftbukkit.event.CraftEventFactory.callBlockIgniteEvent(world, blockposition1, org.bukkit.event.block.BlockIgniteEvent.IgniteCause.FLINT_AND_STEEL, entityhuman).isCancelled()) {
|
||||
+ context.getItemInHand().hurtAndBreak(1, entityhuman, LivingEntity.getSlotForHand(context.getHand()));
|
||||
+ return InteractionResult.PASS;
|
||||
+ }
|
||||
+ // CraftBukkit end
|
||||
world.playSound(entityhuman, blockposition1, SoundEvents.FLINTANDSTEEL_USE, SoundSource.BLOCKS, 1.0F, world.getRandom().nextFloat() * 0.4F + 0.8F);
|
||||
BlockState iblockdata1 = BaseFireBlock.getState(world, blockposition1);
|
||||
|
||||
@@ -54,6 +60,12 @@
|
||||
return InteractionResult.FAIL;
|
||||
}
|
||||
} else {
|
||||
+ // CraftBukkit start - Store the clicked block
|
||||
+ if (org.bukkit.craftbukkit.event.CraftEventFactory.callBlockIgniteEvent(world, blockposition, org.bukkit.event.block.BlockIgniteEvent.IgniteCause.FLINT_AND_STEEL, entityhuman).isCancelled()) {
|
||||
+ context.getItemInHand().hurtAndBreak(1, entityhuman, LivingEntity.getSlotForHand(context.getHand()));
|
||||
+ return InteractionResult.PASS;
|
||||
+ }
|
||||
+ // CraftBukkit end
|
||||
world.playSound(entityhuman, blockposition, SoundEvents.FLINTANDSTEEL_USE, SoundSource.BLOCKS, 1.0F, world.getRandom().nextFloat() * 0.4F + 0.8F);
|
||||
world.setBlock(blockposition, (BlockState) iblockdata.setValue(BlockStateProperties.LIT, true), 11);
|
||||
world.gameEvent((Entity) entityhuman, (Holder) GameEvent.BLOCK_CHANGE, blockposition);
|
||||
Reference in New Issue
Block a user