Buildings
Overview
Buildings are permanent structures placed on the map via the build queue. They provide shelter from weather, enable critical tasks (eating, resting, composing), and buff nearby elves. Four building types cover the settlement's needs: housing, crafting, aesthetics, and communal gathering.
How It Works
Building Types
| Building | Description |
|---|---|
| Dwelling | Living quarters. Speeds rest recovery. Counts as shelter. |
| Workshop | Crafting space. Required for composing. Counts as shelter. |
| Garden | Beauty and creative block recovery. Does NOT count as shelter. |
| Feast Hall | Communal eating. Social gathering space. Counts as shelter. |
(Source: src/sim/components.rs, enum BuildingType)
Build Costs
| Building | Wood | Stone | FineWood |
|---|---|---|---|
| Dwelling | 10 | -- | -- |
| Workshop | 10 | 10 | -- |
| Garden | 5 | -- | -- |
| Feast Hall | 15 | 5 | -- |
(Source: src/sim/systems.rs, build_cost())
Build Queue
Buildings are constructed through the build queue system:
- The patron or AI curator adds a
QueuedBuild(type + site position) toCulturalPolicies::build_queue. build_queue_system()checks if the settlement can afford the top item.- If affordable, it assigns an idle elf (preferring Builders) and deducts resources immediately.
- The assigned elf pathfinds to the build site and begins construction.
- Only one build is active at a time (no double-assignment).
(Source: src/sim/systems.rs, build_queue_system())
Builder Assignment Priority
When a build is ready to start:
| Priority | Candidate |
|---|---|
| 1st | Idle elf with Builder role |
| 2nd | Any idle elf |
| 3rd | Builder-role elf on a non-critical task (Sustenance >= 40, Rest >= 40) |
Builder-role elves on critical tasks (Eat, Rest, Build, ClearForest) or with low needs are not reassigned.
(Source: src/sim/systems.rs, build_queue_system())
Values & Formulas
Construction Progress
progress_rate = (5 + building_skill) + work_speed_modifier
Construction completes when progress reaches 100. Minimum rate is 1.
work_speed_modifier: Inspired = +2, Normal = 0, Stressed = -1.
| Building Skill | Ticks to Complete (Normal) | Ticks (Inspired) | Ticks (Stressed) |
|---|---|---|---|
| 1 | 17 | 13 | 20 |
| 3 | 13 | 10 | 15 |
| 5 | 10 | 8 | 12 |
| 7 | 9 | 7 | 10 |
| 10 | 7 | 6 | 8 |
On completion, the builder gains 15 Building XP.
(Source: src/sim/systems.rs, building_progress_system();
src/sim/components.rs, Skills::add_xp())
Shelter Radius
Buildings classified as shelter (Dwelling, Workshop, Feast Hall) protect elves within Manhattan distance <= 2 from weather penalties.
is_indoors = any shelter building within Manhattan distance 2 of elf
Garden does not count as shelter.
(Source: src/sim/systems.rs, weather_mood_system())
Weather Mood Effects (Shelter-Dependent)
| Weather | Outdoors Effect | Indoors Effect |
|---|---|---|
| Rain | "Caught in rain" -1 (50 ticks) | None |
| Snow | "Snow-covered landscape" +2 (50 ticks) | None |
| Storm | "Sheltering from storm" +0 (50 ticks) | "Sheltering from storm" +0 (50 ticks) |
(Source: src/sim/systems.rs, weather_mood_system())
Rest Recovery
Resting elves recover at different rates depending on proximity to a Dwelling:
| Location | Rest Recovery Rate | Mood on Completion |
|---|---|---|
| At Dwelling | +5 per tick | "Slept in dwelling" +3 (100 ticks) |
| Outdoors | +2 per tick | "Slept on ground" -3 (50 ticks) |
Resting completes when Rest reaches 80 ("Fulfilled" threshold).
(Source: src/sim/systems.rs, resting_system())
Eating
Elves perform the Eat task at any building tile (not just Feast Halls). Eating consumes 1 Food from the stockpile and restores +30 Sustenance.
(Source: src/sim/systems.rs, eating_system())
Composing
Composing requires presence at a Workshop tile with no remaining path. Composition duration scales with Music skill (see Skills for the formula).
(Source: src/sim/systems.rs, compose_system())
Garden and Creative Block
Elves with Creative Block seek a Garden. The Garden does not directly
restore beauty via a building buff -- instead, Gardens are typically placed
near forest tiles where the terrain_effect_system provides passive beauty
restoration. Creative Block drives the elf to the Garden as a waypoint.
(Source: src/sim/systems.rs, task_decision_system(), Step 2)
Interactions
- Resources -- build costs are deducted from the stockpile when construction starts; deposits require proximity to any building.
- Needs & Mood -- Dwellings provide faster rest recovery (+5 vs +2) and a positive mood modifier; sheltered buildings prevent rain mood penalties.
- Roles -- Builder role elves are prioritized for construction assignments.
- Skills -- Building skill determines construction speed; completion grants 15 XP.
- Terrain -- buildings must be placed on walkable tiles; Gardens are most effective near forest terrain for beauty synergy.
Tips
- Build order matters. A Dwelling first ensures Rest recovery is efficient. A Workshop second enables composing and Stimulation restoration. Garden third handles Beauty needs.
- Feast Hall is expensive but versatile. At 15 Wood + 5 Stone, it is the costliest building. But it serves as shelter, eating location, and social gathering point for elves pursuing social aspirations.
- Garden is cheap and essential. At only 5 Wood, it is the most cost-effective building. Place it adjacent to AncientForest tiles to maximize beauty synergy.
- Shelter radius is Manhattan 2. Buildings placed 1 tile apart create overlapping shelter zones. Cluster buildings to cover the most elves.
- One build at a time. The system prevents multiple simultaneous constructions. Queue your builds in priority order; the next one starts automatically when the current one finishes.
- Resources are deducted immediately when a build starts, not when it finishes. If a builder gets interrupted, the resources are still consumed. Make sure your builder has adequate needs before starting expensive constructions.
- Outdoor resting gives a mood penalty. Without a Dwelling, elves who rest get "Slept on ground" (-3 for 50 ticks). This stacks with weather effects and can spiral morale downward in early game.