Skip to content

TileCollisionShape

TileCollisionShape = { type: "box"; } | { points: [number, number][]; type: "polygon"; } | { cx: number; cy: number; r: number; type: "circle"; }

Defined in: tilemap/tilesetAsset.ts:26

A tile’s collision SHAPE, in tile-local pixels (origin top-left, y-down like the atlas). box = the full cell AABB (greedy-merged at runtime); polygon = custom points for slopes / partial tiles; circle = a disc centred at (cx, cy) with radius r.