Preview Wang terrain edits
tiled_update_wangsetsApply sequential Wang edits (add sets, colors, or tile assignments) to an external tileset atlas, returning an expiring change set without altering project files.
Instructions
Validates sequential Wang edits on one currently referenced external atlas TSJ — addWangSet appends a new set (name, corner/edge/mixed type, optional colors up to Tiled's 254-color limit), addWangColor appends one 1-based color to an existing set, and setWangTiles applies Tiled setWangId semantics per assignment (an all-zero 8-slot wangId removes the tile's entry, an identical one is a no-op, anything else upserts; slots run clockwise from the top edge and reference 1-based color indexes valid at that point in the sequence). The touched wangtiles member is rewritten in Tiled's canonical ascending-tileId save order. Returns an expiring wangEdit change set without modifying project assets; image-collection tilesets and pre-1.5 edgecolors/cornercolors sets fail closed.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mapPath | Yes | Canonical project-relative POSIX path; absolute paths and .. are forbidden | |
| operations | Yes | ||
| tilesetAssetId | Yes | ||
| expectedMapRevision | Yes | SHA-256 revision returned by a read or preview | |
| expectedTilesetRevision | Yes | SHA-256 revision returned by a read or preview |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |