Remove getBundledRedstoneConnectivity

Wow, this is old. It looks like it's a legacy of when this method was on
TileGeneric (and so returned false by default). As all implementations
now return true (turtle tools no longer block redstone), we don't really
need this any more.
This commit is contained in:
Jonathan Coates 2023-08-27 23:54:27 +01:00
parent 5b58271b92
commit 13ed422bd5
No known key found for this signature in database
GPG Key ID: B9E431FF07C98D06
3 changed files with 1 additions and 13 deletions

View File

@ -18,11 +18,6 @@ public int getBundledRedstoneOutput(Level world, BlockPos pos, Direction side) {
public static int getDefaultBundledRedstoneOutput(Level world, BlockPos pos, Direction side) {
var block = world.getBlockState(pos).getBlock();
if (block instanceof IBundledRedstoneBlock generic) {
if (generic.getBundledRedstoneConnectivity(world, pos, side)) {
return generic.getBundledRedstoneOutput(world, pos, side);
}
}
return -1;
return block instanceof IBundledRedstoneBlock bundledBlock ? bundledBlock.getBundledRedstoneOutput(world, pos, side) : -1;
}
}

View File

@ -9,7 +9,5 @@
import net.minecraft.world.level.Level;
public interface IBundledRedstoneBlock {
boolean getBundledRedstoneConnectivity(Level world, BlockPos pos, Direction side);
int getBundledRedstoneOutput(Level world, BlockPos pos, Direction side);
}

View File

@ -92,11 +92,6 @@ public int getSignal(BlockState state, BlockGetter world, BlockPos pos, Directio
return getDirectSignal(state, world, pos, incomingSide);
}
@Override
public boolean getBundledRedstoneConnectivity(Level world, BlockPos pos, Direction side) {
return true;
}
@Override
public int getBundledRedstoneOutput(Level world, BlockPos pos, Direction side) {
var entity = world.getBlockEntity(pos);