aboutsummaryrefslogtreecommitdiff
path: root/building_guide/rooms.md
diff options
context:
space:
mode:
authorhistoria <[not public]>2026-06-25 20:33:47 -0400
committerhistoria <[not public]>2026-06-25 20:33:47 -0400
commit84d74ca4351a97148ad8339676f9df7946bc21fb (patch)
treea9f50ac56e8bbcdf2b307ef6f7143b67bce46c61 /building_guide/rooms.md
parentc55d0e4150b23f2c5c9f96bbc3d4dc2fc6dbaa36 (diff)
downloadthehouseoficarus-84d74ca4351a97148ad8339676f9df7946bc21fb.tar.gz
feat: trigger system for scripted events added.
Diffstat (limited to 'building_guide/rooms.md')
-rw-r--r--building_guide/rooms.md22
1 files changed, 22 insertions, 0 deletions
diff --git a/building_guide/rooms.md b/building_guide/rooms.md
index 7028393..5a414a3 100644
--- a/building_guide/rooms.md
+++ b/building_guide/rooms.md
@@ -208,5 +208,27 @@ mobs:
- Hazards stack with mobs: an aggressive mob in a hazardous room hits you while the room
hazard also rolls against you.
+### Room triggers — scripted events when flags change
+
+A room can carry a `triggers:` block. Each trigger watches a player or world flag
+and fires a sequence of timed steps when that flag's value changes. See `triggers.md`
+for the full reference.
+
+```yaml
+triggers:
+ - on_player_flag: 1001_look_sign
+ steps:
+ - delay: 5
+ message: "The cabin shakes as the small craft touches down"
+ - delay: 5
+ message: "The pistons hiss as the rear staircase opens"
+ - set_player_flags:
+ 1001_touchdown: true
+```
+
+Room triggers are scoped to the room — broadcasts go to that room, mobs spawn there,
+and the trigger only fires when the flag-setting player is in that room. For
+server-wide events, use global triggers in `data/triggers/` instead.
+
---