@mousepox/tiled
v0.1.2
Published
Tiled map editor helpers and TypeScript definitions.
Downloads
3
Readme
@mousepox/tiled
Tiled map editor helpers and TypeScript definitions.
Usage
import { ITiledObjectGroup, TiledMap } from "@mousepox/tiled";
// Create new TiledMap object from parsed Tiled JSON
const map = new TiledMap(parsedTiledJSON);
// Get an object group layer named "entities"
const entities = map.getLayerByName<ITiledObjectGroup>("entities");
// Get a custom map property
const foobar = map.getCustomPropertyValue<string>("foobar");