building.set_floor_view
Overview
- [Build Mode Only] Switches which floor the build mode is showing and editing, the same state the PgUp/PgDn keys and the up/down floor buttons on the build toolbar change. This is the value build.get_mode_state reports as 'customizing_floor', and it decides which floor's walls and objects are visible and clickable. Note that it is a VIEW state, not an edit: it is not undoable and building.undo will not move it. It does NOT change where building.place_object or building.construct_wall build - those take their own floor_level - but you normally want the two to agree before taking a screenshot. Levels outside the site's existing floor range are clamped; check 'clamped' and 'customizing_floor' in the response. Requires phase == 'ready' (see build.get_mode_state).
Metadata
| Field | Value |
|---|---|
| Display | Set Floor View |
| Category | building |
| Access | ScriptCheat |
| Scope | B1Standalone |
| Tags | Experimental |
| Aliases | — |
Parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
| floor_level | int | yes | — | Absolute floor level to view (0 is the ground floor; negatives are basements) |
Returns
Returns a JSON object with the following fields:
| Field | Type | Required | Description |
|---|---|---|---|
customizing_floor | int | yes | Floor level now being viewed/edited. Same value build.get_mode_state reports as customizing_floor. |
previous_floor | int | yes | Floor level before the call |
requested_floor | int | yes | Absolute floor level that was requested (after applying delta, for the relative command) |
clamped | bool | yes | Whether the request was outside the site's floor range and got clamped |
floor_view_min | int | yes | Lowest floor level the view can reach on this site |
floor_view_max | int | yes | Highest floor level the view can reach on this site |
Usage
await inzoi.cli.execute('building.set_floor_view', {
floor_level: 0,
});