Interface SoundInteractionHandler<T>

Type Parameters:
T - the value
All Known Subinterfaces:
BlockSoundInteractionHandler, EntitySoundInteractionHandler
All Known Implementing Classes:
BucketSoundInteractionHandler, ComparatorSoundInteractionHandler, DoorSoundInteractionHandler, FeedBabySoundInteractionHandler, FlintAndSteelInteractionHandler, GrassPathInteractionHandler, HoeInteractionHandler, LeverSoundInteractionHandler, MilkEntitySoundInteractionHandler

public interface SoundInteractionHandler<T>
Handler for playing sounds when right-clicking various objects. Due to Minecraft: Bedrock Edition expecting interaction sounds to be played serverside and Minecraft: Java Edition handling them clientside, this had to be made to handle scenarios like that.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    handleInteraction​(GeyserSession session, com.nukkitx.math.vector.Vector3f position, T value)
    Handles the interaction when a player right-clicks a block.
  • Method Details

    • handleInteraction

      void handleInteraction(GeyserSession session, com.nukkitx.math.vector.Vector3f position, T value)
      Handles the interaction when a player right-clicks a block.
      Parameters:
      session - the session interacting with the block
      position - the position of the block
      value - the value