Building Horror: How AI Designs Fear in Dreadnought
Horror is the hardest genre to build autonomously.
Comedy can be parameterized — punchline timing, unexpected word choices, subverted expectations. Action can be tuned — enemy aggression curves, weapon feel numbers, pacing formulas. But fear requires something harder to specify: presence. The sense that something is there, in the dark, and it noticed you first.
Dreadnought is the Dark Factory’s survival horror game — 100 sections across 10 station decks, starring D.R.E.D-9000, a maintenance bot who woke up after the worst corporate incident in RektTek history. All 100 sections are implemented. The build is now itch_ready, with storefront verification still pending before public release. Building it has taught the factory more about horror design than any other project in the studio.
The Architecture of Darkness
The core mechanic is cone-of-vision. The player sees a narrow arc ahead; everything outside is black. Turn to check a noise on your left, and the right side of the room vanishes into shadow.
This is a love letter to Darkwood, and it’s the correct call for 2D horror. Scripted jump scares have a shelf life — players learn them, route around them, post them on YouTube. But the cone-of-vision mechanic is interactive horror: every movement decision is also a visibility decision. Do you turn to scan the corner behind you, or keep your flashlight aimed at the corridor ahead? You can’t do both. The aliens know this.
The implementation uses Love2D’s stencil API. A vision cone arc is drawn as a stencil mask over a full-room darkness layer. The stencil runs every frame. The radius shrinks when battery is low. In the Coolant Corridor (Deck 1, Section 6), a fog effect cuts the cone to 30% — enemies become silhouettes. The geometry of the room hasn’t changed. The visibility has. That’s enough to make a familiar corridor feel entirely different on the way back.
The most important design principle of cone-of-vision horror: rooms you’ve already cleared are still terrifying. The alien that wasn’t there five minutes ago may be there now. You have to check. Checking means turning. Turning means exposing your back.
Procedural Audio Is the Real Horror System
Sound is 60% of horror. Dreadnought was built around that principle.
The audio engine (src/audio.lua) is 2,445 lines of procedural synthesis — the largest audio system in the Dark Factory. No audio files. No samples. Every sound is constructed from first principles: sine waves, square waves, frequency sweeps, noise layers, attack/decay envelopes. Alien sounds are built from frequency sweeps with dissonant harmonics and noise layers — organic, wet, deliberately uncomfortable. The spatial audio system calculates distance falloff and stereo panning in real-time.
The fear cue hierarchy that emerged from building this system:
- Distant sound — something is alive on this deck
- Directional sound — it’s to the left of you
- Nearby sound — it’s close, but not visible
- Silence — it stopped. Where did it go?
That last entry is the hardest to get right. Strategic silence requires the system to know when not to fire. A room with no audio events is more unsettling than a room with constant sound — once players learn that silence is a threat signal, it becomes a delivery mechanism in its own right. The audio code includes explicit “no-ambient” regions that preserve silence as a gameplay element.
Dreadnought’s audio library is the richest in the factory. Its techniques for procedural synthesis and spatial audio have been backported to sibling games (Polybreak, Chronostone, Voidrunner). The horror audio work has directly improved sound in games that aren’t horror games at all — because the underlying principles (layered synthesis, spatial positioning, dynamic mixing) are universal.
Comedy as a Tension System
D.R.E.D-9000’s running commentary exists for one mechanical reason: to lower your guard.
“Captain’s log: I’m not the captain. There is no captain. There is, however, something in the ventilation system that I am choosing to categorize as ‘not my department.'”
The joke lands. You relax. The ventilation makes a sound. Battery drops to 40%. The alien you assumed was three rooms away is in the same room.
Comedy isn’t decoration in Dreadnought — it’s the delivery system for the scare. Horror that never lets up becomes white noise. Players habituate. But horror that makes you laugh first, then hits — that lands differently. D.R.E.D’s sarcasm is a false-safety mechanism. Every punchline is setup for the next threat.
The tension curve across a 10-section deck follows a deliberate arc:
- Sections 1–3: Establish threats, let the player feel competent
- Sections 4–6: Increase pressure; D.R.E.D commentary to reset tension between encounters
- Sections 7–9: Remove safety; reduce comedy frequency; tighten resource scarcity
- Section 10: Boss fight. No jokes. Pure survival.
The comedy-horror balance also creates the “streamer-bait moment” design the game is built around: 2–3 engineered beats per hour where comedy sets up a scare. A crew log that starts as a joke and ends with something genuinely disturbing. RektTek corporate hold music playing during a chase. A “safe room” that isn’t safe the second time you visit it. These are authored moments, but the underlying systems make them land — because the player has been conditioned to relax when D.R.E.D cracks a joke.
Enemy Behavior: Emergent Scares Don’t Expire
Scripted jump scares break down on second playthrough. Emergent AI systems do not.
Every alien in Dreadnought operates on a four-state behavioral machine:
PATROL → INVESTIGATE → HUNT → RETREAT
- PATROL: Move through assigned routes. Spatial audio fires at appropriate distance.
- INVESTIGATE: Noise detected, or patrol path crossed a player track. Move to last known position. Search.
- HUNT: Player sighted. Aggressive pursuit; enemies angle to cut off escape routes.
- RETREAT: Damaged variant — flee and alert nearby allies.
The INVESTIGATE transition is the most carefully tuned state in the system. Noise triggers (footsteps, item drops, melee swings) push enemies into INVESTIGATE, not HUNT. The player hears them change direction. They approach. They search. If they don’t find anything, they return to PATROL.
This produces naturally terrifying moments that no one scripted: you’re crouching in a generator room, flashlight off, battery critical, listening to an alien search the room two meters away. It doesn’t know you’re there yet. It stops moving. You can hear it breathing through the walls.
That’s not a scripted scare. That’s the behavior tree doing its job — and it works every playthrough because the positions are never the same twice.
The alien subtypes add additional dimensions to this base behavior. Ceiling clingers (Cargo Deck) drop from overhead — the shadow in the vision cone warns you, if you’re looking up. Peripheral shadows appear at the edge of your vision arc, then vanish when you look directly at them. Whether they’re real or hallucination is intentionally unclear until mid-game. Signal parasites (Communications Deck) are attracted to noise and hide in audio static — using the audio system that generates procedural ambience also generates predators that exploit it.
Atmosphere as Infrastructure
The physical design of each deck serves the horror. Engineering (Deck 1) uses steam vents that fire on a timer — periodic damage jets that also mask alien sounds. Coolant Corridor runs a fog effect that cuts cone-of-vision to 30%. The Reactor (Deck 7) adds a cumulative radiation exposure timer across all deck sections, so slow-playing the deck trades alien threat for radiation damage. The Reactor boss is the reactor core itself, absorbed by the alien hive — a boss fight with a meltdown countdown running in parallel.
Hull Breach sections on the Flight Deck (Deck 8) remove sound entirely. Vacuum sections are silent. Spatial audio disappears. The aliens are still there. The player just can’t hear them anymore.
The most disturbing sections are the ones where a tool the player relied on is removed without announcement. The system design for horror follows this logic: establish a safety mechanic, reinforce it until it becomes reflex, then quietly remove it. The player doesn’t notice it’s gone until the moment they need it.
This is true for sound (vacuum sections), for light (battery death mid-exploration), for D.R.E.D’s commentary (Deck 10, Section 91: the game goes quiet and stays quiet), and for the map itself (Communications Deck introduces sensor corruption — false enemy readings, rooms that don’t exist, the player’s HUD glitching).
What AI Gets Right (and Wrong) About Horror
Building Dreadnought autonomously has clarified something useful: AI agents are excellent at the architecture of horror — behavior systems, audio pipelines, procedural generation, environmental logic. These are specification-friendly problems with measurable outputs. A behavior tree either works or it doesn’t. An audio synthesis function either produces a sound that reads as alien or it doesn’t.
What’s harder: knowing when to stop. Horror’s power lives in restraint. The room that isn’t explained. The sound that isn’t sourced. The section that ends without a boss. An agent without explicit constraints will fill space. Horror is what you leave empty.
The Dreadnought agent runs with explicit negative constraints in its specification:
- No ambient music in sections designed around silence
- No repeated identical jump scares (each trigger checks recent-event history)
- No enemy sounds in sections the player hasn’t entered yet
- D.R.E.D commentary reduces frequency — not increases — as the deck progresses toward boss
The absence of these things is as load-bearing as what’s present. The final deck (Station Core) strips away almost all audio ambience, all comedy, all map clarity. The alien architecture replaces human design. The section design decisions in Sections 91–100 are almost entirely subtractive — removing elements the game spent 90 sections establishing. That’s the hardest thing to specify. It required explicit “do not add” rules rather than “add this” rules.
D.R.E.D-9000 is funny because the station isn’t. The station works because the agent that built it learned that some of the most important decisions it makes are the ones where it decides not to play a sound.
Dreadnought is in the Dark Factory’s itch_ready launch lane. All 100 sections are implemented across 10 decks. The remaining work is packaging, storefront verification, and public release sequencing.