Skip to content

Commit

Permalink
docs: Fix IsometricTileMap code (#3165)
Browse files Browse the repository at this point in the history
Fix the code in the docs page examples which has IsometricTileset and is
not present in the flame to SpriteSheet

Co-authored-by: Lukas Klingsbo <[email protected]>
  • Loading branch information
immadisairaj and spydon authored May 24, 2024
1 parent 6dfc169 commit ffba0f9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion doc/flame/components.md
Original file line number Diff line number Diff line change
Expand Up @@ -1231,7 +1231,7 @@ A simple example on how to use it:
// Creates a tileset, the block ids are automatically assigned sequentially
// starting at 0, from left to right and then top to bottom.
final tilesetImage = await images.load('tileset.png');
final tileset = IsometricTileset(tilesetImage, 32);
final tileset = SpriteSheet(image: tilesetImage, srcSize: Vector2.all(32));
// Each element is a block id, -1 means nothing
final matrix = [[0, 1, 0], [1, 0, 0], [1, 1, 1]];
add(IsometricTileMapComponent(tileset, matrix));
Expand Down

0 comments on commit ffba0f9

Please sign in to comment.