query · world.settlement

Village demography

Returns one detached summary of current population viability, retained life-course transitions, authored bounds, and the current growth blockage.

world.settlement.demography(filters?, cursor?, page_size?) -> query-page
Stable ID
world.settlement.demography
Owner
assets.runtime-settlement-definition, game.actor-runtime, game.relationship, game.household, game.resource-economy, game.construction, and game.settlement
Authority
read_only
Timing
immediate
Availability
active-session
Side effects
none
Determinism
stable owner order at the current committed tick
Introduced
1.17.0

Usage

Read the retained settlement population trajectory, demographic gates, current population, labor, household, housing, food, health, safety, service, enterprise, prosperity, and life-event evidence without changing the settlement.

Parameters

Returns

One detached demographic row with the retained growing, stable, stagnating, declining, recovering, or abandoned trajectory; birth, immigration, and emigration decisions and reasons; current prosperity; population, labor, Household, housing, food, health, safety, service, enterprise, life-event, authored-limit, and visit-budget facts.

Cost

One exact retained Settlement strategy plus bounded Construction, Resource, Actor, Relationship, Household, Production, and Trade evidence; recurring demographic mutation remains limited by authored rotating visit and mutation budgets.

Fields

IDTypeUnitsRequiredDescription
active_enterprisesunsigned-integernoneyesCurrent active enterprise commitments.
actor_visit_budgetunsigned-integernoneyesMaximum Actors evaluated per demographic update.
adult_laborunsigned-integerbasis-pointsyesHealthy adult share of residents.
adult_labor_populationunsigned-integernoneyesHealthy adult residents available to sustain labor.
birth_allowedbooleannoneyesWhether current strategy permits the existing birth path.
birth_reasonstringnoneyesDirect reason for the current birth gate.
birthsunsigned-integernoneyesRetained Actor lineages created by birth.
conditionenumerationnoneyesRetained growing, stable, stagnating, declining, recovering, or abandoned trajectory.
deathsunsigned-integernoneyesActors with retained death facts.
emigrantsunsigned-integernoneyesActors with retained emigration facts.
emigration_pressurebooleannoneyesWhether current strategy pressures an eligible resident to leave.
emigration_reasonstringnoneyesDirect reason for the current emigration pressure.
evaluation_interval_ticksunsigned-integerticksyesAuthored demographic evaluation cadence.
food_unitsunsigned-integerresource-unitsyesAccessible demographic food reserve.
growth_blockagestring-or-nullnonenoCurrent settlement-level reason growth cannot proceed.
healthunsigned-integerbasis-pointsyesCurrent resident health support.
household_countunsigned-integernoneyesCurrent Settlement Households.
household_visit_budgetunsigned-integernoneyesMaximum Households evaluated per demographic update.
households_separatedunsigned-integernoneyesRetained Household-owned separation formations.
housing_capacityunsigned-integernoneyesUsable authored housing capacity.
immigrantsunsigned-integernoneyesActors with retained immigration provenance.
immigration_allowedbooleannoneyesWhether current strategy permits the existing immigration path.
immigration_population_ceilingunsigned-integernoneyesAuthored ceiling for labor-driven immigration.
immigration_reasonstringnoneyesDirect reason for the current immigration gate.
immigration_recovery_populationunsigned-integernoneyesAuthored population level restored by recovery immigration.
maximum_populationunsigned-integernoneyesAuthored population ceiling.
minimum_populationunsigned-integernoneyesAuthored population floor.
mutation_budgetunsigned-integernoneyesMaximum demographic mutations per update.
partnerships_formedunsigned-integernoneyesRetained Relationship-owned partnership formations.
populationunsigned-integernoneyesCurrent living Settlement residents.
population_pressurebooleannoneyesWhether population, housing, food, or Household strain creates decline pressure.
prosperityenumerationnoneyesCurrent prosperity evidence used by strategy.
recent_migration_changesigned-integernoneyesImmigrants minus emigrants since the previous retained evaluation.
recent_natural_changesigned-integernoneyesBirths minus deaths since the previous retained evaluation.
relationship_visit_budgetunsigned-integernoneyesMaximum Relationships evaluated per demographic update.
required_food_unitsunsigned-integerresource-unitsyesFood required for the current resident count.
safetyunsigned-integerbasis-pointsyesCurrent settlement safety support.
selected_enterprisesunsigned-integernoneyesCurrent selected enterprise opportunities.
servicesunsigned-integerbasis-pointsyesCurrent operational service support.
strained_householdsunsigned-integernoneyesHouseholds above the authored demographic strain limit.
target_populationunsigned-integernoneyesAuthored sustainable target.

Errors

Examples

local demography = world.query("world.settlement.demography", {page_size = 1})

API history

Related symbols

Project references