Wiki: player-facing rewrite of every layer + add a scenario FAQ, linked from Home

This commit is contained in:
flan
2026-07-16 02:18:25 +00:00
parent ff703271ba
commit 8250dcb369
32 changed files with 1654 additions and 2510 deletions
+80 -107
View File
@@ -1,70 +1,63 @@
# Improvised Weapons
*The acquisition route you cannot deny — because you are obliged to furnish the cell, and the
furniture is the raw material.*
*The supply route you cannot deny — because you are obliged to furnish the cell, and the furniture is
the raw material.*
You have to give a prisoner a bed. RimWorld will nag you until you do. That bed is a frame of wood,
or steel, or — if you built a nice prison — plasteel. Give a disposed prisoner a season of
unsupervised time with it and they will file a blade off it. **The prison's own furnishings are the
arsenal, and better furniture is worse.**
You have to give a prisoner a bed. RimWorld will nag you until you do. That bed is a frame of wood, or
steel, or — if you built a nice prison — plasteel. Give a disposed prisoner a season of unsupervised
time with it and they will file a blade off it. **The prison's own furnishings are the arsenal, and
better furniture is worse.**
## The shiv
`CB_Shiv` is a crude stabbing weapon: *"A blade filed off a bed frame and wrapped in cloth for a
grip. Barely a weapon — but a barely-a-weapon in a cell you thought was empty is a dead guard."*
The shiv is a crude stabbing weapon: *"A blade filed off a bed frame and wrapped in cloth for a grip.
Barely a weapon — but a barely-a-weapon in a cell you thought was empty is a dead guard."*
| Stat | Value |
|---|---|
| Tech level | Neolithic |
| Mass | 0.4 kg |
| `concealability` | **0.75** (hides very well — it rides on the body) |
| `hideIn` | `OnBody \| InCell` |
| Concealability | **0.75** (hides very well — it rides on the body) |
| Hides | on body or in cell |
| Point (Stab) | power 7, cooldown 1.5 s |
| Handle (Blunt) | power 5, cooldown 1.6 s |
| `acquireWorker` | `AcquireWorker_Improvise` |
| `useWorker` | none — an armed prisoner *is* the payload |
| Use | none — an armed prisoner *is* the payload |
It is **stuffable** (`stuffCategories`: Metallic, Woody, Stony), which is the entire point of the
harvest mechanic: a shiv's stats come from its material for free. A wood shiv is feeble; a plasteel
one is vicious. You never furnished a cell thinking of it as an armoury, but that is what it is.
Its stats come from its material: it can be made of metal, wood, or stone. A wood shiv is feeble; a
plasteel one is vicious. That is the whole point of the harvest mechanic — you never furnished a cell
thinking of it as an armoury, but that is what it is.
## Who whittles: the disposition gate
`AcquireWorker_Improvise.CanAcquire` is not "any prisoner." Three things must all be true:
Not just "any prisoner." Three things must all be true:
1. **Held.** The pawn is a prisoner, slave, or ward patient (`IsHeld`). Free colonists do not whittle
shivs in the commons — *yet* (the concealment layer already tracks them; only the authority to act
on them is missing).
2. **Disposed.** A seeded propensity roll:
```
Propensity.Would(pawn, 0.10, SaltImprovise)
```
Base chance **0.10**, scaled by Core's nature × nurture. It is seeded per pawn, so it is a *fixed
fact* about them — the mistreated, high-propensity lifer chews his bed apart; the frightened cook
1. **Held.** The pawn is a prisoner, slave, or ward patient. Free colonists do not whittle shivs in
the commons — *yet* (the concealment layer already tracks them; only the authority to act on them
is missing).
2. **Disposed.** A base chance of **0.10**, scaled by Core's nature × nurture. It is a *fixed fact*
about the pawn — the mistreated, high-propensity lifer chews his bed apart; the frightened cook
never does, and never would have, no matter how many times you reload.
3. **Material in reach.** There is a workable source (see below).
The base is deliberately low. Most prisoners are not making weapons. When one is, that is a fact
about *who they are and how you keep them*, and the tell it leaves is meant to point you at exactly
that pawn.
The base is deliberately low. Most prisoners are not making weapons. When one is, that is a fact about
*who they are and how you keep them*, and the tell it leaves is meant to point you at exactly that
pawn.
## The source: what counts as raw material
`FindSource` looks for the nearest reachable, damageable, usefully-stuffed piece of furniture:
The prisoner looks for the nearest reachable, damageable, usefully-made piece of furniture:
- **Their own assigned bed first** — it is right there in the cell.
- Otherwise the **closest artificial building within 12 tiles** that qualifies.
`IsWorkableSource` requires all of:
To be a workable source, a piece of furniture must be:
| Requirement | Why |
|---|---|
| Made of `Stuff` | you cannot whittle a blade out of nothing |
| `useHitPoints` | it has to be damageable |
| Stuff category is **Metallic, Woody, or Stony** | cloth and leather cannot be filed into a blade |
| Reachable at `Touch` through `Danger.Deadly` | they have to get to it |
| Made of a material | you cannot whittle a blade out of nothing |
| Damageable | it has to take a beating |
| Made of metal, wood, or stone | cloth and leather cannot be filed into a blade |
| Reachable, even through danger | they have to get to it |
This is also the counter-play. A cell furnished only in cloth and hydroponics offers nothing to file.
A steel bed offers a steel shiv. **What you build the cell out of decides whether it can become a
@@ -72,71 +65,54 @@ weapon, and how nasty that weapon is.**
## Harvest by damage: the tell *is* the mechanic
Each poll the pawn makes progress, `OnHarvestTick` chips at the source:
Each heartbeat, a whittling prisoner chips at the source — roughly **1.2% of its max hit points per
worked poll**, as blunt damage.
```
damage = max(1, round(source.MaxHitPoints × 0.012)) // Blunt, ~1.2% of max HP per worked poll
```
The damage is not a side effect — it is the point. A gnawed bed is **probable cause**. The same
poll that advances the shiv damages the furniture, and that visible wear is what
[Warden Search](Warden-Search.md) reads to send a guard to the *right* prisoner first: a badly
damaged bed shoots a prisoner to the top of the search priority list. Whittling a shiv is loud, in
the only sense that matters — it leaves a mark you can act on.
The damage is not a side effect — it is the point. A gnawed bed is **probable cause**. The same tick
that advances the shiv damages the furniture, and that visible wear is what
[Warden Search](Warden-Search.md) reads to send a guard to the *right* prisoner first: a badly damaged
bed shoots a prisoner to the top of the search priority list. Whittling a shiv is loud, in the only
sense that matters — it leaves a mark you can act on.
Because the source takes real damage, a determined prisoner can **reduce a piece of furniture to
wreckage and move on to the next**: if the source is destroyed before the shiv is finished,
`FindSource` looks for another, and if there is none, the route **stalls** (progress is kept, not
lost). A materially poor cell is a real defence — the prisoner cannot make progress with nothing to
file.
wreckage and move on to the next**: if the source is destroyed before the shiv is finished, they look
for another, and if there is none, the route **stalls** (progress is kept, not lost). A materially
poor cell is a real defence — the prisoner cannot make progress with nothing to file.
## How long, and the material it becomes
Progress uses the default rate — roughly **1.5 unsupervised days** of active work — jittered ±25%
each poll so no two shivs finish on the same schedule:
A shiv takes roughly **1.5 unsupervised days** of active work, jittered ±25% each poll so no two
shivs finish on the same schedule.
```
progressPerPoll = 250 / (1.5 × 60000) × Rand.Range(0.75, 1.25)
```
When it is finished, it happens **silently** — the player is told nothing. Two things happen:
When progress reaches 1, the shiv is finished, **silently** — the player is told nothing. Two things
happen:
- **Material carry-through.** `item.stuff = source.Stuff`. A wood bed yields a wood shiv, a plasteel
bunk a plasteel one. When the shiv is later redeemed into a real `Thing`, it is made of exactly
that material, and its combat stats follow.
- **The record.** `CriminalRecord.contrabandMade` is incremented (Core's record). That number feeds
- **Material carry-through.** The shiv is made of whatever the source was made of. A wood bed yields a
wood shiv, a plasteel bunk a plasteel one, and its combat stats follow.
- **The record.** The pawn's tally of contraband made ticks up (in Core's record). That number feeds
the warden's future suspicion of this pawn and, if you run **Institution: Justice**, their security
classification.
## The shiv comes out in a break — and who reaches for it
A hidden shiv is inert until a breakout. When a prisoner enters the `PrisonerEscape` or
`PrisonerAssaultColony` duty, `JobGiver_UseContraband` offers to materialise what they are hiding —
but a **weapon** only comes out for someone who would actually use it. That test is
`Disposition.WouldArmSelf`, and it is the same gate `JobGiver_ArmSelf` uses to decide whether an
escapee even bothers to pick a weapon off the floor.
A hidden shiv is inert until a breakout. When a prisoner enters an escape or assault-the-colony state,
they will use what they are hiding — but a **weapon** only comes out for someone who would actually
use it. That is the same test that decides whether an escapee even bothers to pick a weapon off the
floor.
This matters because **vanilla escapees never arm themselves at all.**
`JobGiver_PickUpOpportunisticWeapon` exists and is simply absent from the escape duty tree, so a
base-game prisoner walks out unarmed, always. Arming is genuinely new behaviour, so it is kept rare
enough that when it happens you recognise *who* did it.
This matters because **vanilla escapees never arm themselves at all.** The base game has the behaviour
for opportunistically grabbing a weapon, and simply leaves it out of the escape flow, so a base-game
prisoner walks out unarmed, always. Arming is genuinely new behaviour, so it is kept rare enough that
when it happens you recognise *who* did it.
### `WouldArmSelf`
### Would this pawn arm itself?
First a **hard gate**: a pawn who `WorkTagIsDisabled(Violent)` never arms, ever — a pacifist who
picks up a rifle is not a rare event, it is a bug. Otherwise:
First a **hard gate**: a pawn who is incapable of violence never arms, ever — a pacifist who picks up
a rifle is not a rare event, it is a bug. Otherwise the chance is the pawn's **disposition** (who they
are, fixed) times their **circumstance** (what is happening right now), capped at **0.85** and settled
once per pawn as a fixed fact.
```
chance = ArmDisposition(pawn) × ArmCircumstance(pawn)
armed = WouldSeeded(pawn, min(chance, 0.85), SaltArm) // seeded — a fixed fact per pawn
```
**Disposition** — who they are, fixed, nothing about today changes it:
```
ArmDisposition = 0.10 (base) × trait × skill
```
**Disposition** — who they are, fixed, nothing about today changes it. A base of 0.10, scaled by trait
and skill:
| Factor | Value |
|---|---|
@@ -145,12 +121,12 @@ ArmDisposition = 0.10 (base) × trait × skill
| Brawler | ×1.8 |
| Wimp | ×0.3 |
| Kind | ×0.4 |
| skill | `0.5 + max(Shooting, Melee)/20 × 1.5` → range **0.5 .. 2.0** |
| skill | scales with their best of Shooting or Melee → range **0.5 .. 2.0** |
*Being captured in a raid does not make someone a fighter* — plenty of prisoners are cooks and
conscripts. A weapon is only worth grabbing if you know what to do with it, hence the skill term.
**Circumstance** — what is happening right now, live, not seeded:
**Circumstance** — what is happening right now, live:
| Condition | Effect | Reasoning |
|---|---|---|
@@ -160,38 +136,36 @@ conscripts. A weapon is only worth grabbing if you know what to do with it, henc
### Which weapon they reach for
`JobGiver_ArmSelf` prefers, in order:
An arming escapee prefers, in order:
1. **Their own dropped weapon** — the gun they carried when you downed them, still lying where it
fell within 45 tiles. Vanilla remembers it in `Pawn_MindState.droppedWeapon` and then never uses
the field for prisoners. *"A man walking back to the spot where his own rifle fell is a better
story than a man rummaging through your stockpile."* A prisoner does not care that you marked it
forbidden.
2. **Anything to hand** within 18 tiles — but only for a pawn over a higher disposition floor
(`WouldSeeded(pawn, 0.35, …)`). Rummaging a stockpile is a further step than grabbing your own gun
back.
1. **Their own dropped weapon** — the gun they carried when you downed them, still lying where it fell
within 45 tiles. The base game remembers where it fell and then never uses that for prisoners. *"A
man walking back to the spot where his own rifle fell is a better story than a man rummaging through
your stockpile."* A prisoner does not care that you marked it forbidden.
2. **Anything to hand** within 18 tiles — but only for a pawn over a higher disposition floor (0.35).
Rummaging a stockpile is a further step than grabbing your own gun back.
A concealed shiv slots into this the natural way: a prisoner who has been sitting on a blade and who
is the sort to use it does not leave it in his pocket. `JobGiver_UseContraband` redeems it and moves
it straight from inventory into the equipment slot. The pawn who would *not* arm keeps it hidden and
runs — and the shiv survives to be found in a later search, or used in a later break.
A concealed shiv slots into this the natural way: a prisoner who has been sitting on a blade and who is
the sort to use it does not leave it in his pocket — it goes straight into his hand. The pawn who
would *not* arm keeps it hidden and runs — and the shiv survives to be found in a later search, or
used in a later break.
## Not only shivs: the crude pick
`AcquireWorker_Improvise` is shared. The **crude pick** (`CB_DiggingTool`) is filed off furniture
exactly the same way — same disposition gate, same damage tell — but it carries an `escapeWorker`
instead of weapon stats, and its purpose is a tunnel rather than a fight. See [Tunnels](Tunnels.md).
The same whittling behaviour makes the **crude pick** — filed off furniture exactly the same way, with
the same disposition gate and the same damage tell — but its purpose is a tunnel rather than a fight.
See [Tunnels](Tunnels.md).
## Quick reference
| Constant | Value | Meaning |
|---|---|---|
| Improvise base chance | 0.10 | before nature × nurture; seeded per pawn |
| Damage per worked poll | ~1.2% of source max HP | Blunt; the visible tell |
| Improvise base chance | 0.10 | before nature × nurture; fixed per pawn |
| Damage per worked poll | ~1.2% of source max HP | blunt; the visible tell |
| Source search radius | 12 tiles | own bed first, then nearest workable furniture |
| Time to finish a shiv | ~1.5 active days | jittered ±25% per poll |
| Workable stuff | Metallic / Woody / Stony | cloth and leather cannot be whittled |
| Shiv `concealability` | 0.75 | hard to find on the body |
| Workable material | metal / wood / stone | cloth and leather cannot be whittled |
| Shiv concealability | 0.75 | hard to find on the body |
| Arm chance cap | 0.85 | after disposition × circumstance |
| Own-weapon reach | 45 tiles | their dropped weapon |
| Any-weapon reach | 18 tiles | scavenge floor 0.35 disposition |
@@ -200,4 +174,3 @@ instead of weapon stats, and its purpose is a tunnel rather than a fight. See [T
*Part of the **Institution** suite — Core · Contraband · Justice · Gangs, alongside Foul Play and
Ward. Each stands alone; together they interlock.*
**