Enum Class AugmentNumber

java.lang.Object
java.lang.Enum<AugmentNumber>
xericker.arenalegends.gameplay.augment.value.type.AugmentNumber
All Implemented Interfaces:
Serializable, Comparable<AugmentNumber>, Constable

public enum AugmentNumber extends Enum<AugmentNumber>
  • Enum Constant Details

    • MULTIPLY_BY_100

      public static final AugmentNumber MULTIPLY_BY_100
      Multiplies the value by 100. Examples: - 0.25 -> 25% - 0.5 -> 50% - 1.0 -> 100% - 1.5 -> 150%
    • KEEP_AS_IS

      public static final AugmentNumber KEEP_AS_IS
      Keeps the decimal value as is. Examples: - 25.5 -> 25.5% - 100.0 -> 100.0% - 0.5 -> 0.5% - 150.75 -> 150.75%
    • DECIMAL_TO_PERCENT

      public static final AugmentNumber DECIMAL_TO_PERCENT
      Gets decimal part only and converts to percent. Examples: - 1.25 -> 25% - 2.5 -> 50% - 3.75 -> 75% - 4.99 -> 99%
    • SCALE_TO_PERCENT

      public static final AugmentNumber SCALE_TO_PERCENT
      Converts value to percentage by dividing by 2. Examples: - 2.0 -> 100% - 1.0 -> 50% - 0.5 -> 25% - 3.0 -> 150%
    • CAPPED_PERCENT

      public static final AugmentNumber CAPPED_PERCENT
      Limits the percentage to 100% maximum. Examples: - 0.5 -> 50% - 1.0 -> 100% - 1.5 -> 100% - 2.0 -> 100%
  • Method Details

    • values

      public static AugmentNumber[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static AugmentNumber valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • calculateValue

      public abstract double calculateValue(double value)
      Calculates the modified value based on the enum type.
      Parameters:
      value - The input value to be modified.
      Returns:
      The calculated value.