# Tavern Lighting Implementation Plan

> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.

**Goal:** Add atmospheric candle/lantern lighting to the tavern so the scene is visible and testable.

**Architecture:** Edit `taproom.tscn` (shared geometry) to add multiple OmniLight3D nodes and tune the WorldEnvironment ambient. Then add lights to `tavern.tscn`'s upper floor (corridor + rooms). No new scripts needed — pure scene edits.

**Tech Stack:** Godot 4.x, GDScript, godot-mcp scene tools

---

## Context

`taproom.tscn` already has one OmniLight3D (energy 1.2, range 10, warm color) and a WorldEnvironment with fog. The single light is insufficient — the room is dark and the upper floor has zero lights. Both `tavern_lobby.tscn` and `tavern.tscn` use `taproom.tscn` as a sub-scene, so improvements there benefit both.

## Files

| File | Action |
|------|--------|
| `ruf-der-pilze/scenes/taproom.tscn` | Add OmniLight3D nodes, tune WorldEnvironment ambient |
| `ruf-der-pilze/scenes/tavern.tscn` | Add OmniLight3D nodes to UpperFloor |

---

## Task 1: Tune WorldEnvironment in taproom.tscn

The existing `WorldEnvironment` node has a dark ambient. Raise it so the scene has a minimum base brightness.

**Files:**
- Modify: `scenes/taproom.tscn` — WorldEnvironment/Environment resource

- [ ] **Step 1: Open taproom.tscn in Godot via MCP, select WorldEnvironment node**

  Use `mcp__godot-mcp__scene` or `mcp__godot-mcp__editor` to open the scene. Navigate to the `WorldEnvironment` node.

- [ ] **Step 2: Set ambient light values**

  Set on the `Environment` resource:
  ```
  ambient_light_color = Color(0.15, 0.10, 0.06)   # very dim warm brown
  ambient_light_energy = 0.4
  ambient_light_sky_contribution = 0.0
  ```

- [ ] **Step 3: Screenshot to verify minimum base brightness**

  Use `mcp__godot-mcp__editor` screenshot. The scene should no longer be pitch-black.

- [ ] **Step 4: Commit**

  ```bash
  git add ruf-der-pilze/scenes/taproom.tscn
  git commit -m "feat: taproom — raise ambient light for base visibility"
  ```

---

## Task 2: Add fill lights to taproom.tscn

Add 3 additional OmniLight3D nodes inside the taproom for tables and corners. All lights use warm candle tones.

**Files:**
- Modify: `scenes/taproom.tscn` — add OmniLight3D children to Taproom root

Light positions (approximate, adjust in editor if needed):

| Name | Position | Energy | Range | Color |
|------|----------|--------|-------|-------|
| `CandleTable1` | (-2, 1.0, 1) | 0.8 | 5.0 | (1.0, 0.65, 0.2) |
| `CandleTable2` | (1, 1.0, 2) | 0.8 | 5.0 | (1.0, 0.65, 0.2) |
| `BarLight` | (4, 1.5, -3) | 1.0 | 6.0 | (0.95, 0.60, 0.25) |

- [ ] **Step 1: Add CandleTable1 OmniLight3D**

  Add as child of `Taproom` root. Name: `CandleTable1`. Set transform position, color, energy, range as above. Enable shadows: `shadow_enabled = true`.

- [ ] **Step 2: Add CandleTable2 OmniLight3D**

  Same settings, position (1, 1.0, 2).

- [ ] **Step 3: Add BarLight OmniLight3D**

  Position (4, 1.5, -3), slightly higher energy. This lights the bar counter area.

- [ ] **Step 4: Screenshot from inside taproom**

  Verify warm candlelit atmosphere. Tables should be lit, corners may be darker.

- [ ] **Step 5: Commit**

  ```bash
  git add ruf-der-pilze/scenes/taproom.tscn
  git commit -m "feat: taproom — add candle lights at tables and bar"
  ```

---

## Task 3: Add lights to tavern.tscn upper floor

The upper floor (rooms + corridor) has zero lights. Add corridor lighting and one light per room area.

**Files:**
- Modify: `scenes/tavern.tscn` — add OmniLight3D to `UpperFloor` node

Upper floor is at Y ≈ 3.5–5.5. Room positions roughly: Room1–Room4 along one side, Room5–Room9 along the other. Corridor runs through the center.

- [ ] **Step 1: Add corridor OmniLight3D**

  Add under `Tavern/UpperFloor`. Name: `CorridorLight`.
  ```
  position = (0, 4.5, 0)
  color = Color(0.7, 0.55, 0.3)
  energy = 1.5
  range = 12.0
  shadow_enabled = true
  ```

- [ ] **Step 2: Add room fill lights (one per side)**

  Two wide-range dim lights to fill the rooms without adding 8 individual lights:

  `RoomLightA` — position (-3, 4.2, -2), energy 0.6, range 8.0, color (0.8, 0.6, 0.3)
  `RoomLightB` — position (3, 4.2, -2), energy 0.6, range 8.0, color (0.8, 0.6, 0.3)

- [ ] **Step 3: Screenshot from UpperFloor spawn point**

  Spawn at Room1 SpawnPoint (`UpperFloor/Room1/SpawnPoint`). Verify room is visible.

- [ ] **Step 4: Commit**

  ```bash
  git add ruf-der-pilze/scenes/tavern.tscn
  git commit -m "feat: tavern — add upper floor corridor and room lighting"
  ```

---

## Task 4: Fine-tune and verify end-to-end

- [ ] **Step 1: Run Godot project with server + 1 client**

  Start server: `godot --headless -- --server`
  Start client: open Godot editor, run scene, join as Spieler.
  Verify: taproom is visible, upper floor is visible after spawn.

- [ ] **Step 2: Screenshot from player perspective in taproom**

  Must be able to see walls, bar, floor clearly. Warm candlelit feel.

- [ ] **Step 3: Screenshot from player perspective in upper room**

  Must be able to see bed, walls, door. Not pitch-black.

- [ ] **Step 4: Adjust any lights that look off**

  Common issues: lights too bright (reduce energy), too small (increase range), wrong color.

- [ ] **Step 5: Update STATUS.md**

  Mark Schritt 7 ✅, set Schritt 8 (Dice Roller) as next.

  ```bash
  git add docs/STATUS.md
  git commit -m "docs: mark Tavern Lighting complete"
  ```
