|
11 | 11 | import zero.test.mixin.IPistonBaseAccessMixins; |
12 | 12 | import zero.test.IWorldMixins; |
13 | 13 | import zero.test.IBlockEntityPistonMixins; |
| 14 | +import zero.test.ZeroUtil; |
14 | 15 | // Block piston reactions |
15 | 16 | public class TurntableResolver { |
16 | 17 | private static final int TURNTABLE_HEIGHT_LIMIT = |
@@ -158,11 +159,16 @@ public int turnBlocks(World world, int x, int y, int z, boolean reverse, int cra |
158 | 159 | for (int i = attachment_index_global; --i >= ATTACHMENT_LIST_START_INDEX;) { |
159 | 160 | packedPos = pillar_blocks[i]; |
160 | 161 | {(x)=((int)((packedPos)<<26>>(64)-26));(z)=((int)((packedPos)>>(64)-26));(y)=((int)(packedPos)<<(32)-12>>(32)-12);}; |
161 | | - if (Block.blocksList[((data_list[i])&0xFFF)].hasTileEntity()) { |
| 162 | + blockId = ((data_list[i])&0xFFF); |
| 163 | + Block block = Block.blocksList[blockId]; |
| 164 | + if (block.hasTileEntity()) { |
162 | 165 | tile_entity_list[tile_entity_index++] = world.getBlockTileEntity(x, y, z); |
163 | 166 | world.removeBlockTileEntity(x, y, z); |
164 | 167 | } |
165 | 168 | world.setBlock(x, y, z, 0, 0, 0x01 | 0x02); |
| 169 | + if (block.hasComparatorInputOverride()) { |
| 170 | + world.func_96440_m(x, y, z, blockId); |
| 171 | + } |
166 | 172 | } |
167 | 173 | for (int i = pillar_index_global; --i >= PILLAR_LIST_START_INDEX;) { |
168 | 174 | packedPos = pillar_blocks[i]; |
@@ -217,6 +223,9 @@ public int turnBlocks(World world, int x, int y, int z, boolean reverse, int cra |
217 | 223 | } |
218 | 224 | } |
219 | 225 | else { |
| 226 | + if (tile_entity != null) { |
| 227 | + ZeroUtil.break_tile_entity(world, x, y, z, tile_entity); |
| 228 | + } |
220 | 229 | // This seems like it could be an issue. |
221 | 230 | // Maybe destroy the block instead? |
222 | 231 | block.dropBlockAsItem(world, x, y, z, blockId, blockMeta); |
|
0 commit comments