Interface ICondition.IContext

All Known Implementing Classes:
ConditionContext
Enclosing interface:
ICondition

public static interface ICondition.IContext
  • Field Details

  • Method Details

    • isTagLoaded

      <T> boolean isTagLoaded(TagKey<T> key)
      Returns true if the requested tag is available. This method does not require that the loaded tag have any elements, only that it be present at all.
    • getTag

      default <T> Collection<Holder<T>> getTag(TagKey<T> key)
      Returns the contents of the requested tag as loaded from data packs, or an empty collection if the tag is not loaded. The returned holders are safe to inspect even though the tag has not yet been bound to its registry (i.e. Registry.PendingTags.apply() has not yet run).
    • registryAccess

      default RegistryAccess registryAccess()
      Provides access to the loaded registries if this context is used for a datapack reload.
      Returns:
      The RegistryAccess context for the currently active reload.
    • enabledFeatures

      default FeatureFlagSet enabledFeatures()