Class TagUtils

java.lang.Object
com.minecolonies.api.util.TagUtils

public final class TagUtils extends Object
Class for specific minecraft tag utilities.
  • Method Summary

    Modifier and Type
    Method
    Description
    static net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block>
    getBlock(net.minecraft.resources.ResourceLocation resourceLocation)
    Get a tag for items.
    static net.minecraft.tags.TagKey<net.minecraft.world.item.Item>
    getItem(net.minecraft.resources.ResourceLocation resourceLocation)
    Get a tag for items.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • getItem

      public static net.minecraft.tags.TagKey<net.minecraft.world.item.Item> getItem(net.minecraft.resources.ResourceLocation resourceLocation)
      Get a tag for items.
      Parameters:
      resourceLocation - the unique id.
      Returns:
      the tag or an empty placeholder if not existant.
    • getBlock

      public static net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block> getBlock(net.minecraft.resources.ResourceLocation resourceLocation)
      Get a tag for items.
      Parameters:
      resourceLocation - the unique id.
      Returns:
      the tag or an empty placeholder if not existant.