Files
CatServer/patches/net/minecraft/block/BlockRotatedPillar.java.patch
2019-02-24 22:29:41 +08:00

25 lines
773 B
Diff

--- ../src-base/minecraft/net/minecraft/block/BlockRotatedPillar.java
+++ ../src-work/minecraft/net/minecraft/block/BlockRotatedPillar.java
@@ -28,6 +28,21 @@
super(materialIn, color);
}
+ @Override
+ public boolean rotateBlock(net.minecraft.world.World world, BlockPos pos, EnumFacing axis)
+ {
+ IBlockState state = world.getBlockState(pos);
+ for (IProperty<?> prop : state.getProperties().keySet())
+ {
+ if (prop.getName().equals("axis"))
+ {
+ world.setBlockState(pos, state.cycleProperty(prop));
+ return true;
+ }
+ }
+ return false;
+ }
+
public IBlockState withRotation(IBlockState state, Rotation rot)
{
switch (rot)