Skip to main content

build.get_site_info

Overview

  • CALL THIS FIRST when you are about to build anything. It returns an aggregate summary of the current site - type, size, floor range, counts - plus a 'build_rules' block that states the conventions the rest of the build CLI assumes: which coordinate space x/y/z and yaw use, how doors and windows auto-align to walls, which field carries a storey's elevation (floor_height, not base_height), the default and preset wall heights, and the floor_height to use for the next floor up. Reading it once saves you from the mistakes those rules describe. Read 'coord_space' before placing anything: site coordinates are in CENTIMETRES, the origin (0,0) is the site's MINIMUM CORNER (not the centre), and the usable range is coord_space.min..coord_space.max, which equals 0..site_size. Note that 'site_half_extent' is the distance from the origin to the site centre, so it is HALF of site_size - using it as the full size confines everything to one quadrant. The wall grid snaps to 25cm. Works in both play mode (character must be inside a building) and build mode. This command AGGREGATES only. For per-object / per-wall / per-room enumeration use build.scan_objects, build.scan_walls and build.scan_floors with limit/offset. detail=floors adds a per-floor breakdown with up to 32 rooms per floor. NOTE: counts.floors is the number of allocated floor structures, which the engine grows on demand and never releases - it does not go back down after building.undo. Use floor_min/floor_max for the range of floors that actually contain something.

Metadata

FieldValue
DisplayGet Site Info
Categorybuild
AccessPublic
ScopeB1Standalone
TagsExperimental
Aliases—

Parameters

NameTypeRequiredDefaultDescription
detailstringnosummarysummary (default) or floors
floor_levelintno—Restrict every count and the floors breakdown to a single floor level

Usage

await inzoi.cli.execute('build.get_site_info', {
detail: 'summary', // optional
floor_level: 0, // optional
});