java.lang.Object
net.storm.api.movement.pathfinder.model.requirement.charges.ItemChargeRequirement
Direct Known Subclasses:
ChargeRequirement, UnlockRequirement

public abstract class ItemChargeRequirement extends Object
Abstract base class for item charge tracking requirements.

ItemChargeRequirement provides the foundation for tracking items that have limited uses or charges. This base class stores common properties shared by both ChargeRequirement (numeric charges) and UnlockRequirement (boolean unlock states).

Common Properties

  • id - Unique identifier for this charge requirement
  • itemIds - Array of item IDs that this requirement applies to
  • chatTriggers - Regex patterns to detect charge changes from chat messages

Subclasses

Chat Triggers

Chat triggers allow the system to detect charge changes from game messages. For example, when a Ring of Dueling is used, the game displays remaining charges which can be captured via regex patterns.

See Also:
  • Field Details

    • id

      protected final String id
      Unique identifier for this charge requirement (e.g., "ring_of_dueling").
    • itemIds

      protected final int[] itemIds
      Array of item IDs that this charge tracking applies to.
    • chatTriggers

      protected final List<Pattern> chatTriggers
      Regex patterns for detecting charge changes from game chat messages.
  • Constructor Details

    • ItemChargeRequirement

      protected ItemChargeRequirement(String id, int[] itemIds, List<Pattern> chatTriggers)
      Creates a new item charge requirement.
      Parameters:
      id - unique identifier for this requirement
      itemIds - array of applicable item IDs
      chatTriggers - regex patterns for detecting charge messages