renderBackground

open fun renderBackground(context: DrawContext, x: Int, y: Int, width: Int, height: Int, mouseX: Int, mouseY: Int, delta: Float)

Custom background rendering for the widget. By default, will render the standard MC button texture set.

Author

fzzyhmstrs

Since

0.6.0

Parameters

context

DrawContext

x

X position for rendering. This is not necessarily the widgets x position.

y

Y position for rendering. This is not necessarily the widgets y position.

width

render width. Not necessarily widget width. If you modify x, it's recommended to counter-modify this to keep rendered space consistent with the foreground as applicable

height

render height. Not necessarily widget height. If you modify y, it's recommended to counter-modify this to keep rendered space consistent with the foreground as applicable

mouseX

current horizontal screen position of the mouse

mouseY

current vertical screen position of the mouse

delta

screen frame delta