Class ScreenEvent.MouseScrolled

java.lang.Object
net.neoforged.bus.api.Event
Direct Known Subclasses:
ScreenEvent.MouseScrolled.Post, ScreenEvent.MouseScrolled.Pre
Enclosing class:
ScreenEvent

public abstract static class ScreenEvent.MouseScrolled extends ScreenEvent.MouseInput
Fired when the mouse was dragged while a button is being held down. See the two subclasses for listening before and after the normal handling.
See Also:
  • Field Details

    • scrollDeltaX

      private final double scrollDeltaX
    • scrollDeltaY

      private final double scrollDeltaY
  • Constructor Details

    • MouseScrolled

      @Internal public MouseScrolled(Screen screen, double mouseX, double mouseY, double scrollDeltaX, double scrollDeltaY)
  • Method Details

    • getScrollDeltaX

      public double getScrollDeltaX()
      Returns the amount of change / delta of the mouse scroll on the X axis.
      Returns:
      the amount of change / delta of the mouse scroll on the X axis
    • getScrollDeltaY

      public double getScrollDeltaY()
      Returns the amount of change / delta of the mouse scroll on the Y axis.
      Returns:
      the amount of change / delta of the mouse scroll on the Y axis