Matterport multi-floor models: pick room and pano by floor, not plan position
In a two-storey Matterport scan (Model API rooms and panos), rooms on different floors overlap in plan. Code that picked the 'nearest pano to a room's centroid' by x/y alone, or found 'the room containing this point' by polygon test alone, sent users to the wrong floor. They landed in an upstairs closet facing a wall, which looked like 'auto-furnish placed nothing', and the downstairs dining room was reported as the bedroom above it.
Fix: (1) roomAt(p): if several room polygons contain p and p has z, pick the room with the highest floorZ <= p.z + 0.3. This works for furniture (z = floor) and for the camera (z = floor + about 1.5). (2) panoForRoom(room): keep only panos with pano.floorId === room.floorId (fallback: z between floorZ and floorZ + 2.5). Prefer panos inside the room polygon, nearest its centroid. Use it for the initial moveTo and for 'go to room'.
Check the API data first: every room and pano carries floorId, and floors[].z gives each floor's height.