SourceMod · RCBot2 · Day of Defeat: Source

Twelve Actors
bots that talk back, in their own voices.

A conversation layer for Source-engine bots. Twelve Actors binds each bot slot to a persona with a voice, lets an LLM write short in-character lines, and plays the line back using the voice clips the game already ships — no TTS, no audio generation, no voice cloning, no GPU.

What it does

chat

Bots text chat back

Address a bot by name in team chat and it answers, in character, with a line short enough to be spoken.

voice

Real voices, no new assets

Each line is matched to an existing .wav inside the game's dod_pak_dir.vpk — read in place, nothing extracted to disk — and played as that bot's speech sound.

cast

A cast, not a crowd

Twelve hand-written personas bound to RCBot2 profile slots 1–12. The bot module adds them in order and renames strays instead of kicking them, because a kick costs a death notice in the kill feed.

events

More than chat

Deaths and round starts can trigger a bark, and in-game quick-key radio is captured and answered.

cost

Silent when nobody listens

With zero human players the plugin stops writing events and the daemon refuses to spend a model turn. Read cursors keep moving, so the first person in never hears a stale backlog.

protocol

Text-first, engine-safe

Two append-only TSV files between plugin and daemon. No HTTP, sockets or named pipes in the hot path: if the daemon is down the game does not care, and it resumes when it comes back.

How the pieces connect

 player chat  ──┐
 quick keys   ──┤   SourceMod plugin        append-only TSV        Python daemon
 deaths/rounds──┴──►  twelveactors.sp ──►  in.tsv     ──►  twelveactors/bridge.py
                    ta_bots_rcbot2.sp                       ├─ personae (sqlite)
                    ta_botjoin.sp  (no team-change death)   │
                                                            ├─ LLM (OpenAI-compatible)
                                                            └─ voice clip picker
                                  out.tsv  ◄──  clip + chat line
                                     │
        twelveactors.sp plays the clip on the speaking bot

The daemon's HTTP listener is bound to 127.0.0.1:8377 — localhost only. No public address and no port forward are needed to run it.

The cast

Two voices ship with the game — one male US, one male German — so pitch is the per-bot distinction. It travels in the sound packet, so it costs nothing: no new files, no client download, no precache_budget change.

Allied
  • John 97
  • Paul 103
  • Frank 108
  • Donald 94
  • Thomas 111
  • Edward 100
Axis
  • Walter 96
  • Herbert 102
  • Alfred 107
  • Kurt 93
  • Otto 110
  • Rolf 99

Numbers are clip pitch (100 = untouched). sm_ta_reload re-reads the table live.

Requirements

ThingVersion usedNotes
DoD:S dedicated serverapp 23229032-bit binary; on Arch enable multilib
MetaMod:Source1.11+the loader SourceMod runs under
SourceMod1.12.0-git72551.11 crashes on current srcds builds
RCBot22.0-alpha8supplies the bots and the console surface the bot module drives
Python3.9+standard library only — no pip install step
Linux with systemd—developed on Omarchy/Arch, x86-64
No API key is needed just to play. With no model configured the daemon falls back to clip-only barks. Add an OpenAI-compatible endpoint when you want generated lines.

Install

git clone https://github.com/burnssos/twelveactors.git twelveactors
cd twelveactors
sudo TWELVEACTORS_API_BASE=https://api.venice.ai/api/v1 \
     TWELVEACTORS_API_KEY=<your-key> \
     TWELVEACTORS_MODEL=deepseek-v4-flash-0731 \
     ./install.sh

install.sh compiles the five plugins, installs the daemon to /opt/twelveactors, writes config.json, indexes the voice clips, binds the cast to the RCBot2 profile slots, pins min_bots 0 / max_bots 12, installs and starts the service, and restarts the game so the plugins load. It must run as root and is idempotent — re-running it is the supported way to ship a change.

Omit the three TWELVEACTORS_* variables and the installer asks for them on a terminal, reading the key with echo off. With no terminal it writes <YOUR_API_KEY> placeholders and prints the file to edit, so a botched install cannot look like a working one.

Choosing a model

The daemon needs an OpenAI-compatible /chat/completions that returns a JSON object and respects max_tokens. deepseek-v4-flash-0731 is the recommendation — cheap, about $0.0002 per measured reply — not a requirement. Switch later without touching the tree:

sudo bash install-model-switch.sh <model-id>

Check any candidate with one call shaped like the daemon sends (JSON object response format, max_tokens 600): a model without JSON mode returns 400 and every line falls back to clips, and a reasoning model can spend the whole budget thinking and return nothing.

Repository