Class ForgeRegistryHelper
java.lang.Object
de.cech12.usefulhats.platform.ForgeRegistryHelper
- All Implemented Interfaces:
IRegistryHelper
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddGoalToMob(net.minecraft.world.entity.Mob mob, int position, net.minecraft.world.entity.ai.goal.Goal goal) booleanareEntityEyesInDrownableFluid(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.booleanisAxe(net.minecraft.world.item.ItemStack tool) booleanisBossEntity(net.minecraft.world.entity.LivingEntity entity) booleanisEntityInFluid(net.minecraft.world.entity.LivingEntity entity) Checks if the given entity is in a fluid.booleanisHoe(net.minecraft.world.item.ItemStack tool) booleanisPickaxe(net.minecraft.world.item.ItemStack tool) booleanisShovel(net.minecraft.world.item.ItemStack tool)
-
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:
addGoalToMobin interfaceIRegistryHelper
-
isBossEntity
public boolean isBossEntity(net.minecraft.world.entity.LivingEntity entity) - Specified by:
isBossEntityin interfaceIRegistryHelper
-
getAllHatItems
- Specified by:
getAllHatItemsin interfaceIRegistryHelper- 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:IRegistryHelperGet 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:
getEquippedHatItemStacksin interfaceIRegistryHelper- 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:IRegistryHelperChecks if the eyes of the given entity are in a fluid, where it can drown.- Specified by:
areEntityEyesInDrownableFluidin interfaceIRegistryHelper- 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:IRegistryHelperChecks if the given entity is in a fluid.- Specified by:
isEntityInFluidin interfaceIRegistryHelper- 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:
isAxein interfaceIRegistryHelper
-
isHoe
public boolean isHoe(net.minecraft.world.item.ItemStack tool) - Specified by:
isHoein interfaceIRegistryHelper
-
isPickaxe
public boolean isPickaxe(net.minecraft.world.item.ItemStack tool) - Specified by:
isPickaxein interfaceIRegistryHelper
-
isShovel
public boolean isShovel(net.minecraft.world.item.ItemStack tool) - Specified by:
isShovelin interfaceIRegistryHelper
-