Interface IArmorApiaristHelper


public interface IArmorApiaristHelper
Helper class for checking whether an entity is wearing Apiarist Armor
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    isArmorApiarist(net.minecraft.world.item.ItemStack stack, net.minecraft.world.entity.LivingEntity entity, IBeeEffect cause, boolean doProtect)
    Called when the apiarist's armor acts as protection against an attack.
    int
    wearsItems(net.minecraft.world.entity.LivingEntity entity, IBeeEffect cause, boolean doProtect)
    Called when the apiarist's armor acts as protection against an attack.
  • Method Details

    • isArmorApiarist

      boolean isArmorApiarist(net.minecraft.world.item.ItemStack stack, net.minecraft.world.entity.LivingEntity entity, IBeeEffect cause, boolean doProtect)
      Called when the apiarist's armor acts as protection against an attack.
      Parameters:
      stack - ItemStack to check
      entity - Entity being attacked
      cause - Optional cause of attack, such as a bee effect identifier
      doProtect - Whether or not to actually do the side effects of protection
      Returns:
      Whether or not the item is valid Apiarist Armor and should protect the player from that attack
      Since:
      Forestry 4.2
    • wearsItems

      int wearsItems(net.minecraft.world.entity.LivingEntity entity, @Nullable IBeeEffect cause, boolean doProtect)
      Called when the apiarist's armor acts as protection against an attack.
      Parameters:
      entity - Entity being attacked
      cause - Optional cause of attack, such as a bee effect identifier
      doProtect - Whether or not to actually do the side effects of protection
      Returns:
      The number of valid Apiarist Armor pieces the player is wearing that are actually protecting. 4 means full protection, but it can go higher if they are holding items like the smoker.
      Since:
      Forestry 4.2