{"id":16102149,"url":"https://github.com/layoric/dtiled","last_synced_at":"2025-10-07T15:48:58.182Z","repository":{"id":12366749,"uuid":"15016998","full_name":"Layoric/DTiled","owner":"Layoric","description":"A Dart package that renders Tiled maps and integrates with TiledStack services","archived":false,"fork":false,"pushed_at":"2013-12-08T11:23:26.000Z","size":160,"stargazers_count":1,"open_issues_count":2,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-09-11T08:07:24.945Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Layoric.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-12-08T02:38:45.000Z","updated_at":"2019-02-14T16:16:33.000Z","dependencies_parsed_at":"2022-08-29T02:40:41.543Z","dependency_job_id":null,"html_url":"https://github.com/Layoric/DTiled","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Layoric/DTiled","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Layoric%2FDTiled","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Layoric%2FDTiled/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Layoric%2FDTiled/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Layoric%2FDTiled/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Layoric","download_url":"https://codeload.github.com/Layoric/DTiled/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Layoric%2FDTiled/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278802800,"owners_count":26048566,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-07T02:00:06.786Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-09T18:52:27.587Z","updated_at":"2025-10-07T15:48:58.140Z","avatar_url":"https://github.com/Layoric.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"DTiled\n======\n\nA Dart package that renders Tiled maps and integrates with TiledStack services\n\n0.0.x only supports the JSON map format and currently only renders Isometric maps. TMX and Orthogonal support coming.\n\nBasics.\n\nSetup TilesetProvider and DTiledLoader. A 'TiledsetProvider' is a class which providers logic to get a tileset image.\nA DTiledLoader converts from a simple Dto to the main data structure used for renderering. This is based on 'XTiled' by ViNull.\n\n```\n...\n  gameLoop.start();\n  query('#canvas').nodes.add(canvas);\n  context2d = canvas.getContext('2d');\n  // TiledStack tileset provider is for use with TiledStack API. 'LocalTilesetProvider' for alternate path to textures\n  tileProvider = new TiledStackTilesetProvider(baseAddress);\n  tiledLoader = new DTiledLoader(tileProvider);\n...\n\n```\n\nOnce the JSON map is loaded, other parts need to be initialised. \n\n```\n...\n  // a Dart 'Map'\n  Map response = JSON.decode(r.responseText); \n  //populate simple Dto\n  MapDto mapDto = new MapDto(response); \n  currentMapDto = mapDto;\n  // Parse simple Dto\n  currentMap = xTiledLoader.LoadMap(currentMapDto); \n  // Create render region for camera\n  renderRegion = new Rect(canvas.clientLeft,canvas.clientTop,canvas.clientWidth,canvas.clientHeight); \n  // Create camera\n  camera = new Camera(currentMap,renderRegion);\n  // Create renderer. This should probably be based on map type in Dto, and will once all maps types are supported\n  renderer = new TiledIsometricRenderer(canvas,context2d,tileProvider,camera);\n...\n```\n\n[Example project here.](https://github.com/Layoric/DTiled_Example)\n\n[See complete simple example code.](https://github.com/Layoric/DTiled/wiki/Simple-DTiled-example)\n\n![example](http://3.bp.blogspot.com/-r5wizd17O6o/UqQhv1opKKI/AAAAAAAABjE/pY04lWEXMhc/s1600/dtiled_example.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flayoric%2Fdtiled","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flayoric%2Fdtiled","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flayoric%2Fdtiled/lists"}