Class ItemUseSupport

java.lang.Object
dev.rono.igniscore.api.strategy.ItemUseSupport

public final class ItemUseSupport extends Object
Default item interaction resolution from YAML behavior sections.

Extensions implement OnItemClickListener for custom behavior; use this helper when composing behavior tokens with extension logic outside the default interface routing.

  • Method Details

    • actionFor

      public static Optional<String> actionFor(ItemDefinition definition, IgnisInteraction interaction)
      Returns the configured behavior action token for a player interaction, if any.
      Parameters:
      definition - item definition carrying behavior config
      interaction - player interaction type
      Returns:
      normalized action token, or empty when unset or none
    • triggers

      public static boolean triggers(ItemDefinition definition, IgnisInteraction interaction)
      Returns true when the interaction has a configured non-empty action token.