Package com.jozufozu.flywheel.lib.visual
Class SimpleBlockEntityVisualizer.Builder<T extends net.minecraft.world.level.block.entity.BlockEntity>
java.lang.Object
com.jozufozu.flywheel.lib.visual.SimpleBlockEntityVisualizer.Builder<T>
- Type Parameters:
T- The type of the block entity.
- Enclosing class:
- SimpleBlockEntityVisualizer<T extends net.minecraft.world.level.block.entity.BlockEntity>
public static class SimpleBlockEntityVisualizer.Builder<T extends net.minecraft.world.level.block.entity.BlockEntity>
extends Object
An object to configure the visualizer for a block entity.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected net.minecraft.world.level.block.entity.BlockEntityType<T>protected @Nullable SimpleBlockEntityVisualizer.Factory<T> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionapply()Constructs the block entity visualizer and sets it for the block entity type.factory(SimpleBlockEntityVisualizer.Factory<T> visualFactory) Sets the visual factory for the block entity.Sets a predicate to never skip rendering with the vanillaBlockEntityRenderer.skipVanillaRender(Predicate<T> skipVanillaRender) Sets a predicate to determine whether to skip rendering with the vanillaBlockEntityRenderer.
-
Field Details
-
type
protected net.minecraft.world.level.block.entity.BlockEntityType<T extends net.minecraft.world.level.block.entity.BlockEntity> type -
visualFactory
@Nullable protected @Nullable SimpleBlockEntityVisualizer.Factory<T extends net.minecraft.world.level.block.entity.BlockEntity> visualFactory -
skipVanillaRender
-
-
Constructor Details
-
Builder
-
-
Method Details
-
factory
public SimpleBlockEntityVisualizer.Builder<T> factory(SimpleBlockEntityVisualizer.Factory<T> visualFactory) Sets the visual factory for the block entity.- Parameters:
visualFactory- The visual factory.- Returns:
this
-
skipVanillaRender
Sets a predicate to determine whether to skip rendering with the vanillaBlockEntityRenderer.- Parameters:
skipVanillaRender- The predicate.- Returns:
this
-
neverSkipVanillaRender
Sets a predicate to never skip rendering with the vanillaBlockEntityRenderer.- Returns:
this
-
apply
Constructs the block entity visualizer and sets it for the block entity type.- Returns:
- The block entity visualizer.
-