Thanks to visit codestin.com
Credit goes to github.com

Skip to content

LongCatIsLooong/tiler

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NOTE: This software is not being actively developed or maintained.

Tiler

A Dart/Flutter library for rendering maps created with the Tiled map editor in Dart/Flutter.

Example map in the Tiled editor:

Example map rendered in Flutter using Tiler:

Usage

Tile maps and tilesets must use the JSON format (not XML).

Use loadMap to load a map and all external assets asynchronously (for ex. during a loading screen or using a FutureBuilder):

var loadedMap = await loadMap(rootBundle, 'assets/example_map.json');

Use the TileMap widget to render the map at a given offset with a given size. The number of elapsed milliseconds must be supplied for animated tiles to animate.

TileMap(
  loadedMap,
  offset,
  Size(
    (map.width * map.tileWidth).toDouble(),
    (map.height * map.tileHeight).toDouble(),
  ),
  sw.elapsedMilliseconds,
)

About

Library for rendering maps created with the Tiled map editor in Dart/Flutter.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Dart 100.0%