Skip to content

Commit

Permalink
Fix ToolMaterial
Browse files Browse the repository at this point in the history
  • Loading branch information
TheidenHD committed Jun 16, 2024
1 parent f0337a9 commit a473e12
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 55 deletions.
17 changes: 14 additions & 3 deletions src/main/java/vazkii/psi/api/PsiAPI.java
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,16 @@
import net.minecraft.resources.ResourceKey;
import net.minecraft.resources.ResourceLocation;
import net.minecraft.sounds.SoundEvents;
import net.minecraft.tags.BlockTags;
import net.minecraft.world.entity.player.Player;
import net.minecraft.world.item.ItemStack;
import net.minecraft.world.item.Items;
import net.minecraft.world.item.Tier;
import net.minecraft.world.item.Tiers;
import net.minecraft.world.item.crafting.Ingredient;
import net.minecraftforge.api.distmarker.Dist;
import net.minecraftforge.common.ForgeTier;
import net.minecraftforge.common.TierSortingRegistry;
import net.minecraftforge.common.capabilities.Capability;
import net.minecraftforge.common.capabilities.CapabilityManager;
import net.minecraftforge.common.capabilities.CapabilityToken;
Expand All @@ -35,14 +41,15 @@
import vazkii.psi.api.internal.DummyMethodHandler;
import vazkii.psi.api.internal.IInternalMethodHandler;
import vazkii.psi.api.material.PsimetalArmorMaterial;
import vazkii.psi.api.material.PsimetalToolMaterial;
import vazkii.psi.api.spell.ISpellAcceptor;
import vazkii.psi.api.spell.ISpellImmune;
import vazkii.psi.api.spell.SpellPiece;
import vazkii.psi.api.spell.detonator.IDetonationHandler;
import vazkii.psi.common.item.base.ModItems;

import java.util.Collection;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;

Expand Down Expand Up @@ -80,8 +87,12 @@ public final class PsiAPI {
private static final Map<ResourceLocation, Class<? extends SpellPiece>> mainPieceForGroup = new HashMap<>();

public static final PsimetalArmorMaterial PSIMETAL_ARMOR_MATERIAL = new PsimetalArmorMaterial("psimetal", 18, new int[] { 2, 5, 6, 2 },
12, SoundEvents.ARMOR_EQUIP_IRON, 0F, () -> Ingredient.of(Registry.ITEM.get(new ResourceLocation(MOD_ID, "psimetal"))), 0.0f);
public static final PsimetalToolMaterial PSIMETAL_TOOL_MATERIAL = new PsimetalToolMaterial();
12, SoundEvents.ARMOR_EQUIP_IRON, 0F, () -> Ingredient.of(ForgeRegistries.ITEMS.getValue(new ResourceLocation(MOD_ID, "psimetal"))), 0.0f);
public static final Tier PSIMETAL_TOOL_MATERIAL = TierSortingRegistry.registerTier(
new ForgeTier(3, 900, 7.8F, 2F, 12, BlockTags.NEEDS_DIAMOND_TOOL, () -> Ingredient.of(ModItems.psimetal)),
new ResourceLocation(MOD_ID, "psimetal_tier"),
List.of(Tiers.DIAMOND), List.of(Tiers.NETHERITE));


/**
* Registers a Spell Piece.
Expand Down
52 changes: 0 additions & 52 deletions src/main/java/vazkii/psi/api/material/PsimetalToolMaterial.java

This file was deleted.

0 comments on commit a473e12

Please sign in to comment.