Class DebugRendererRegistry

java.lang.Object
net.fabricmc.fabric.api.client.debug.v1.renderer.DebugRendererRegistry

public final class DebugRendererRegistry extends Object
Registry for custom debug renderers.
  • Constructor Details

    • DebugRendererRegistry

      public DebugRendererRegistry()
  • Method Details

    • register

      public static <T> void register(net.minecraft.util.debug.DebugSubscription<T> debugSubscription, DebugRendererFactory rendererFactory)
      Registers a debug renderer for the given DebugSubscription.
      Type Parameters:
      T - the inner type of the DebugSubscription.
      Parameters:
      debugSubscription - the DebugSubscription.
      rendererFactory - the factory/constructor for the debug renderer.
    • register

      public static <T> void register(net.minecraft.util.debug.DebugSubscription<T> debugSubscription, DebugRendererFactory rendererFactory, boolean isEnabledFlag)
      Registers a debug renderer for the given DebugSubscription if isEnabledFlag is true.
      Type Parameters:
      T - the inner type of the DebugSubscription.
      Parameters:
      debugSubscription - the DebugSubscription.
      rendererFactory - the factory/constructor for the debug renderer.
      isEnabledFlag - the flag determining whether to register this debug renderer.