Class BellVisual

java.lang.Object
com.jozufozu.flywheel.lib.visual.AbstractVisual
com.jozufozu.flywheel.lib.visual.AbstractBlockEntityVisual<net.minecraft.world.level.block.entity.BellBlockEntity>
com.jozufozu.flywheel.vanilla.BellVisual
All Implemented Interfaces:
BlockEntityVisual<net.minecraft.world.level.block.entity.BellBlockEntity>, DynamicVisual, LitVisual, Visual, SimpleDynamicVisual

public class BellVisual extends AbstractBlockEntityVisual<net.minecraft.world.level.block.entity.BellBlockEntity> implements SimpleDynamicVisual
  • Constructor Details

    • BellVisual

      public BellVisual(VisualizationContext ctx, net.minecraft.world.level.block.entity.BellBlockEntity blockEntity)
  • Method Details

    • init

      public void init(float partialTick)
      Description copied from interface: Visual
      Initialize instances here.

      This method will be called exactly once upon visual creation.

      Specified by:
      init in interface Visual
      Overrides:
      init in class AbstractBlockEntityVisual<net.minecraft.world.level.block.entity.BellBlockEntity>
    • beginFrame

      public void beginFrame(DynamicVisual.Context context)
      Description copied from interface: SimpleDynamicVisual
      Called every frame.
      The implementation is free to parallelize calls to this method. You must ensure proper synchronization if you need to mutate anything outside this visual.
      This method and SimpleTickableVisual.tick(com.jozufozu.flywheel.api.visual.TickableVisual.Context) will never be called simultaneously.
      Instancer/Instance creation/acquisition is safe here.
      Specified by:
      beginFrame in interface SimpleDynamicVisual
    • updateLight

      public void updateLight()
      Description copied from interface: LitVisual
      Called when a section this visual is contained in receives a light update.

      Even if multiple sections are updated at the same time, this method will only be called once.

      The implementation is free to parallelize calls to this method, as well as execute the plan returned by DynamicVisual.planFrame() simultaneously. It is safe to query/update light here, but you must ensure proper synchronization if you want to mutate anything outside this visual or anything that is also mutated within DynamicVisual.planFrame().

      Specified by:
      updateLight in interface LitVisual
    • collectCrumblingInstances

      public void collectCrumblingInstances(Consumer<Instance> consumer)
      Description copied from interface: BlockEntityVisual
      Collect all instances that should render with a crumbling overlay when the block corresponding to this visual is being broken.
      Passing null to the consumer has no effect.
      Specified by:
      collectCrumblingInstances in interface BlockEntityVisual<net.minecraft.world.level.block.entity.BellBlockEntity>
      Parameters:
      consumer - A consumer to provide instances to.
    • _delete

      protected void _delete()
      Specified by:
      _delete in class AbstractVisual