Class ForgeRegistryHelper

java.lang.Object
de.cech12.usefulhats.platform.ForgeRegistryHelper
All Implemented Interfaces:
IRegistryHelper

public class ForgeRegistryHelper extends Object implements IRegistryHelper
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addGoalToMob(net.minecraft.world.entity.Mob mob, int position, net.minecraft.world.entity.ai.goal.Goal goal)
     
    boolean
    areEntityEyesInDrownableFluid(net.minecraft.world.entity.LivingEntity entity)
    Checks if the eyes of the given entity are in a fluid, where it can drown.
    List<net.minecraft.world.item.Item>
     
    List<net.minecraft.world.item.ItemStack>
    getEquippedHatItemStacks(net.minecraft.world.entity.LivingEntity entity)
    Get all equipped item stacks of hat items of this mod.
    boolean
    isAxe(net.minecraft.world.item.ItemStack tool)
     
    boolean
    isBossEntity(net.minecraft.world.entity.LivingEntity entity)
     
    boolean
    isEntityInFluid(net.minecraft.world.entity.LivingEntity entity)
    Checks if the given entity is in a fluid.
    boolean
    isHoe(net.minecraft.world.item.ItemStack tool)
     
    boolean
    isPickaxe(net.minecraft.world.item.ItemStack tool)
     
    boolean
    isShovel(net.minecraft.world.item.ItemStack tool)
     

    Methods inherited from class Object

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

    • ForgeRegistryHelper

      public ForgeRegistryHelper()
  • Method Details

    • addGoalToMob

      public void addGoalToMob(net.minecraft.world.entity.Mob mob, int position, net.minecraft.world.entity.ai.goal.Goal goal)
      Specified by:
      addGoalToMob in interface IRegistryHelper
    • isBossEntity

      public boolean isBossEntity(net.minecraft.world.entity.LivingEntity entity)
      Specified by:
      isBossEntity in interface IRegistryHelper
    • getAllHatItems

      public List<net.minecraft.world.item.Item> getAllHatItems()
      Specified by:
      getAllHatItems in interface IRegistryHelper
      Returns:
      Returns all available useful hats.
    • getEquippedHatItemStacks

      public List<net.minecraft.world.item.ItemStack> getEquippedHatItemStacks(net.minecraft.world.entity.LivingEntity entity)
      Description copied from interface: IRegistryHelper
      Get all equipped item stacks of hat items of this mod. Some APIs like Curios enables to have more than one slot. If two hats of the same item are worn, only one is in the list to avoid effect stacking.
      Specified by:
      getEquippedHatItemStacks in interface IRegistryHelper
      Parameters:
      entity - entity
      Returns:
      List of all equipped item stacks of hat items of this mod.
    • areEntityEyesInDrownableFluid

      public boolean areEntityEyesInDrownableFluid(net.minecraft.world.entity.LivingEntity entity)
      Description copied from interface: IRegistryHelper
      Checks if the eyes of the given entity are in a fluid, where it can drown.
      Specified by:
      areEntityEyesInDrownableFluid in interface IRegistryHelper
      Parameters:
      entity - entity to check
      Returns:
      true, if the eyes of the given entity are in a drownable fluid, else false
    • isEntityInFluid

      public boolean isEntityInFluid(net.minecraft.world.entity.LivingEntity entity)
      Description copied from interface: IRegistryHelper
      Checks if the given entity is in a fluid.
      Specified by:
      isEntityInFluid in interface IRegistryHelper
      Parameters:
      entity - entity to check
      Returns:
      true, if the given entity is in a fluid, else false
    • isAxe

      public boolean isAxe(net.minecraft.world.item.ItemStack tool)
      Specified by:
      isAxe in interface IRegistryHelper
    • isHoe

      public boolean isHoe(net.minecraft.world.item.ItemStack tool)
      Specified by:
      isHoe in interface IRegistryHelper
    • isPickaxe

      public boolean isPickaxe(net.minecraft.world.item.ItemStack tool)
      Specified by:
      isPickaxe in interface IRegistryHelper
    • isShovel

      public boolean isShovel(net.minecraft.world.item.ItemStack tool)
      Specified by:
      isShovel in interface IRegistryHelper