パッケージ model.type

列挙クラス Element

すべての実装されたインタフェース:
Serializable, Comparable<Element>, Constable

public enum Element extends Enum<Element>
Enumeration of the seven playable elements plus Physical damage in Genshin Impact.

Each constant carries a reference to the corresponding StatType DMG_BONUS key so that damage calculators and resistance lookups can retrieve the correct stat without string-based dispatch.

The same StatType key is used both for the character's elemental DMG Bonus% and for the enemy's resistance entry in Enemy.getRes(StatType).

  • 列挙型定数の詳細

  • メソッドの詳細

    • values

      public static Element[] values()
      この列挙クラスの定数を含む配列を宣言されている順序で 返します。
      戻り値:
      この列挙クラスの定数を宣言されている順序で含む配列
    • valueOf

      public static Element valueOf(String name)
      このクラスの列挙型定数を指定した名前で返します。 文字列は、このクラスの列挙型定数の宣言に使用された識別子と正確に 一致する必要があります。(余分な空白文字は使用 できません。)
      パラメータ:
      name - 返される列挙型定数の名前。
      戻り値:
      指定した名前の列挙型定数
      例外:
      IllegalArgumentException - この列挙クラスに、指定した名前の定数がない場合
      NullPointerException - 引数がnullの場合
    • getBonusStatType

      public StatType getBonusStatType()
      Returns the StatType DMG_BONUS key associated with this element. Used to look up both the attacker's elemental DMG Bonus% and the enemy's corresponding resistance value.
      戻り値:
      associated DMG Bonus stat type