Function of Game
game.texture
Returns a new texture of width by height pixels, see-through until drawn on, for a pack's block or item. A texture to draw on (512 at most a side), or a PNG file in the pack (4096 at most a side).
game.texture((width: number, height: number) -> Texture) → & ((file: string) -> Texture)
Parameters
(widthnumber, height: number) -> TextureReturns
& ((file: string) -> Texture)Used in
local side = game.texture(16, 16)Custom blocks| `ui.image{}` | a picture | `image` (a `game.texture`), `color` (a tint) |Layoutspack, or a `game.texture`; `detail = 2` has four times the pixels. SetDialogsA `game.texture` in `kit.image` is pixel art: each pixel grows into aDialogs`fill` and `draw(picture, x, y)`: a `game.texture` over it, its corner3D modelstakes the second square of 128 from a PNG loaded with `game.texture`.3D modelslocal ingot = game.texture(16, 16) -- a picture drawn in code, or a PNG file in the packItemslocal t = game.texture(16, 16) -- see-through until drawn on, 512 at most a sideItems