@@ -1,8 +1,8 @@
|
||||
--- a/net/minecraft/server/BlockRedstoneOre.java
|
||||
+++ b/net/minecraft/server/BlockRedstoneOre.java
|
||||
@@ -2,6 +2,11 @@
|
||||
|
||||
import java.util.Random;
|
||||
--- a/net/minecraft/world/level/block/BlockRedstoneOre.java
|
||||
+++ b/net/minecraft/world/level/block/BlockRedstoneOre.java
|
||||
@@ -21,6 +21,11 @@
|
||||
import net.minecraft.world.level.block.state.properties.BlockStateBoolean;
|
||||
import net.minecraft.world.phys.MovingObjectPositionBlock;
|
||||
|
||||
+// CraftBukkit start
|
||||
+import org.bukkit.craftbukkit.event.CraftEventFactory;
|
||||
@@ -12,7 +12,7 @@
|
||||
public class BlockRedstoneOre extends Block {
|
||||
|
||||
public static final BlockStateBoolean a = BlockRedstoneTorch.LIT;
|
||||
@@ -13,14 +18,30 @@
|
||||
@@ -32,14 +37,30 @@
|
||||
|
||||
@Override
|
||||
public void attack(IBlockData iblockdata, World world, BlockPosition blockposition, EntityHuman entityhuman) {
|
||||
@@ -46,7 +46,7 @@
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -28,7 +49,7 @@
|
||||
@@ -47,7 +68,7 @@
|
||||
if (world.isClientSide) {
|
||||
playEffect(world, blockposition);
|
||||
} else {
|
||||
@@ -55,7 +55,7 @@
|
||||
}
|
||||
|
||||
ItemStack itemstack = entityhuman.b(enumhand);
|
||||
@@ -36,9 +57,14 @@
|
||||
@@ -55,9 +76,14 @@
|
||||
return itemstack.getItem() instanceof ItemBlock && (new BlockActionContext(entityhuman, enumhand, itemstack, movingobjectpositionblock)).b() ? EnumInteractionResult.PASS : EnumInteractionResult.SUCCESS;
|
||||
}
|
||||
|
||||
@@ -71,7 +71,7 @@
|
||||
world.setTypeAndData(blockposition, (IBlockData) iblockdata.set(BlockRedstoneOre.a, true), 3);
|
||||
}
|
||||
|
||||
@@ -52,6 +78,11 @@
|
||||
@@ -71,6 +97,11 @@
|
||||
@Override
|
||||
public void tick(IBlockData iblockdata, WorldServer worldserver, BlockPosition blockposition, Random random) {
|
||||
if ((Boolean) iblockdata.get(BlockRedstoneOre.a)) {
|
||||
@@ -83,7 +83,7 @@
|
||||
worldserver.setTypeAndData(blockposition, (IBlockData) iblockdata.set(BlockRedstoneOre.a, false), 3);
|
||||
}
|
||||
|
||||
@@ -60,12 +91,25 @@
|
||||
@@ -79,12 +110,25 @@
|
||||
@Override
|
||||
public void dropNaturally(IBlockData iblockdata, WorldServer worldserver, BlockPosition blockposition, ItemStack itemstack) {
|
||||
super.dropNaturally(iblockdata, worldserver, blockposition, itemstack);
|
||||
|
||||
Reference in New Issue
Block a user