public final class Resources
extends java.lang.Object
Resources class provides access to types of ResourcesContainers and is used by different (loading) mechanisms to make
resources available during runtime.
The LITIengine supports a variety of different resource types, including:
ResourcesContainer| Modifier and Type | Method and Description |
|---|---|
static Fonts |
fonts()
Gets the container that manages
Font resources. |
static Images |
images()
Gets the container that manages
BufferedImage resources. |
static void |
load(java.lang.String gameResourceFile)
Load
Spritesheets, Tilesets and Maps from a game resource file created with the utiLITI editor. |
static Maps |
maps()
Gets the container that manages
IMap resources. |
static Sounds |
sounds()
Gets the container that manages
Sound resources. |
static Spritesheets |
spritesheets()
Gets the container that manages
Spritesheet resources. |
static Strings |
strings()
Gets a container that manages
String resources.This instance can be used to access localizable string from a ".properties" file. |
static Tilesets |
tilesets()
Gets the container that manages
Tileset resources.This implementation uses raw Tilesets, to avoid problems with
Tileset methods that aren't in the ITileset interface. |
public static Fonts fonts()
Font resources.Fontpublic static Sounds sounds()
Sound resources.Soundpublic static Maps maps()
IMap resources.IMappublic static Tilesets tilesets()
Tileset resources.Tilesets, to avoid problems with
Tileset methods that aren't in the ITileset interface.Tilesetpublic static Strings strings()
String resources.public static Images images()
BufferedImage resources.BufferedImagepublic static Spritesheets spritesheets()
Spritesheet resources.Spritesheetpublic static void load(java.lang.String gameResourceFile)
Spritesheets, Tilesets and Maps from a game resource file created with the utiLITI editor.
After loading, these resources can be accessed via this API (e.g. Resources.maps().get("mapname").gameResourceFile - The file name of the game resource file