Annotation Interface RequirementName


@Retention(RUNTIME) @Target(TYPE) @Inherited public @interface RequirementName
Annotation that assigns a unique name to a Requirement implementation.

The value() is used as the lookup key when skilltree JSON files reference a requirement by name. The optional translationNode() allows the requirement name to be localized for display in player-facing UIs.

This annotation is inherited, so subclasses of annotated requirement classes will share the same name unless they override it with their own annotation.

  • Required Element Summary

    Required Elements
    Modifier and Type
    Required Element
    Description
    The unique identifier for this requirement (used in .st.json files).
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    Optional translation node for localizing the requirement name in player UIs.
  • Element Details

    • value

      String value
      The unique identifier for this requirement (used in .st.json files).
      Returns:
      the requirement's config-facing name
    • translationNode

      String translationNode
      Optional translation node for localizing the requirement name in player UIs.
      Returns:
      the translation node, or an empty string when there is none
      Default:
      ""