Class StatType<T>

java.lang.Object
net.minecraft.stat.StatType<T>
All Implemented Interfaces:
Iterable<Stat<T>>

public class StatType<T>
extends Object
implements Iterable<Stat<T>>
  • Field Details

    • registry

      private final Registry<T> registry
    • stats

      private final Map<T,​Stat<T>> stats
    • field_26382

      @Environment(CLIENT) @Nullable private Text field_26382
  • Constructor Details

    • StatType

      public StatType​(Registry<T> registry)
  • Method Details

    • hasStat

      @Environment(CLIENT) public boolean hasStat​(T key)
    • getOrCreateStat

      public Stat<T> getOrCreateStat​(T key, StatFormatter formatter)
    • getRegistry

      public Registry<T> getRegistry()
    • iterator

      public Iterator<Stat<T>> iterator()
      Specified by:
      iterator in interface Iterable<T>
    • getOrCreateStat

      public Stat<T> getOrCreateStat​(T key)
    • getTranslationKey

      @Environment(CLIENT) public String getTranslationKey()
    • method_30739

      @Environment(CLIENT) public Text method_30739()