Progress on documentation

This commit is contained in:
2026-02-20 14:00:40 -08:00
parent d59cf82ab3
commit f421a8e436
413 changed files with 1681 additions and 109 deletions

View File

@@ -0,0 +1,99 @@
# Room 11: Enchanted Grove
This is a dangerous forest grove in King's Quest IV where sentient trees lurk, ready to grab unwary travelers. The room features multiple animated trees (views 692 and 693) positioned throughout the grove that can capture Rosella when she wanders too close to their reaching branches. The room serves as a hazard area with tree-grabbing traps triggered by walking on specific control areas. It connects to other forest areas in multiple directions.
## Look Description
"This place gives you the willies! The trees around here are very strange; almost human-like. A dense forest surrounds this odd grove of trees."
## Interactions
| Status | Behavior Type | Command | Response |
|--------|--------------|---------|----------|
| TODO | Look | `look around` / `look room` / `look[<around]` | "This place gives you the willies! The trees around here are very strange; almost human-like. A dense forest surrounds this odd grove of trees." (Print 11 0) |
## Scripts
| Status | Behavior Type | Name | Trigger | Behavior |
|--------|--------------|------|---------|----------|
| TODO | Interaction | grabbed | Player touches control areas (bitmasks $0002, $0004, $0008, $0010, $0020, $0040, $0200, $0400, $0800, $1000, $2000) anywhere in the room | Stops walking music, plays caught music, animates a tree grabbing the ego (using newProp based on control area), displays random tree-themed death message (wooden/limb/leaf/sap/root puns), sets global127=1 (game over state). Multiple control areas correspond to different tree props that grab the player. |
| TODO | Background | treeAnimation | Continuous when room loaded | Trees (newProp 1-11) are static props with cycleSpeed=1 but stopUpd called, except animated elements (newProp_2 through newProp_6) have setCycle:Fwd for continuous animation |
## Technical Notes
- **Room Number**: 11
- **Picture**: 11
- **Region**: 509 (Forest Region - referenced but region script not found)
- **Exits**: North→5, South→17, East→12, West→10
- **Music**: Walking music (sound 64), Caught music (sound 65)
### Objects
| Object | View | Loop | Description |
|--------|------|------|-------------|
| newProp 1 | 692 | 0 | Tree at position 145,76 |
| newProp 2 | 692 | 1 | Tree at position 152,83 |
| newProp 3 | 692 | 2 | Tree at position 167,83 |
| newProp 4 | 692 | 3 | Tree at position 196,70 |
| newProp 5 | 692 | 4 | Tree at position 213,66 |
| newProp 6 | 692 | 5 | Tree at position 258,76 |
| newProp 7 | 692 | 6 | Tree at position 305,70 |
| newProp 8 | 693 | 0 | Element at position 81,105 |
| newProp 9 | 693 | 1 | Element at position 242,86 |
| newProp 10 | 693 | 2 | Element at position 256,85 |
| newProp 11 | 694 | 0 | Element at position 281,65 |
| newProp_2 | 689 | 2 | Animated element (cel 2) at 105,62 - extra animation |
| newProp_3 | 689 | 3 | Animated element (cel 3) at 160,83 - extra animation |
| newProp_4 | 689 | 4 | Animated element (cel 2) at 249,83 - extra animation |
| newProp_5 | 689 | 5 | Animated element (cel 3) at 280,52 - extra animation |
| newProp_6 | 689 | 6 | Animated element (cel 0) at 314,48 - extra animation |
### State Variables
| Variable | Values | Description |
|----------|--------|-------------|
| `global101` | `0` | Set to 0 on room init |
| `global100` | `true`, `false` | When true, overlay picture 111 is displayed |
| `global112` | `true`, `false` | When true, tree grabbing is disabled (can walk safely) |
| `global127` | `0`, `1` | Set to 1 when player is caught by trees (game over state) |
| `local12` | `1-11` | Tracks which tree prop grabbed the player |
| `local13` | `1-3` | Animation cel parameter for grabbing animation |
### Control Areas
The room uses multiple control areas (bitmasks) to detect when player touches different tree zones:
| Bitmask | local12 | local13 | Tree Triggered |
|---------|---------|---------|----------------|
| $0002 | 8 | 3 | newProp 8 grabbing |
| $0004 | 1 | 1 | newProp 1 grabbing |
| $0008 | 2 | 2 | newProp 2 grabbing + another grab |
| $0010 | 3 | 1 | newProp 3 grabbing |
| $0020 | 4 | 1 | newProp 4 grabbing |
| $0040 | 5 | 1 | newProp 5 grabbing |
| $0200 | 9 | 1 | newProp 9 grabbing |
| $2000 | 6 | 2 | newProp 6 grabbing |
| $0400 | 10 | 2 | newProp 10 grabbing |
| $1000 | 11 | 3 | newProp 11 grabbing |
| $0800 | 7 | 2 | newProp 7 grabbing |
### Death Messages
When caught, one of these messages displays (Print 11 1-6):
1. "Wooden you know it. You've been caught!"
2. "You've really gotten yourself out on a limb this time, Rosella!"
3. "Talk about being torn limb from limb!"
4. "Time to 'leaf' this mortal world!"
5. "You've been a real sap this time, Rosella!"
6. "It seems you'll discover your roots, Rosella!"
### Additional Technical Details
- Entry from west (room 10): Player positioned at x=1, y=max(horizon+2, egoY)
- Entry from east (room 12): Player positioned at x=318, y=egoY
- Entry from south (room 17): Player y=188, x clamped between 103-277
- Entry from north (room 5): Player positioned at x=148, y=horizon+2
- Block defined at left=212, top=103, right=224, bottom=106 that ego observes
- Walking music (64) plays on room entry
- Caught music (65) pre-loaded for grab sequence
- Overlay 111 shown if global100 is true