[{"name":"Tiled","comment":" Use the [`decode`](#decode) to get [`Level`](Tiled-Level)\n\n\n# Default Decoding\n\n@docs decode, encode\n\n\n# Helpers\n\n@docs gidInfo, GidInfo\n\n","unions":[],"aliases":[{"name":"GidInfo","comment":" ","args":[],"type":"{ gid : Basics.Int, fh : Basics.Bool, fv : Basics.Bool, fd : Basics.Bool }"}],"values":[{"name":"decode","comment":" Alias to [`Level.decode`](Tiled.Level#decode)\n","type":"Json.Decode.Decoder Tiled.Level.Level"},{"name":"encode","comment":" Alias to [`Level.encode`](Tiled.Level#encode)\n","type":"Tiled.Level.Level -> Json.Decode.Value"},{"name":"gidInfo","comment":" The highest three bits of the `gid` store the flipped states. Bit 32 is used for storing whether the tile is horizontally flipped, bit 31 is used for the vertically flipped tiles and bit 30 indicates whether the tile is flipped (anti) diagonally, enabling tile rotation. These bits have to be read and cleared before you can find out which tileset a tile belongs to.\n","type":"Basics.Int -> Tiled.GidInfo"}],"binops":[]},{"name":"Tiled.Layer","comment":"\n\n@docs Layer, decode, encode\n@docs TileData, ImageData, ObjectData, DrawOrder, Chunk, TileChunkedData\n\n\n# Internal\n\n@docs decodeDraworder, encodeDraworder\n\n","unions":[{"name":"DrawOrder","comment":" ","args":[],"cases":[["TopDown",[]],["Index",[]]]},{"name":"Layer","comment":" ","args":[],"cases":[["Image",["Tiled.Layer.ImageData"]],["Object",["Tiled.Layer.ObjectData"]],["Tile",["Tiled.Layer.TileData"]],["InfiniteTile",["Tiled.Layer.TileChunkedData"]]]}],"aliases":[{"name":"Chunk","comment":"\n\n  - `data` array or string Array of unsigned int (GIDs) or base64-encoded data\n  - `height` int Height in tiles\n  - `width` int Width in tiles\n  - `x` int X coordinate in tiles\n  - `y` int Y coordinate in tiles\n\n","args":[],"type":"{ data : List.List Basics.Int, height : Basics.Int, width : Basics.Int, x : Basics.Int, y : Basics.Int }"},{"name":"ImageData","comment":"\n\n  - `image` - Image used as background\n  - `name` Name assigned to this layer\n  - `x` Horizontal layer offset in tiles. Always 0.\n  - `y` Vertical layer offset in tiles. Always 0.\n  - `opacity` Value between 0 and 1\n  - `properties` A list of properties (name, value, type).\n  - `visible` Whether layer is shown or hidden in editor\n\n","args":[],"type":"{ id : Basics.Int, image : String.String, name : String.String, opacity : Basics.Float, visible : Basics.Bool, x : Basics.Float, y : Basics.Float, transparentcolor : String.String, properties : Tiled.Properties.Properties }"},{"name":"ObjectData","comment":"\n\n  - `name` Name assigned to this layer\n  - `x` Horizontal layer offset in tiles. Always 0.\n  - `y` Vertical layer offset in tiles. Always 0.\n  - `draworder` [`TopDown`](Tiled.Layer#DrawOrder) (default)\n  - `objects` List of objects. objectgroup only.\n  - `opacity` Value between 0 and 1\n  - `properties` A list of properties (name, value, type).\n  - `visible` Whether layer is shown or hidden in editor\n\n","args":[],"type":"{ id : Basics.Int, draworder : Tiled.Layer.DrawOrder, name : String.String, objects : List.List Tiled.Object.Object, opacity : Basics.Float, visible : Basics.Bool, x : Basics.Float, y : Basics.Float, color : String.String, properties : Tiled.Properties.Properties }"},{"name":"TileChunkedData","comment":" ","args":[],"type":"{ id : Basics.Int, chunks : List.List Tiled.Layer.Chunk, name : String.String, opacity : Basics.Float, visible : Basics.Bool, width : Basics.Int, height : Basics.Int, startx : Basics.Int, starty : Basics.Int, x : Basics.Float, y : Basics.Float, properties : Tiled.Properties.Properties }"},{"name":"TileData","comment":"\n\n  - `data` List of GIDs from [`Tileset`](Tiled.Tileset#Tileset).\n  - `name` Name assigned to this layer\n  - `x` Horizontal layer offset in tiles. Always 0.\n  - `y` Vertical layer offset in tiles. Always 0.\n  - `width` Column count. Same as map width for fixed-size maps.\n  - `height` Row count. Same as map height for fixed-size maps.\n  - `opacity` Value between 0 and 1\n  - `properties` A list of properties (name, value, type).\n  - `visible` Whether layer is shown or hidden in editor\n\n","args":[],"type":"{ id : Basics.Int, data : List.List Basics.Int, name : String.String, opacity : Basics.Float, visible : Basics.Bool, width : Basics.Int, height : Basics.Int, x : Basics.Float, y : Basics.Float, properties : Tiled.Properties.Properties }"}],"values":[{"name":"decode","comment":" ","type":"Json.Decode.Decoder Tiled.Layer.Layer"},{"name":"decodeDraworder","comment":" ","type":"Json.Decode.Decoder Tiled.Layer.DrawOrder"},{"name":"encode","comment":" ","type":"Tiled.Layer.Layer -> Json.Encode.Value"},{"name":"encodeDraworder","comment":" ","type":"Tiled.Layer.DrawOrder -> Json.Encode.Value"}],"binops":[]},{"name":"Tiled.Level","comment":"\n\n@docs Level\n@docs decode, encode\n\n\n# Level Data\n\n@docs LevelData, StaggeredLevelData, ExtensibleLevelData\n\n","unions":[{"name":"Level","comment":" Tiled can export maps as JSON files. That is elm representation of that structure.\n","args":[],"cases":[["Orthogonal",["Tiled.Level.LevelData"]],["Isometric",["Tiled.Level.LevelData"]],["Staggered",["Tiled.Level.StaggeredLevelData"]],["Hexagonal",["Tiled.Level.StaggeredLevelData"]]]}],"aliases":[{"name":"ExtensibleLevelData","comment":" ","args":["addition"],"type":"{ addition | backgroundcolor : String.String, height : Basics.Int, infinite : Basics.Bool, layers : List.List Tiled.Layer.Layer, nextobjectid : Basics.Int, renderorder : Tiled.Level.RenderOrder, tiledversion : String.String, tileheight : Basics.Int, tilesets : List.List Tiled.Tileset.Tileset, tilewidth : Basics.Int, version : Basics.Float, width : Basics.Int, properties : Tiled.Properties.Properties }"},{"name":"LevelData","comment":" ","args":[],"type":"Tiled.Level.ExtensibleLevelData {}"},{"name":"StaggeredLevelData","comment":" ","args":[],"type":"Tiled.Level.ExtensibleLevelData { hexsidelength : Basics.Int, staggeraxis : Tiled.Level.Axis, staggerindex : Tiled.Level.OddOrEven }"}],"values":[{"name":"decode","comment":" ","type":"Json.Decode.Decoder Tiled.Level.Level"},{"name":"encode","comment":" ","type":"Tiled.Level.Level -> Json.Encode.Value"}],"binops":[]},{"name":"Tiled.Object","comment":"\n\n@docs Object, decode, encode\n@docs CommonDimension, CommonDimensionGid, CommonDimensionPolyPoints\n@docs Common, Dimension, Gid, PolyPoints\n\n","unions":[{"name":"Object","comment":" ","args":[],"cases":[["Point",["Tiled.Object.Common {}"]],["Rectangle",["Tiled.Object.CommonDimension"]],["Ellipse",["Tiled.Object.CommonDimension"]],["Polygon",["Tiled.Object.CommonDimensionPolyPoints"]],["PolyLine",["Tiled.Object.CommonDimensionPolyPoints"]],["Tile",["Tiled.Object.CommonDimensionGid"]]]}],"aliases":[{"name":"Common","comment":" Do i really need ID here?\n","args":["a"],"type":"{ a | id : Basics.Int, name : String.String, kind : String.String, visible : Basics.Bool, x : Basics.Float, y : Basics.Float, rotation : Basics.Float, properties : Tiled.Properties.Properties }"},{"name":"CommonDimension","comment":" ","args":[],"type":"Tiled.Object.Common (Tiled.Object.Dimension {})"},{"name":"CommonDimensionGid","comment":" ","args":[],"type":"Tiled.Object.Common (Tiled.Object.Dimension { gid : Tiled.Object.Gid })"},{"name":"CommonDimensionPolyPoints","comment":" ","args":[],"type":"Tiled.Object.Common (Tiled.Object.Dimension { points : List.List { x : Basics.Float, y : Basics.Float } })"},{"name":"Dimension","comment":" ","args":["a"],"type":"{ a | width : Basics.Float, height : Basics.Float }"},{"name":"Gid","comment":" ","args":[],"type":"Basics.Int"},{"name":"PolyPoints","comment":" ","args":[],"type":"List.List { x : Basics.Float, y : Basics.Float }"}],"values":[{"name":"decode","comment":" ","type":"Json.Decode.Decoder Tiled.Object.Object"},{"name":"encode","comment":" ","type":"Tiled.Object.Object -> Json.Encode.Value"}],"binops":[]},{"name":"Tiled.Properties","comment":"\n\n@docs Properties, Property\n@docs decode, encode\n\n","unions":[{"name":"Property","comment":" Custom properties values\n","args":[],"cases":[["PropBool",["Basics.Bool"]],["PropInt",["Basics.Int"]],["PropFloat",["Basics.Float"]],["PropString",["String.String"]],["PropColor",["String.String"]],["PropFile",["String.String"]]]}],"aliases":[{"name":"Properties","comment":" ","args":[],"type":"Dict.Dict String.String Tiled.Properties.Property"}],"values":[{"name":"decode","comment":" ","type":"Json.Decode.Decoder Tiled.Properties.Properties"},{"name":"encode","comment":" ","type":"Tiled.Properties.Properties -> Json.Encode.Value"}],"binops":[]},{"name":"Tiled.Tileset","comment":"\n\n@docs Tileset, decode, encode\n@docs SourceTileData, EmbeddedTileData, ImageCollectionTileData\n@docs TilesData, ImageCollectionTileDataTile, TilesDataObjectgroup, SpriteAnimation\n\n\n## Decode tileset from file\n\n@docs decodeFile\n\n\n## Internal stuff\n\n@docs GridData\n\n\n## stuff to delete\n\n@docs decodeTilesData, encodeTilesData\n\n","unions":[{"name":"Tileset","comment":" ","args":[],"cases":[["Source",["Tiled.Tileset.SourceTileData"]],["Embedded",["Tiled.Tileset.EmbeddedTileData"]],["ImageCollection",["Tiled.Tileset.ImageCollectionTileData"]]]}],"aliases":[{"name":"EmbeddedTileData","comment":"\n\n  - `columns` The number of tile columns in the tileset\n  - `firstgid` GID corresponding to the first tile in the set\n  - `image` Image used for tiles in this set\n  - `imagewidth` Width of source image in pixels\n  - `imageheight` Height of source image in pixels\n  - `margin` Buffer between image edge and first tile (pixels)\n  - `name` Name given to this tileset\n  - `spacing` Spacing between adjacent tiles in image (pixels)\n  - `tilecount` The number of tiles in this tileset\n  - `tileheight` Maximum height of tiles in this set\n  - `tiles` Dict of TilesData [`TilesData`](#TilesData)\n  - `tilewidth` Maximum width of tiles in this set\n  - `properties` A list of properties (name, value, type).\n\n","args":[],"type":"{ columns : Basics.Int, firstgid : Basics.Int, image : String.String, imageheight : Basics.Int, imagewidth : Basics.Int, margin : Basics.Int, name : String.String, spacing : Basics.Int, tilecount : Basics.Int, tileheight : Basics.Int, tilewidth : Basics.Int, transparentcolor : String.String, tiles : Dict.Dict Basics.Int Tiled.Tileset.TilesData, properties : Tiled.Properties.Properties }"},{"name":"GridData","comment":" ","args":[],"type":"{ height : Basics.Int, orientation : String.String, width : Basics.Int }"},{"name":"ImageCollectionTileData","comment":"\n\n  - `columns` The number of tile columns in the tileset\n  - `firstgid` GID corresponding to the first tile in the set\n  - `margin` Buffer between image edge and first tile (pixels)\n  - `name` Name given to this tileset\n  - `spacing` Spacing between adjacent tiles in image (pixels)\n  - `tilecount` The number of tiles in this tileset\n  - `tileheight` Maximum height of tiles in this set\n  - `tiles` Dict of [`ImageCollectionTileDataTile`](#ImageCollectionTileDataTile)\n  - `tilewidth` Maximum width of tiles in this set\n  - `properties` A list of properties (name, value, type).\n\n","args":[],"type":"{ columns : Basics.Int, firstgid : Basics.Int, margin : Basics.Int, name : String.String, spacing : Basics.Int, tilecount : Basics.Int, tilewidth : Basics.Int, tileheight : Basics.Int, tiles : Dict.Dict Basics.Int Tiled.Tileset.ImageCollectionTileDataTile, properties : Tiled.Properties.Properties, grid : Maybe.Maybe Tiled.Tileset.GridData }"},{"name":"ImageCollectionTileDataTile","comment":" ","args":[],"type":"Tiled.Tileset.TilesDataPlain { image : String.String, imageheight : Basics.Int, imagewidth : Basics.Int }"},{"name":"SourceTileData","comment":"\n\n  - `firstgid` GID corresponding to the first tile in the set\n  - `source` url to `EmbeddedTileData`\n\n","args":[],"type":"{ firstgid : Basics.Int, source : String.String }"},{"name":"SpriteAnimation","comment":" ","args":[],"type":"{ duration : Basics.Int, tileid : Basics.Int }"},{"name":"TilesData","comment":" ","args":[],"type":"Tiled.Tileset.TilesDataPlain {}"},{"name":"TilesDataObjectgroup","comment":" ","args":[],"type":"{ draworder : Tiled.Layer.DrawOrder, name : String.String, objects : List.List Tiled.Object.Object, opacity : Basics.Int, visible : Basics.Bool, x : Basics.Int, y : Basics.Int }"}],"values":[{"name":"decode","comment":" ","type":"Json.Decode.Decoder Tiled.Tileset.Tileset"},{"name":"decodeFile","comment":" ","type":"Basics.Int -> Json.Decode.Decoder Tiled.Tileset.Tileset"},{"name":"decodeTilesData","comment":" ","type":"Json.Decode.Decoder (Maybe.Maybe (Tiled.Tileset.TilesDataPlain { id : Basics.Int }))"},{"name":"encode","comment":" ","type":"Tiled.Tileset.Tileset -> Json.Encode.Value"},{"name":"encodeTilesData","comment":" ","type":"( Basics.Int, Tiled.Tileset.TilesDataPlain a ) -> Json.Encode.Value"}],"binops":[]}]