Interface ClientScreenInputEvent.KeyReleased

Enclosing interface:
ClientScreenInputEvent

public static interface ClientScreenInputEvent.KeyReleased
  • Method Summary

    Modifier and Type
    Method
    Description
    net.minecraft.world.InteractionResult
    keyReleased(net.minecraft.client.Minecraft client, net.minecraft.client.gui.screens.Screen screen, int keyCode, int scanCode, int modifiers)
    Invoked whenever a held key is released inside a screen.
  • Method Details

    • keyReleased

      net.minecraft.world.InteractionResult keyReleased(net.minecraft.client.Minecraft client, net.minecraft.client.gui.screens.Screen screen, int keyCode, int scanCode, int modifiers)
      Invoked whenever a held key is released inside a screen. Equivalent to Forge's GuiScreenEvent.KeyboardKeyReleasedEvent event.

      This event is handled in two phases PRE and POST, which are invoked before and after the keys have been processed by the screen, respectively.

      Parameters:
      client - The Minecraft instance performing it.
      screen - The screen this keystroke was performed in.
      keyCode - The key code.
      scanCode - The raw keyboard scan code.
      modifiers - Additional modifiers.
      Returns:
      Any other result than InteractionResult.PASS leads to the cancellation of the key release.