TmxMapLoader,
AtlasTmxMapLoader, TmjMapLoader, or AtlasTmjMapLoader based solely on the map file's extension and
content. A primary use case is for projects that need to load a mix of TMX and TMJ maps (with or without atlases) using a
single loader instance inside an AssetManager. For TMX and TMJ files, this loader checks for the presence of an
"atlas" property. If found, it uses an atlas-based loader; otherwise, it falls back to the standard loader.
| Modifier and Type | Field and Description |
|---|---|
| private final AtlasTmjMapLoader | |
| private final AtlasTmxMapLoader | |
| private final JsonReader | |
| private final TmjMapLoader | |
| private final TmxMapLoader | |
| private final XmlReader |
| Access | Constructor and Description |
|---|---|
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| public Array | getDependencies(String fileName, FileHandle file, BaseTiledMapLoader.
Implements abstract com. Returns the assets this asset requires to be loaded first. |
| public TiledMap | |
| public TiledMap | Returns: a loadedTiledMappath to a .tmx or .tmj file fileName, BaseTiledMapLoader.existing Parameters object parameterUniversal synchronous loader with custom parameters. |
| public void | loadAsync(AssetManager manager, String fileName, FileHandle file, BaseTiledMapLoader.
Implements abstract com. Loads the non-OpenGL part of the asset and injects any dependencies of the asset into the AssetManager. |
| public TiledMap | loadSync(AssetManager manager, String fileName, FileHandle file, BaseTiledMapLoader.
Implements abstract com. Loads the OpenGL part of the asset. |
| private boolean |
| atlasTmjMapLoader | back to summary |
|---|---|
| private final AtlasTmjMapLoader atlasTmjMapLoader | |
| atlasTmxMapLoader | back to summary |
|---|---|
| private final AtlasTmxMapLoader atlasTmxMapLoader | |
| jsonReader | back to summary |
|---|---|
| private final JsonReader jsonReader | |
| tmjMapLoader | back to summary |
|---|---|
| private final TmjMapLoader tmjMapLoader | |
| tmxMapLoader | back to summary |
|---|---|
| private final TmxMapLoader tmxMapLoader | |
| xmlReader | back to summary |
|---|---|
| private final XmlReader xmlReader | |
| TiledMapLoader | back to summary |
|---|---|
| public TiledMapLoader() | |
| TiledMapLoader | back to summary |
|---|---|
| public TiledMapLoader(FileHandleResolver resolver) | |
| getDependencies | back to summary |
|---|---|
| public Array Implements abstract com. Doc from com. Returns the assets this asset requires to be loaded first. This method may be called on a thread other than the GL thread.
| |
| load | back to summary |
|---|---|
| public TiledMap load(String fileName) Universal synchronous loader. This method is a thin wrapper that picks the correct underlying loader (TMX vs TMJ, atlas vs
non‑atlas) and then delegates straight through to its synchronous
| |
| load | back to summary |
|---|---|
| public TiledMap load(String fileName, BaseTiledMapLoader. Universal synchronous loader with custom parameters. Resolves the file and Inspects the extension (tmx vs tmj). Check
whether the ‘atlas’ property exists in the map and delegates to the appropriate loader’s
| |
| loadAsync | back to summary |
|---|---|
| public void loadAsync(AssetManager manager, String fileName, FileHandle file, BaseTiledMapLoader. Implements abstract com. Doc from com. Loads the non-OpenGL part of the asset and injects any dependencies of the asset into the AssetManager.
| |
| loadSync | back to summary |
|---|---|
| public TiledMap loadSync(AssetManager manager, String fileName, FileHandle file, BaseTiledMapLoader. Implements abstract com. Doc from com. Loads the OpenGL part of the asset.
| |
| usesAtlas | back to summary |
|---|---|
| private boolean usesAtlas(FileHandle file) | |