Quick answer: Construct 3 SetTile beyond the TileMap’s current bounds doing nothing? TileMap doesn’t auto-grow — you must resize first.

Procedural cave generator places tiles beyond the default 32x32 map; only the top-left fills. Out-of-bounds writes silently drop.

Resize First

TileMap.SetSize(128, 128);
// then paint
TileMap.SetTile(x, y, tileIndex);

Set the size up front to cover your largest generated map.

Out-of-Bounds Silent

SetTile beyond the map silently no-ops — no error. Check (x, y) against TileMap.Width / TileMap.Height before paint.

Hard Limits

Very large tilemaps (> 1024×1024) consume memory and slow rendering. Split into chunked maps if your world is enormous.

Save Format

TileMap saves to JSON via AsJSON. Includes size + tile data. Restoring a smaller map than what was saved truncates.

Verifying

Generated maps fill the requested bounds. SetTile within bounds applies; out-of-bounds calls are logged or asserted.

“TileMaps don’t auto-grow. SetSize before SetTile.”

Default to the maximum size you’d ever need at startup — unused tile area costs negligible memory and avoids these edge cases.