Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
var bitmapData = Assets.getBitmapData ("tiles.png");
var tileset = new Tileset (bitmapData);
tileset.addTileRect (new Rectangle (0, 0, 100, 100));
var tilemap = new Tilemap (800, 600);
var tilemapLayer = new TilemapLayer (tileset);
var tile = new Tile (0);
tilemapLayer.addTile (tile);
tilemap.addLayer (tilemapLayer);
addChild (tilemap);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment