godot-doors · a Godot 4.7 addon

A door is never just a door.

godot-doors is a rooms and doors system for Godot. One autoload decides who may pass a door, who can hear or see through it, who knocks and who answers, who gets caught where they should not be, and which rooms keep living while the player is somewhere else.

Engine
Godot 4.7
Addon
GDScript, no dependencies
Acceptance checks
130, headless
Licence
MIT
The demo, recorded with Godot's Movie Maker and the Compatibility renderer, as on the web. The cast are procedural mannequins; no art assets are involved.

The door problem

In 2014 Liz England answered “what does a game designer do?” with a door. In The Door Problem she points out that the simplest object in a level makes almost every discipline on a team decide something, and each team decides it again for each game, usually as bugs.

England's post is a list of questions. This addon is one set of answers, for games about houses full of people with secrets, where a door does five jobs at once.

Five jobs, one authority

No script keeps its own “is this door open”. Everything asks the RoomsAndDoors autoload; Door.tscn and RoomArea are thin views of its state. Every discipline gets the same answers.

Movement gate

Three states, CLOSED, AJAR and OPEN, plus locked, held, blocked and jammed. Keys are ids; a master key lists the keys it stands in for. A close never completes into a body.

try_open · may_pass · grant_key

Information gate

Sound travels the door graph. A closed door passes its hearing factor, an ajar one more, an open one all of it. An ear against the door hears names. A keyhole shows a glimpse, then faces.

hear_check · sight_check · witnesses_of

Social instrument

Presence is not permission. Admission is computed: owner, resident, invited, on duty, or none. Chores grant bounded access. A servant on duty is invisible; one minute after, she is a discovery.

knock · admission · set_duty · discovery

Content gate

Restricted scenes declare door preconditions instead of checking by hand: closed, locked, private enough. One build flag resolves them to the scene or to a fade.

scene_preconditions_met · request_scene

Simulation boundary

Rooms one door from the player always run in full. Two doors out, at lower fidelity. Further, on the clock. A scene that started without you is joined in progress, never restarted.

simulation_tier · resident_rooms · start_activity

QA

Moving between rooms with no open door between them is flagged. 130 acceptance checks run headless. F3 draws the room graph, door states, witnesses and the last twenty events.

door_clip_detected · debug overlay

What carries through a door

A conversation in the study, loudness 0.4, and the maid in the gallery outside. Heard means above 0.08; identified, above 0.35. The numbers are the addon's defaults, and the demo plays them.

The maid in the gallery; the overheard log shows lines as rows of dots attributed to 'a man'.
Through the closed door, the overheard log shows only dots.
Closed door, factor 0.3
0.12: heard, not identified
Ajar door, factor 0.3 + 0.6
0.36: identified
Closed door, listening (thresholds × 0.4)
identified
A whisper, 0.15, through the closed door
0.045: nothing
Quiet door, 0.5 × 0.25, beside a sleeper (× 2.5)
0.125 < 0.2: she sleeps
The same door, closed normally
0.5: she wakes, and finds you

Play Ashcombe House.

You are the new maid. Tonight the master has a visitor, the mistress is writing a letter, and every door in the house listens back. Find out what the house is hiding before it finds out what you are doing. About ten minutes; keyboard required.

doorproblem.splatterfacegames.com/play Open in a new tab
About 50 MB. The download starts when you click.
WASD
walk; Shift sneaks and opens doors quietly
E
open, close, unlock, use; hold for chores
F
knock
hold R
listen at a door
hold T
peek through a keyhole
G
leave a door ajar
Z X
turn the camera
F3
the RoomsAndDoors debug overlay

A Godot web export: Compatibility renderer, no threads. The HUD is one UXML document loaded by godot-uxml; room names and speech are Typesetter text; the house is generated from a table of rooms and doors. Desktop builds are on the releases page.

Install

  1. Copy addons/rooms_and_doors into your project.
  2. Add the autoload RoomsAndDoors → res://addons/rooms_and_doors/rooms_and_doors.gd.
  3. Put a RoomArea in each room and a Door.tscn in each doorway, then register your characters.

The design, section by section, is in docs/design.md; the README lists every choice made where the design was open.

RoomsAndDoors.register_character(&"maid", $Maid, { "role": &"servant" })
RoomsAndDoors.set_duty(&"maid", &"study", { "duration": 120.0 })

var r := RoomsAndDoors.try_open(&"study_door", &"maid", { "quiet": true })
if not r.ok:
    print(r.reason)            # LOCKED, NO_KEY, BLOCKED, HELD …

var h := RoomsAndDoors.hear_check(&"maid", &"study", RAD.LOUD_CONVERSATION)
if h.identified:
    print(h.participants)

RoomsAndDoors.discovery.connect(func(who, finder, room, ctx):
    print(finder, " found ", who, " in ", room))

Where it is

Built

  • The autoload: rooms, doors, keys and master keys, admission, duty windows, invitations, knock policies, hearing, keyhole and ajar sight, witnesses, discovery, trespass log, residency tiers, activities, scene preconditions, fade-to-black, versioned save and load.
  • Door.tscn with placeholder clips and procedural sounds, RoomArea in 3D and 2D, KeyItem, NpcDoorAgent, the debug overlay.
  • 130 acceptance checks and a demo smoke run, in CI on every push.
  • Ashcombe House on the web, Linux and Windows.

Not built

  • Navigation meshes: demo NPCs walk straight lines inside rectangular rooms and do not avoid furniture.
  • Art: the house is boxes and the cast are mannequins, by design.
  • A 2D demo. RoomArea2D exists; the ajar sight cone is 3D only.
  • Lockpicking, multiplayer and networking are out of scope.

Licence

Copyright 2026 Jetha Chan. godot-doors is available under the MIT License. The demo vendors godot-uxml (Apache 2.0) and Typesetter (MIT); both draw Inter (SIL OFL 1.1). The addon itself depends on neither. “The Door Problem” is Liz England's essay; this project borrows its name with thanks and is not affiliated with her.