Compare commits

..

No commits in common. "ae1e7a404f3d14ef2faf217ecf63f35382c6ed25" and "2acd74b12cf1bd2da37026cafb004d386be4444f" have entirely different histories.

2 changed files with 3 additions and 3 deletions

View file

@ -15,4 +15,4 @@ botania=1.18.2-430-SNAPSHOT
jei_version=jei-1.18.2:9.5.0.132 jei_version=jei-1.18.2:9.5.0.132
version_major=2 version_major=2
version_minor=9 version_minor=7

View file

@ -1,8 +1,8 @@
package thetadev.constructionwand.wand; package thetadev.constructionwand.wand;
import net.minecraft.core.BlockPos; import net.minecraft.core.BlockPos;
import net.minecraft.server.level.ServerPlayer;
import net.minecraft.sounds.SoundSource; import net.minecraft.sounds.SoundSource;
import net.minecraft.world.InteractionHand;
import net.minecraft.world.entity.player.Player; import net.minecraft.world.entity.player.Player;
import net.minecraft.world.item.BlockItem; import net.minecraft.world.item.BlockItem;
import net.minecraft.world.item.Item; import net.minecraft.world.item.Item;
@ -99,7 +99,7 @@ public class WandJob
// If the item cant be taken, undo the placement // If the item cant be taken, undo the placement
if(wandSupplier.takeItemStack(snapshot.getRequiredItems()) == 0) { if(wandSupplier.takeItemStack(snapshot.getRequiredItems()) == 0) {
executed.add(snapshot); executed.add(snapshot);
wand.hurtAndBreak(1, player, e -> e.broadcastBreakEvent(InteractionHand.MAIN_HAND)); wand.hurt(1, player.getRandom(), (ServerPlayer) player);
} }
else { else {
ConstructionWand.LOGGER.info("Item could not be taken. Remove block: " + ConstructionWand.LOGGER.info("Item could not be taken. Remove block: " +