Class EnchantmentCoreEntities

java.lang.Object
johnsmith.enchantmentcore.api.registry.EnchantmentCoreEntities

public class EnchantmentCoreEntities extends Object
Defines custom entity types utilized by the Enchantment Core library.

Defers EntityType.Builder.build(net.minecraft.resources.ResourceKey) execution via suppliers so that BuiltInRegistries.ENTITY_TYPE.createIntrusiveHolder is only invoked when the entity registry is unfrozen during loader registration events.

  • Field Details

    • SPELL_FIELD_ANCHOR

      public static net.minecraft.world.entity.EntityType<SpellFieldAnchorEntity> SPELL_FIELD_ANCHOR
      The entity type definition for the spell field anchor. Acts as an invisible, marker-based origin point for delayed or persistent spatial spell effects. Populated when the entity type is built during registration.
  • Constructor Details

    • EnchantmentCoreEntities

      public EnchantmentCoreEntities()
  • Method Details

    • getEntities

      public static Map<String,Supplier<net.minecraft.world.entity.EntityType<?>>> getEntities()
      Retrieves an unmodifiable view of all defined entity type suppliers keyed by their path identifier.
      Returns:
      The map of entity type suppliers to register.
    • initialize

      public static void initialize()
      Triggers static initialization of entity type definitions.