Class AstralActionFactory<T>

java.lang.Object
io.github.apace100.apoli.power.factory.action.ActionFactory<T>
dev.jaxydog.astral.content.power.AstralActionFactory<T>
All Implemented Interfaces:
Registered, io.github.apace100.apoli.power.factory.Factory

public class AstralActionFactory<T> extends io.github.apace100.apoli.power.factory.action.ActionFactory<T> implements Registered
An extension of an ActionFactory that provides additional functionality.
Since:
2.0.0
  • Nested Class Summary

    Nested classes/interfaces inherited from class io.github.apace100.apoli.power.factory.action.ActionFactory

    io.github.apace100.apoli.power.factory.action.ActionFactory.Instance

    Nested classes/interfaces inherited from interface dev.jaxydog.astral.register.Registered

    Registered.All, Registered.Client, Registered.Common, Registered.Generated, Registered.Server
  • Field Summary

    Fields inherited from class io.github.apace100.apoli.power.factory.action.ActionFactory

    data
  • Constructor Summary

    Constructors
    Constructor
    Description
    AstralActionFactory(String path, io.github.apace100.calio.data.SerializableData data, BiConsumer<io.github.apace100.calio.data.SerializableData.Instance,T> effect)
    Creates a new action factory.
  • Method Summary

    Modifier and Type
    Method
    Description
    net.minecraft.util.Identifier
    Returns this value's associated registry identifier.
    Returns this value's associated registry identifier path.
    void
    register(net.minecraft.registry.Registry<io.github.apace100.apoli.power.factory.action.ActionFactory<T>> registry)
    Registers this factory within the provided registry.

    Methods inherited from class io.github.apace100.apoli.power.factory.action.ActionFactory

    getSerializableData, getSerializerId, read, read

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • AstralActionFactory

      public AstralActionFactory(String path, io.github.apace100.calio.data.SerializableData data, BiConsumer<io.github.apace100.calio.data.SerializableData.Instance,T> effect)
      Creates a new action factory.
      Parameters:
      path - The factory's identifier path.
      data - The factory's serialization data.
      effect - The factory's executed action.
      Since:
      2.0.0
  • Method Details

    • register

      public void register(net.minecraft.registry.Registry<io.github.apace100.apoli.power.factory.action.ActionFactory<T>> registry)
      Registers this factory within the provided registry.
      Parameters:
      registry - The target registry.
      Since:
      2.0.0
    • getRegistryPath

      public String getRegistryPath()
      Description copied from interface: Registered
      Returns this value's associated registry identifier path.

      This is by default used to determine the Identifier provided by Registered.getRegistryId(). For example, returning "my_item" will cause the associated identifier to be astral:my_item.

      Specified by:
      getRegistryPath in interface Registered
      Returns:
      An identifier path.
    • getRegistryId

      public net.minecraft.util.Identifier getRegistryId()
      Description copied from interface: Registered
      Returns this value's associated registry identifier.

      This is used to uniquely distinguish this instance from other equally-typed instances.

      Specified by:
      getRegistryId in interface Registered
      Returns:
      A new identifier.