tilemap
Create and manage Unity Tilemaps for 2D level design. Place, erase, fill, and inspect tiles, compress bounds, and control tile colors.
Instructions
Manage Unity Tilemaps for 2D level design. Actions:
create: Create a new Tilemap under a Grid (creates Grid if needed)
get_info: Get tilemap details (bounds, tile count, orientation)
set_tile: Place a tile at a cell position
erase_tile: Remove a tile at a cell position
fill_area: Fill a rectangular area with a tile
clear: Remove all tiles from a tilemap
get_tile: Inspect what tile is at a cell position
get_bounds: Get the used cell bounds
list: List all tilemaps in the scene
list_tiles: List TileBase assets in a folder
create_tile: Create a Tile asset from a sprite
set_color: Set the color tint of a tile at a position
compress_bounds: Compress tilemap bounds to remove empty space
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| a | No | Alpha color component (0-1) | |
| b | No | Blue color component (0-1) | |
| g | No | Green color component (0-1) | |
| r | No | Red color component (0-1) | |
| x | No | Cell X position | |
| y | No | Cell Y position | |
| endX | No | Fill area end X | |
| endY | No | Fill area end Y | |
| name | No | Name for new tilemap (create) | |
| color | No | Color JSON for create_tile: {"r":1,"g":1,"b":1,"a":1} | |
| action | Yes | Tilemap action to perform | |
| folder | No | Folder to search for tiles (default: Assets) | |
| startX | No | Fill area start X | |
| startY | No | Fill area start Y | |
| tilePath | No | Asset path to a TileBase or Tile | |
| tilemapId | No | Instance ID of the Tilemap | |
| parentPath | No | Parent Grid path (create) | |
| spritePath | No | Sprite path for create_tile | |
| tilemapName | No | Name of the Tilemap GameObject | |
| sortingOrder | No | Sorting order (create) |