-
Notifications
You must be signed in to change notification settings - Fork 87
TiledSharp Class Overview
This is an overview of the classes and data types used by TiledSharp.
Map is an abstraction of a TMX file and its associated data. It contains basic information about the map, such as the map size (in tiles) or the tile size (in pixels). It also contains the principal TMX data elements (Tileset, Layer, MapObjectGroup, MapObject), which are organized into TiledLists.
Tileset objects contain data associated with tile appearance. Each tileset contains a reference to an image, which can be decomposed into a selection of individual tiles. The image reference can be either the name of an embedded resource or an explicit file path.
Layer objects describe the tile map as a list, where each element contains a global tile ID for each grid point. The order is sequential, rather than as a two-dimensional array, although each element also stores its own coordinates.
MapObjectGroup objects contain information about the Tiled "object layers". Object groups allow for organization of objects into separate layers.
MapObject objects contain detailed information about the various Tiled objects (Locations, Tiles, Polygons, Polylines). MapObject positions are in pixels, rather than tile position, since they are not constrained by the tile grid.
TiledList is a [KeyedCollection] which stores lists of the principal TiledSharp classes. TiledLists are accessible by either their names or by index.