Commit graph

3 commits

Author SHA1 Message Date
c6c88acc47 sow no longer needs grain + add crop zone paint tools
Bug: pawns weren't replanting. _find_sow required a TYPE_GRAIN item
as seed, but Millstone's flour bill (FOREVER) consumed all grain
before sow could claim it. With CookingProvider now priority 6, grain
contention is fatal — TILLED crops sit forever.

Fix: removed the grain requirement. Sow is now Rimworld-style — the
designation triggers work; no input is consumed. _find_sow returns a
2-toil job (walk → interact). Crop.on_sow_tick just flips stage to
SOWN.

Feature: 4 new paint tools in BuildDrawer's new "Farm" section column
— TOOL_PAINT_CROP_WHEAT/POTATO/CORN/STRAWBERRY. Painting a grass
tile spawns a TILLED Crop entity that pawns then sow. World rejects
non-grass tiles, occupied tiles, and non-walkable terrain. 9 new
string keys, kind-specific thumbnail draws (gold/tan/yellow/red).

MCP verified: 12 forced-TILLED crops fully cycled TILLED → SOWN →
growth → READY within ~3000 ticks. Paint tool spawned wheat crop at
(35, 30); wall tile at (44, 23) correctly rejected.

Followup smell: cancelling a designation on a player-painted crop
will queue_free even if grown — Crop has no can_complete. Future
guard could skip crops past TILLED.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-16 21:29:00 +01:00
d98d2c2425 Renewable resources: tree growth + WildGrowth + Quarry on BigRockNode
Trees: 4 growth stages (Sapling→Young→Growing→Mature), only Mature
yields wood. WildGrowth ticker fires every in-game hour; rejection-
samples grass tiles and plants a sapling with ~30% probability (capped
at MAP_TREE_LIMIT=60). New `paint_plant_tree` designation lets the
player manually plant — ghost sapling registered as a build_site that
ConstructionProvider fulfils. Stage round-trips through save/load.
Initial seed mixes 4 saplings + 6 mature so growth is visible day 1.

Quarry: new BigRockNode entity (2×2 permanent stone outcrop, never
depletes). 3 nodes seeded far from cabin. New QuarryWorkbench
(extends Workbench, auto-FOREVER `quarry_stone` bill, recipe drops
1 stone per 300 work-ticks). New `paint_quarry` designation only
accepts BigRockNode tiles. CraftingProvider now supports recipes
with `ingredient_count == 0` — skips ingredient-fetch and goes
straight to walk+craft toils. Recipe gains `ingredient_count` field
(defaults 0). Save/load layering: big_rock_node spawns at priority 0
(same as rock/tree), quarry_workbench at priority 2 (after the node).

UI: Plant tree + Build quarry buttons added to Build drawer.
build_drawer_thumb gains `plant_tree` (sapling sprout in dirt) and
`paint_quarry` (stone block + chisel + cut-stone pile) shapes.
inspect_tooltip recognises BigRockNode + shows tree growth stage on
hover.

Delegation: gdscript-refactor (Sonnet ×2) for trees full impl +
quarry skeleton; quick-edit (Haiku) for CraftingProvider no-ingredient
plumbing + TopBar polish; integration handled on Opus.
2026-05-16 16:36:16 +01:00
53cb92041c UI pass: medieval-warm Theme + real Build drawer thumbnails
Theme (scenes/ui/medieval_theme.gd):
- Procedural builder for an app-wide Theme: parchment buttons on
  dark-wood border, tan panels, ink text, gold focus ring.
- Applied on the root Window in Main._ready, with a tree-walk that
  re-seeds every CanvasLayer's topmost Control (CanvasLayer
  interrupts the root-Window theme cascade in Godot 4).
- Late-mounting popups + modals get themed via a child_entered_tree
  hook on each CanvasLayer.

Build drawer thumbnails (scenes/ui/build_drawer_thumb.gd):
- New BuildDrawerThumb Control that dispatches on tool_id and draws
  a recognisable silhouette of the entity each tool builds. 17 tools
  covered: chop/mine/dig_grave/no_roof (Designate), stone+wood walls,
  wood+stone floors, door, crate, bed, torch, 5 workbenches
  (Carpenter/Smelter/Millstone/Hearth/Cremation Pyre), stockpile,
  graveyard.
- Replaces the flat ColorRect placeholder. _add_tool_btn signature
  changed from (label, color, callback) to (label, tool_id, callback).
2026-05-16 16:09:56 +01:00