Interface ShieldDamageReduction.MultiplyAdd

Enclosing interface:
ShieldDamageReduction<T>

public static interface ShieldDamageReduction.MultiplyAdd
The final amount of blocked damage will be constantReduction + fractionalReduction * damage
  • Method Details

    • builder

    • damageTypes

      Optional<Set<DamageType>> damageTypes()
      Returns the damage types this reduction applies to. Optional.empty() means this reduction is not restricted to any given damage type.
      Returns:
      the affected damage types
    • horizontalBlockingAngle

      double horizontalBlockingAngle()
      Returns the maximum angle between the users facing direction and the direction of the incoming attack.
      Returns:
      the maximum angle
    • constantReduction

      double constantReduction()
      Returns the constant amount of damage to be blocked.
      Returns:
      a constant amount of damage to block
    • fractionalReduction

      double fractionalReduction()
      Returns fractional amount of damage to block, where a factor of 1 means that all damage is blocked, and a factor of 0 that no damage is blocked.
      Returns:
      fractional amount of damage to block