Class VisualizerRegistry

java.lang.Object
dev.engine_room.flywheel.api.visualization.VisualizerRegistry

public final class VisualizerRegistry extends Object
The registry for Visualizers.
  • Method Summary

    Modifier and Type
    Method
    Description
    static <T extends net.minecraft.world.entity.Entity>
    @Nullable EntityVisualizer<? super T>
    getVisualizer(net.minecraft.world.entity.EntityType<T> type)
    Gets the visualizer for the given entity type, if one exists.
    static <T extends net.minecraft.world.level.block.entity.BlockEntity>
    @Nullable BlockEntityVisualizer<? super T>
    getVisualizer(net.minecraft.world.level.block.entity.BlockEntityType<T> type)
    Gets the visualizer for the given block entity type, if one exists.
    static <T extends net.minecraft.world.entity.Entity>
    void
    setVisualizer(net.minecraft.world.entity.EntityType<T> type, @Nullable EntityVisualizer<? super T> visualizer)
    Sets the visualizer for the given entity type.
    static <T extends net.minecraft.world.level.block.entity.BlockEntity>
    void
    setVisualizer(net.minecraft.world.level.block.entity.BlockEntityType<T> type, @Nullable BlockEntityVisualizer<? super T> visualizer)
    Sets the visualizer for the given block entity type.

    Methods inherited from class java.lang.Object

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

    • getVisualizer

      @Nullable public static <T extends net.minecraft.world.level.block.entity.BlockEntity> @Nullable BlockEntityVisualizer<? super T> getVisualizer(net.minecraft.world.level.block.entity.BlockEntityType<T> type)
      Gets the visualizer for the given block entity type, if one exists.
      Type Parameters:
      T - The type of the block entity.
      Parameters:
      type - The block entity type to get the visualizer for.
      Returns:
      The visualizer for the given block entity type, or null if none exists.
    • getVisualizer

      @Nullable public static <T extends net.minecraft.world.entity.Entity> @Nullable EntityVisualizer<? super T> getVisualizer(net.minecraft.world.entity.EntityType<T> type)
      Gets the visualizer for the given entity type, if one exists.
      Type Parameters:
      T - The type of the entity.
      Parameters:
      type - The entity type to get the visualizer for.
      Returns:
      The visualizer for the given entity type, or null if none exists.
    • setVisualizer

      public static <T extends net.minecraft.world.level.block.entity.BlockEntity> void setVisualizer(net.minecraft.world.level.block.entity.BlockEntityType<T> type, @Nullable @Nullable BlockEntityVisualizer<? super T> visualizer)
      Sets the visualizer for the given block entity type.
      Type Parameters:
      T - The type of the block entity.
      Parameters:
      type - The block entity type to set the visualizer for.
      visualizer - The visualizer to set.
    • setVisualizer

      public static <T extends net.minecraft.world.entity.Entity> void setVisualizer(net.minecraft.world.entity.EntityType<T> type, @Nullable @Nullable EntityVisualizer<? super T> visualizer)
      Sets the visualizer for the given entity type.
      Type Parameters:
      T - The type of the entity.
      Parameters:
      type - The entity type to set the visualizer for.
      visualizer - The visualizer to set.