fixed the tree ritual not working right with acacia

closes #13
This commit is contained in:
Ellpeck 2018-11-23 17:15:42 +01:00
parent 628f67eb36
commit e1f0bf63c3

View file

@ -129,14 +129,18 @@ public class TileEntityWoodStand extends TileEntityImpl implements ITickable {
return; return;
} }
for (EnumFacing facing : EnumFacing.VALUES) { for (int x = -1; x <= 1; x++) {
BlockPos offset = pos.offset(facing); for (int y = -1; y <= 1; y++) {
IBlockState state = this.world.getBlockState(offset); for (int z = -1; z <= 1; z++) {
if (state.getBlock() instanceof BlockLog || state.getBlock() instanceof BlockLeaves) { BlockPos offset = pos.add(x, y, z);
this.world.setBlockToAir(offset); IBlockState state = this.world.getBlockState(offset);
PacketHandler.sendToAllAround(this.world, this.pos, 32, new PacketParticles(offset.getX(), offset.getY(), offset.getZ(), 2)); if (state.getBlock() instanceof BlockLog || state.getBlock() instanceof BlockLeaves) {
this.world.setBlockToAir(offset);
PacketHandler.sendToAllAround(this.world, this.pos, 32, new PacketParticles(offset.getX(), offset.getY(), offset.getZ(), 2));
this.recurseTreeDestruction(offset, start); this.recurseTreeDestruction(offset, start);
}
}
} }
} }
} }