Class BellMock

All Implemented Interfaces:
PersistentDataViewHolder, Bell, BlockState, TileState, Metadatable, PersistentDataHolder

public class BellMock extends TileStateMock implements Bell
Mock implementation of a Bell.
See Also:
  • Constructor Details

    • BellMock

      public BellMock(@NotNull @NotNull Material material)
      Constructs a new BellMock for the provided Material. Only supports Material.BELL
      Parameters:
      material - The material this state is for.
    • BellMock

      protected BellMock(@NotNull @NotNull Block block)
      Constructs a new BellMock for the provided Block. Only supports Material.BELL
      Parameters:
      block - The block this state is for.
    • BellMock

      protected BellMock(@NotNull @NotNull BellMock state)
      Constructs a new BellMock by cloning the data from an existing one.
      Parameters:
      state - The state to clone.
  • Method Details

    • getSnapshot

      @NotNull public @NotNull BlockState getSnapshot()
      Description copied from class: BlockStateMock
      This returns a copy of this BlockStateMock. Inheritents of this class should override this method!
      Specified by:
      getSnapshot in class TileStateMock
      Returns:
      A snapshot of this BlockStateMock.
    • ring

      public boolean ring(@Nullable @Nullable Entity entity, @Nullable @Nullable BlockFace direction)
      Specified by:
      ring in interface Bell
    • ring

      public boolean ring(@Nullable @Nullable Entity entity)
      Specified by:
      ring in interface Bell
    • ring

      public boolean ring(@Nullable @Nullable BlockFace direction)
      Specified by:
      ring in interface Bell
    • ring

      public boolean ring()
      Specified by:
      ring in interface Bell
    • isShaking

      public boolean isShaking()
      Specified by:
      isShaking in interface Bell
    • getShakingTicks

      public int getShakingTicks()
      Specified by:
      getShakingTicks in interface Bell
    • isResonating

      public boolean isResonating()
      Specified by:
      isResonating in interface Bell
    • getResonatingTicks

      public int getResonatingTicks()
      Specified by:
      getResonatingTicks in interface Bell