Fix firestarter eating cake instead of lighting it on fire
@@ -97,6 +97,17 @@ public class FirestarterModifier extends InteractionModifier.NoLevels {
return false;
}
+ @Override
+ public InteractionResult beforeBlockUse(IToolStackView tool, int level, UseOnContext context, EquipmentSlot slotType) {
+ if (tool.isBroken()) {
+ return InteractionResult.PASS;
+ }
+ if (context.getLevel().getBlockState(context.getClickedPos()).is(BlockTags.CANDLE_CAKES)) {
+ return afterBlockUse(tool, level, context, slotType);
+ }
+ return InteractionResult.PASS;
+ }
+
@Override
public InteractionResult afterBlockUse(IToolStackView tool, int level, UseOnContext context, EquipmentSlot slotType) {
if (tool.isBroken()) {
