Help Support the Baja Engine! Donate to Breezeway Studios!
lmtpacker

Search:

Purpose


The lmtpacker allows you to take a bunch of image files (tga/bmp) and pack them into a single lmt file. Typically, these files are used in menus. Because the files are packed, it is harder for others to steal your menu graphics.

Usage


Note: see Using The Command Line if you don't know how to use command line utilities.

Code

lmtpacker.exe lmtscript.txt


lmtscript.txt is a plain text file that lists the files that the packer needs to include.

Code


DEST:C:/gamebuild/

TARGET:menu/menu.lmt
menu/mybutton.tga
menu/slider.bmp

TARGET:menu/icons.lmt
menu/myicon.tga


"DEST:" specifies the root destination directory where the lmt files will be saves. By default (if DEST isn't specified) files are placed in with the working directory of the lmtpacker.exe as root. "TARGET:" specifies the name of the lmt file to build. The lines with the images are relative to the working directory of the exe.

To load a lmt file:

Code

texture.load('file.lmt')
obj.menubutton:load('test.tga') -- will load from file.lmt if it was included


As long as you used relative paths when you loaded the file directly, the engine will just find the file in the pack and use it. No changes will need to be made to your code. See texture for more information.