ResourceTexture
The ResourceTexture
class extends TransformTexture
to render textures based on a resource location. It supports configurable offsets, dimensions, and color overlays.
Basic Properties
Field | Description |
---|---|
imageLocation | The resource location of the texture image |
offsetX | Horizontal offset of the texture (default is 0) |
offsetY | Vertical offset of the texture (default is 0) |
imageWidth | Width factor of the texture (default is 1) |
imageHeight | Height factor of the texture (default is 1) |
color | Color overlay applied to the texture (default is -1) |
APIs
createTexture
Create a texture from a resource location.
getSubTexture
Returns a sub-texture of the current texture.