GuiTextureAlignment

Generates offsets for gui textures.

Inheritors

Types

Link copied to clipboard
object Companion
Link copied to clipboard
class Custom(offset: Vector2ic) : GuiTextureAlignment

A custom alignment with a fixed offset.

Link copied to clipboard
class HorizontallyCentered(baseOffset: Vector2ic = CHEST_OFFSET, baseWidth: Int = CHEST_WIDTH, yOffset: Int = 0) : GuiTextureAlignment

A horizontally centered alignment for gui textures, using baseOffset based on the menu type and yOffset for an additional vertical offset.

Link copied to clipboard
class TopLeft(baseOffset: Vector2ic = CHEST_OFFSET, extraOffset: Vector2ic = Vector2i(0, 0)) : GuiTextureAlignment

Aligns the gui texture to the top left corner of the menu, using baseOffset based on the menu type and extraOffset for an additional custom offset.

Functions

Link copied to clipboard
abstract fun getOffset(width: Int, height: Int): Vector2ic

Returns the offset based on the width and height of the gui texture.