Ledger v3 · C# · Godot 4.7 Get started
The author's guide

Scope: one kind, or every kind

A game's content has two kinds of lines. The rules for all: the rate, the stats, the pools, the links, the tags, and the effects every actor holds (Mortal here). One kind: an archetype and what only it grants or has (Fighter, its Strike). A request about one kind changes that kind's lines, and nothing every actor reads.

content/GAME.ledger
# GAME: two sides, a fighter each. The game walks each fighter toward the other, and a fighter strikes what it can
# reach. These are the rules every actor reads (the stats, the pool, the sides) and the one kind, the Fighter: a
# request about the Fighter alone changes the Fighter, not the rules above it.

rate 20
stat MaxHealth
stat MoveSpeed
pool Health max MaxHealth
damage Health
link team
allegiance team
tags Unit Attack
event Died

archetype Side

# an actor at 0 health dies: told, then gone
effect Mortal
  after Depleted Health of holder
    raise Died of holder
    destroy holder

ability Strike
  tags Attack
  target one enemy within 2
  cooldown 1s
  deal 10 to target

archetype Fighter
  tags Unit
  base MaxHealth 50
  base MoveSpeed 4
  full Health
  has Mortal
  grants Strike

"Fighters heal 1 a second" is a request about the Fighter: an effect only the Fighter has (ledger forms gives its spelling), not a regen on pool Health, which every kind with Health reads. If the game later adds a second kind, the change stays on the Fighter. Plays catch a wrong number but not a wrong scope: a change to the shared rules passes every play written for the one kind, and reaches every other kind besides.

Before you change a line, ask who reads it. A line above the first archetype, or an effect more than one archetype has, is read by every kind that holds it: grep the content for its name.

From ledger-v3's guide/ledger-author/scope.md, last changed 2026-10-26.