Files
Basalt/docs/docs1_6/objects/Image.md
Robert Jelic d4c72514ef Docs 1.6
Accidentally uploaded outdated 1.6 docs
2023-05-01 16:28:46 +02:00

1.3 KiB

The image object is for adding more advanced backgrounds to your interface. It supports the loading of .nfp and .bimg images.

Object methods also apply for images.

loadImage Loads an image from the specified file path
setImage Set's a new image
usePalette Changes the used palette to the image prefered palette
play Plays an animated image
selectFrame Selects a specific frame in an animated image
getMetadata Returns the metadata of the image
getImageSize Returns the width and height of the image
resizeImage Resizes the image to the specified dimensions

About Bimg

Bimg is a custom image format that can be used in place of .nfp, it is a table which can store multiple frames and metadata. The frames can store text, background and foreground, which makes it possible to create any image you'd like. The image format is made by people from the Minecraft Computercraft Mods - Discord. Here's a Github page which explains how the Bimg format works: bimg