SpriteDecoration

open class SpriteDecoration @JvmOverloads constructor(tex: TextureSet, val w: Int = 16, val h: Int = 16) : SpriteDecorated

Implementation of a SpriteDecorated for rendering a TextureSet as a decoration

Author

fzzyhmstrs

Since

0.6.0

Parameters

w

Decoration height in pixels, default 16

h

Decoration width in pixels, default 16

Inheritors

Constructors

Link copied to clipboard
constructor(id: Identifier, w: Int = 16, h: Int = 16)

SpriteDecorated that uses one texture in all circumstances

constructor(tex: TextureSet, w: Int = 16, h: Int = 16)

Properties

Link copied to clipboard
open override val h: Int = 16
Link copied to clipboard
open override val w: Int = 16

Functions

Link copied to clipboard
open override fun renderDecoration(context: DrawContext, x: Int, y: Int, delta: Float, enabled: Boolean, selected: Boolean)

Renders the decoration. Notably, this provides active and selected context for rendering different things based on those states.

Link copied to clipboard
open override fun textureSet(): TextureSet

TextureSet this decoration will render from