Interface BlockSoundInteractionTranslator

All Superinterfaces:
SoundInteractionTranslator<BlockState>
All Known Implementing Classes:
BucketSoundInteractionTranslator, ButtonSoundInteractionTranslator, ComparatorSoundInteractionTranslator, FlintAndSteelInteractionTranslator, GrassPathInteractionTranslator, HoeInteractionTranslator, LeverSoundInteractionTranslator, OpenableSoundInteractionTranslator

public interface BlockSoundInteractionTranslator extends SoundInteractionTranslator<BlockState>
Sound interaction handler for when a block is right-clicked.
  • Method Details

    • handleBlockInteraction

      static void handleBlockInteraction(GeyserSession session, org.cloudburstmc.math.vector.Vector3f position, BlockState state)
      Handles the block interaction when a player right-clicks a block.
      Parameters:
      session - the session interacting with the block
      position - the position of the block
      state - the state of the block
    • canInteract

      static boolean canInteract(GeyserSession session, GeyserItemStack itemInHand, String blockIdentifier)
      Determines if the adventure gamemode would prevent this item from actually succeeding