1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2025-03-21 10:56:58 +00:00

Fix breaking computers having no particle or sound

This commit is contained in:
Jonathan Coates 2023-05-31 19:18:19 +01:00
parent d3b39be9a8
commit b09200a270
No known key found for this signature in database
GPG Key ID: B9E431FF07C98D06

View File

@ -130,6 +130,7 @@ public abstract class AbstractComputerBlock<T extends AbstractComputerBlockEntit
@Override
public void playerWillDestroy(Level world, BlockPos pos, BlockState state, Player player) {
super.playerWillDestroy(world, pos, state, player);
if (!(world instanceof ServerLevel serverWorld)) return;
// We drop the item here instead of doing it in the harvest method, as we should