Fix room surfaces, wall openings, and paint scope#498
Conversation
…oofing finishes All 48 remaining webp/jpg/png finish entries now reference _512.ktx2 maps and 256px _thumb.webp previews, matching the fabric/leather/concrete/metal convention. flipY set to false on the converted entries — compressed textures can't be flipped at upload. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 2 potential issues.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 3c762e3. Configure here.
| wall.start[0] + local.x * cos - local.z * sin, | ||
| wall.start[1] + local.x * sin + local.z * cos, | ||
| ], | ||
| } |
There was a problem hiding this comment.
Curved wall room paint
Medium Severity
Room-scope wall painting now depends on resolveWallPaintHit, which maps the click to a plan point using a straight chord from wall.start/wall.end and mesh-local x. Curved walls use sampled polylines in boundaryFaces, so the hit point and face often miss the correct subsegment and resolveWallPaintSpace falls back to a single surface or the wrong room.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 3c762e3. Configure here.
| if (boundary.wallId !== wall.id || boundary.face !== wallHit.face) continue | ||
| const distance = distanceToPolyline(wallHit.point, boundary.points) | ||
| if (distance > tolerance || (best && distance >= best.distance)) continue | ||
| best = { space, distance } |
There was a problem hiding this comment.
Room paint tie breaks arbitrarily
Medium Severity
When two spaces share the same wall face and the click is equidistant from both boundary polylines, resolveWallPaintSpace keeps the first match and skips later ties via distance >= best.distance. The winner follows Object.values(spaces) order, so room-scope paint can target the wrong room without a stable rule.
Reviewed by Cursor Bugbot for commit 3c762e3. Configure here.


Summary
Test plan
bun run typecheckbun run build🤖 Generated with Codex