Skip to content

Commit

Permalink
fix: Conduit dupe when breaking with yeta wrench
Browse files Browse the repository at this point in the history
Fixes: GH-914
  • Loading branch information
Rover656 committed Dec 11, 2024
1 parent 91f9f71 commit 54fc279
Showing 1 changed file with 0 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -302,9 +302,6 @@ public static void handleShiftYeta(PlayerInteractEvent.RightClickBlock event) {
if (conduit != null) {
blockEntity.removeTypeAndDelete(event.getEntity(), conduit);
if (event.getLevel() instanceof ServerLevel serverLevel) {
Inventory inventory = event.getEntity().getInventory();
inventory.placeItemBackInInventory(ConduitBlockItem.getStackFor(conduit, 1));

ServerPlayer player = (ServerPlayer) event.getEntity();
event.getLevel().playSound(null, event.getPos(), SoundEvents.ITEM_PICKUP, SoundSource.PLAYERS, 0.2f,
((player.getRandom().nextFloat() - player.getRandom().nextFloat()) * 0.7F + 1.0F) * 2.0F);
Expand Down

0 comments on commit 54fc279

Please sign in to comment.