mirror of
https://github.com/SquidDev-CC/CC-Tweaked
synced 2025-02-13 01:20:04 +00:00
Don't expose a menu provider for computers
We can't safely use this anyway (as custom data is not sent), so better not to expose it at all. Fixes #1844.
This commit is contained in:
parent
d48b85d50c
commit
862d92785e
@ -18,7 +18,6 @@ import net.minecraft.server.level.ServerLevel;
|
|||||||
import net.minecraft.stats.Stats;
|
import net.minecraft.stats.Stats;
|
||||||
import net.minecraft.world.InteractionHand;
|
import net.minecraft.world.InteractionHand;
|
||||||
import net.minecraft.world.InteractionResult;
|
import net.minecraft.world.InteractionResult;
|
||||||
import net.minecraft.world.MenuProvider;
|
|
||||||
import net.minecraft.world.entity.LivingEntity;
|
import net.minecraft.world.entity.LivingEntity;
|
||||||
import net.minecraft.world.entity.player.Player;
|
import net.minecraft.world.entity.player.Player;
|
||||||
import net.minecraft.world.item.ItemStack;
|
import net.minecraft.world.item.ItemStack;
|
||||||
@ -196,13 +195,6 @@ public abstract class AbstractComputerBlock<T extends AbstractComputerBlockEntit
|
|||||||
return super.updateShape(state, direction, neighborState, level, pos, neighborPos);
|
return super.updateShape(state, direction, neighborState, level, pos, neighborPos);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Nullable
|
|
||||||
@Override
|
|
||||||
@Deprecated
|
|
||||||
public MenuProvider getMenuProvider(BlockState state, Level level, BlockPos pos) {
|
|
||||||
return level.getBlockEntity(pos) instanceof AbstractComputerBlockEntity computer ? computer : null;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@Nullable
|
@Nullable
|
||||||
public <U extends BlockEntity> BlockEntityTicker<U> getTicker(Level level, BlockState state, BlockEntityType<U> type) {
|
public <U extends BlockEntity> BlockEntityTicker<U> getTicker(Level level, BlockState state, BlockEntityType<U> type) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user