Table of Contents

Class TMXLoader

Namespace
PopcorningGuineaPig.Engine.Gameplay
Assembly
PopcorningGuineaPig.Engine.dll

Utility class for loading TMX (Tiled Map eXchange) files. Supports Base64 uncompressed and CSV tile data formats.

public static class TMXLoader
Inheritance
TMXLoader
Inherited Members

Methods

LoadFromFile(string, string)

Loads a tilemap from a TMX file.

public static Tilemap LoadFromFile(string tmxFilePath, string baseAssetPath = "")

Parameters

tmxFilePath string

Path to the TMX file

baseAssetPath string

Base path for resolving relative asset paths

Returns

Tilemap

Loaded tilemap

Exceptions

FileNotFoundException

TMX file not found

InvalidDataException

Invalid TMX format

LoadFromString(string, string)

Loads a tilemap from TMX content string.

public static Tilemap LoadFromString(string tmxContent, string baseAssetPath = "")

Parameters

tmxContent string

TMX file content

baseAssetPath string

Base path for resolving relative asset paths

Returns

Tilemap

Loaded tilemap