Enum Class ChallengeComponent

java.lang.Object
java.lang.Enum<ChallengeComponent>
dev.deepcore.challenge.ChallengeComponent
All Implemented Interfaces:
Serializable, Comparable<ChallengeComponent>, Constable

public enum ChallengeComponent extends Enum<ChallengeComponent>
Individual challenge mechanic toggles that can be enabled or disabled.
  • Enum Constant Details

    • KEEP_INVENTORY

      public static final ChallengeComponent KEEP_INVENTORY
      Keep inventory contents after player death.
    • HARDCORE

      public static final ChallengeComponent HARDCORE
      Enable hardcore life mode semantics.
    • HEALTH_REFILL

      public static final ChallengeComponent HEALTH_REFILL
      Allow natural health regeneration.
    • SHARED_INVENTORY

      public static final ChallengeComponent SHARED_INVENTORY
      Share inventory state across participants.
    • SHARED_HEALTH

      public static final ChallengeComponent SHARED_HEALTH
      Share health pool across participants.
    • INITIAL_HALF_HEART

      public static final ChallengeComponent INITIAL_HALF_HEART
      Start each life at half a heart.
    • DEGRADING_INVENTORY

      public static final ChallengeComponent DEGRADING_INVENTORY
      Shrink available inventory capacity over time.
  • Method Details

    • values

      public static ChallengeComponent[] 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 ChallengeComponent 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
    • key

      public String key()
    • displayName

      public String displayName()
    • fromKey

      public static Optional<ChallengeComponent> fromKey(String key)