package de.ellpeck.actuallyadditions.api; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; import net.minecraft.core.registries.Registries; import net.minecraft.resources.ResourceLocation; import net.minecraft.tags.ItemTags; import net.minecraft.tags.TagKey; import net.minecraft.world.item.Item; import net.minecraft.world.level.block.Block; public final class ActuallyTags { public static final void init() { // lol Items.touch(); Blocks.touch(); } public static class Items { public static void touch() { // load the stupid tags } public static final TagKey DRILLS = tag("drills"); public static final TagKey COFFEE_BEANS = tag("coffee_beans"); public static final TagKey TINY_COALS = tag("tiny_coals"); public static final TagKey HOLDS_ITEMS = ItemTags.create(new ResourceLocation("forge", "holds_items")); public static final TagKey CRYSTALS = tag("crystals"); private static TagKey tag(String name) { return TagKey.create(Registries.ITEM, new ResourceLocation(ActuallyAdditions.MODID, name)); } } public static class Blocks { public static void touch() { // load the stupid tags } public static final TagKey MINEABLE_WITH_DRILL = tag("mineable/drill"); public static final TagKey MINEABLE_WITH_AIO = tag("mineable/aio"); public static final TagKey NEEDS_BLACK_QUARTZ_TOOL = tag("needs_black_quartz_tool"); public static final TagKey NEEDS_RESTONIA_TOOL = tag("needs_restonia_tool"); public static final TagKey NEEDS_PALIS_TOOL = tag("needs_palis_tool"); public static final TagKey NEEDS_DIAMATINE_TOOL = tag("needs_diamatine_tool"); public static final TagKey NEEDS_VOID_TOOL = tag("needs_void_tool"); public static final TagKey NEEDS_EMERADIC_TOOL = tag("needs_emeradic_tool"); public static final TagKey NEEDS_ENORI_TOOL = tag("needs_enori_tool"); private static TagKey tag(String name) { return TagKey.create(Registries.BLOCK, new ResourceLocation(ActuallyAdditions.MODID, name)); } } }