query · world.infrastructure
Infrastructure construction
Returns bounded Construction-owned infrastructure project, worker, Work identity, progress, resource-owner, and failure facts.
world.infrastructure.construction(filters?, cursor?, page_size?) -> query-page
- Stable ID
world.infrastructure.construction- Owner
- game.infrastructure-construction
- Authority
- read_only
- Timing
- immediate
- Availability
- active-session
- Side effects
- none
- Determinism
- stable owner order at the current committed tick
- Introduced
- 1.19.0
Usage
Read retained road, fence, or gate construction progress through a bounded detached query. Use the reported project revision for cancellation and the reported Work job identity with normal priority or assignment commands; do not retain a row after its callback.
Parameters
- filters.infrastructure_id: optional positive World infrastructure identity.
- cursor: optional stable-identity continuation cursor returned by the same query.
- page_size: positive record limit capped by the host.
Returns
A detached page containing build-or-repair purpose, project and resume stages, the World stage and condition restored on cancellation, failure cause, current worker, Work demand and job identities, source and site Resource containers, work cell, stage progress and requirements, revision, and causal ticks.
Cost
Bounded by page size and owner-visit budgets. Construction resumes from the stable infrastructure identity cursor.
Fields
| ID | Type | Units | Required | Description |
|---|---|---|---|---|
clearing_work | unsigned-integer | work-units | yes | Required clearing work. |
completed_stage_work | unsigned-integer | work-units | yes | Retained work completed in the current stage. |
created_at_tick | unsigned-integer | ticks | yes | Project creation tick. |
demand_id | stable-id | none | yes | Work demand identity. |
failure_cause | enumeration | none | yes | Retained terminal failure cause. |
finishing_work | unsigned-integer | work-units | yes | Required finishing work. |
infrastructure_id | stable-id | none | yes | World infrastructure identity. |
job_id | stable-id | none | yes | Work job identity. |
laying_work | unsigned-integer | work-units | yes | Required laying work. |
material_source_container_id | stable-id | none | yes | Resource stockpile container supplying the project. |
purpose | enumeration | none | yes | Build or repair. |
restored_world_condition | unsigned-integer | basis-points | yes | World condition restored if the project is cancelled. |
restored_world_stage | enumeration | none | yes | World stage restored if the project is cancelled. |
resume_stage | enumeration | none | yes | Stage retained across a worker handoff. |
revision | revision | none | yes | Construction project revision. |
site_inventory_container_id | stable-id | none | yes | Resource construction-site container. |
stage | enumeration | none | yes | Current infrastructure-work stage. |
updated_at_tick | unsigned-integer | ticks | yes | Latest project mutation tick. |
work_cell_x | signed-integer | grid-cells | yes | Infrastructure work cell X. |
work_cell_y | signed-integer | grid-cells | yes | Infrastructure work cell Y. |
worker_id | stable-id-or-null | none | no | Current resident worker. |
Errors
error.capability-unavailableerror.invalid-queryerror.query-budget-exhaustederror.query-contract-violation
Examples
local result = world.query("world.infrastructure.construction", {page_size = 8})
if result.status == "completed" then
for _, project in ipairs(result.records) do
ui.row("Infrastructure " .. tostring(project.infrastructure_id), project.stage)
end
end
API history
- 1.19.0: Physical retained road, fence, and gate construction inspection added for Village Life M2 and M3.
Related symbols
world.infrastructureworld.infrastructure.localcommand.infrastructure.cancelcommand.work.assigncommand.work.set-priorityworld.query