Make new press implementation savegame-compatible

This commit is contained in:
abel1502 2025-06-29 01:03:16 +03:00
parent 4a869ae2ea
commit 0eb87524ab
No known key found for this signature in database
GPG Key ID: 076926596A536338
2 changed files with 12 additions and 0 deletions

View File

@ -36,6 +36,12 @@ public class MachineEPress extends BlockDummyable {
return 0;
}
@Override
protected boolean isLegacyMonoblock(World world, int x, int y, int z) {
TileEntity te = world.getTileEntity(x, y, z);
return te != null && te instanceof TileEntityMachineEPress;
}
@Override
public void onBlockPlacedBy(World world, int x, int y, int z, EntityLivingBase player, ItemStack itemStack) {
super.onBlockPlacedBy(world, x, y, z, player, itemStack);

View File

@ -34,6 +34,12 @@ public class MachinePress extends BlockDummyable {
public int getOffset() {
return 0;
}
@Override
protected boolean isLegacyMonoblock(World world, int x, int y, int z) {
TileEntity te = world.getTileEntity(x, y, z);
return te != null && te instanceof TileEntityMachinePress;
}
@Override
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int side, float hitX, float hitY, float hitZ) {