Skip to content

Commit

Permalink
fix silly crash
Browse files Browse the repository at this point in the history
  • Loading branch information
Thepigcat76 committed Nov 19, 2024
1 parent 7f8e8f2 commit 1361115
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 1 addition & 3 deletions src/main/java/com/portingdeadmods/nautec/NTConfig.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
package com.portingdeadmods.nautec;

import net.minecraft.core.registries.BuiltInRegistries;
import net.minecraft.resources.ResourceLocation;
import net.neoforged.bus.api.SubscribeEvent;
import net.neoforged.fml.common.EventBusSubscriber;
import net.neoforged.fml.event.config.ModConfigEvent;
Expand Down Expand Up @@ -60,7 +58,6 @@ public final class NTConfig {
.comment("The amount of damage the guardian augments laser deals")
.defineInRange("guardianAugmentDamage", 3, 0, Integer.MAX_VALUE);


static final ModConfigSpec SPEC = BUILDER.build();

public static int kelpHeight;
Expand Down Expand Up @@ -104,4 +101,5 @@ static void onLoad(final ModConfigEvent event) {

guardianAugmentDamage = GUARDIAN_AUGMENT_DAMAGE.get();
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,10 @@ protected MapCodec<? extends BaseEntityBlock> codec() {
} else if (p_60503_.getValue(Multiblock.FORMED)) {
ItemStack stack = player.getMainHandItem();
IFluidHandler itemFluidHandler = stack.getCapability(Capabilities.FluidHandler.ITEM);
extractFluid(player, level, InteractionHand.MAIN_HAND, (FluidTank) drainBlockEntity.getFluidHandler(), itemFluidHandler);
return InteractionResult.SUCCESS;
if (itemFluidHandler != null) {
extractFluid(player, level, InteractionHand.MAIN_HAND, (FluidTank) drainBlockEntity.getFluidHandler(), itemFluidHandler);
return InteractionResult.SUCCESS;
}
}
}

Expand Down

0 comments on commit 1361115

Please sign in to comment.