@@ -1,6 +1,6 @@
|
||||
--- a/net/minecraft/world/level/block/BlockRedstoneOre.java
|
||||
+++ b/net/minecraft/world/level/block/BlockRedstoneOre.java
|
||||
@@ -21,6 +21,11 @@
|
||||
@@ -22,6 +22,11 @@
|
||||
import net.minecraft.world.level.block.state.properties.BlockStateBoolean;
|
||||
import net.minecraft.world.phys.MovingObjectPositionBlock;
|
||||
|
||||
@@ -11,8 +11,8 @@
|
||||
+
|
||||
public class BlockRedstoneOre extends Block {
|
||||
|
||||
public static final BlockStateBoolean LIT = BlockRedstoneTorch.LIT;
|
||||
@@ -32,14 +37,27 @@
|
||||
public static final MapCodec<BlockRedstoneOre> CODEC = simpleCodec(BlockRedstoneOre::new);
|
||||
@@ -39,14 +44,27 @@
|
||||
|
||||
@Override
|
||||
public void attack(IBlockData iblockdata, World world, BlockPosition blockposition, EntityHuman entityhuman) {
|
||||
@@ -42,7 +42,7 @@
|
||||
}
|
||||
|
||||
super.stepOn(world, blockposition, iblockdata, entity);
|
||||
@@ -50,7 +68,7 @@
|
||||
@@ -57,7 +75,7 @@
|
||||
if (world.isClientSide) {
|
||||
spawnParticles(world, blockposition);
|
||||
} else {
|
||||
@@ -51,7 +51,7 @@
|
||||
}
|
||||
|
||||
ItemStack itemstack = entityhuman.getItemInHand(enumhand);
|
||||
@@ -58,9 +76,14 @@
|
||||
@@ -65,9 +83,14 @@
|
||||
return itemstack.getItem() instanceof ItemBlock && (new BlockActionContext(entityhuman, enumhand, itemstack, movingobjectpositionblock)).canPlace() ? EnumInteractionResult.PASS : EnumInteractionResult.SUCCESS;
|
||||
}
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
world.setBlock(blockposition, (IBlockData) iblockdata.setValue(BlockRedstoneOre.LIT, true), 3);
|
||||
}
|
||||
|
||||
@@ -74,6 +97,11 @@
|
||||
@@ -81,6 +104,11 @@
|
||||
@Override
|
||||
public void randomTick(IBlockData iblockdata, WorldServer worldserver, BlockPosition blockposition, RandomSource randomsource) {
|
||||
if ((Boolean) iblockdata.getValue(BlockRedstoneOre.LIT)) {
|
||||
@@ -79,7 +79,7 @@
|
||||
worldserver.setBlock(blockposition, (IBlockData) iblockdata.setValue(BlockRedstoneOre.LIT, false), 3);
|
||||
}
|
||||
|
||||
@@ -82,12 +110,20 @@
|
||||
@@ -89,12 +117,20 @@
|
||||
@Override
|
||||
public void spawnAfterBreak(IBlockData iblockdata, WorldServer worldserver, BlockPosition blockposition, ItemStack itemstack, boolean flag) {
|
||||
super.spawnAfterBreak(iblockdata, worldserver, blockposition, itemstack, flag);
|
||||
|
||||
Reference in New Issue
Block a user