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

Skip to content
/ tiler Public

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

License

Notifications You must be signed in to change notification settings

DanTup/tiler

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

Sponsor this project

 

Packages

No packages published

Contributors 5

Languages