bulc_create_room_polygon
Create custom-shaped rooms in building designs by defining polygon coordinates. Design L-shaped or irregular rooms using precise centimeter measurements for architectural planning.
Instructions
Create a room with a custom polygon shape defined by an array of points. Use this for non-rectangular rooms like L-shaped rooms. All coordinates are in centimeters.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| points | Yes | Array of [x, y] coordinate pairs defining the room polygon in centimeters. Minimum 3 points required. Points should be in order (clockwise or counter-clockwise). | |
| name | No | Room name for display | |
| level | No | Floor level index. Default: current level |
Implementation Reference
- src/tools/room.ts:220-227 (handler)Handler logic for the 'bulc_create_room_polygon' tool: parses input arguments using Zod schema and sends a 'create_room_polygon' command to the BULC client.case "bulc_create_room_polygon": { const validated = CreateRoomPolygonSchema.parse(args); result = await client.sendCommand({ action: "create_room_polygon", params: validated, }); break; }
- src/tools/room.ts:50-87 (registration)Registration of the 'bulc_create_room_polygon' tool in the roomTools array, including name, description, input schema, and annotations.{ name: "bulc_create_room_polygon", description: "Create a room with a custom polygon shape defined by an array of points. " + "Use this for non-rectangular rooms like L-shaped rooms. " + "All coordinates are in centimeters.", inputSchema: { type: "object" as const, properties: { points: { type: "array", description: "Array of [x, y] coordinate pairs defining the room polygon in centimeters. " + "Minimum 3 points required. Points should be in order (clockwise or counter-clockwise).", items: { type: "array", items: { type: "number" }, minItems: 2, maxItems: 2, }, minItems: 3, }, name: { type: "string", description: "Room name for display", }, level: { type: "integer", description: "Floor level index. Default: current level", }, }, required: ["points"], }, annotations: { readOnlyHint: false, destructiveHint: true, }, },
- src/tools/room.ts:177-181 (schema)Zod validation schema used in the handler for input validation of 'bulc_create_room_polygon' tool.const CreateRoomPolygonSchema = z.object({ points: z.array(z.tuple([z.number(), z.number()])).min(3), name: z.string().optional(), level: z.number().int().optional(), });