v0.7.0 — vehicles, Borrowed Authority, and a door for the case generator

Since 0.6.1:

- VEHICLES as their own Item type: crew, seats, cargo, hull, armour, range,
  terrain and the skill that works them, with speed as a band. 14 of them, from
  the pool car and the Custodian van to a sealed crawler and the carriage that is
  already parked outside wherever you were going to go.
- STORES roughly doubled to 118 gear items across four eras — standing issue and
  paperwork, transport stores, and the forward stores Registry will not hand a
  probationary officer. Catalogue now 175 items, 231 icons.
- Agents leave creation properly equipped: standing issue, the posting's kit,
  what seniority adds, and one personal effect that is theirs and not the
  department's.
- All 25 postings now describe themselves in the creation dialog.
- BORROWED AUTHORITY, the access subsystem. No hacking skill and nothing to break
  into: access is a named credential with a scope, a Trust that erodes, and red
  flags describing how its real owner behaves. Inside scope there is no roll. Two
  tiers beyond is impossible at any skill. Coherence widens a record, and pushing
  one past what its Trust will carry merges your file with theirs.
- Defences graded by level, and damage now rolls at the level a blow landed at.
- Dodge's DEX x 2 base is finally evaluated; it read 0% for most postings.
- Brawl is a fallback rather than a peer of the weapon in hand.
- check-lang guard: one key that was both a value and a branch silently
  un-localised the entire system.
- The case generator is reachable from the Actor Directory, and no longer puts
  every character in the world on a new case.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
slaguru666
2026-08-10 20:23:52 +01:00
co-authored by Claude Opus 5
parent d0144f744e
commit 1734612c06
99 changed files with 154 additions and 139 deletions
+17
View File
@@ -3614,3 +3614,20 @@ began printing raw keys, with no error a user would ever connect to the cause. T
leaf is renamed, and `tools/check-lang.mjs` now fails the build on any key that is
both a value and a prefix of another, and on duplicate keys, which `JSON.parse`
swallows.
## The case generator gets a door
**R-219 · `missionDialog()` was exported, complete, and reachable from nothing.** The
entire case generator — anomalies, gaps, adversaries, phases, seeds — existed behind a
console call. The Actor Directory offered "New Agent" and "New NPC" and no way to make
a case. It now sits with the other two generators, because a case IS an actor and that
is where actors are made.
**R-220 · a new case conscripted every character in the world.** The roster fell back
to `game.actors.filter(a => a.type === "character")`, which is defensible in a world
holding one party and absurd in a world holding several — a freshly generated case
here listed thirty-six agents. The fallback exists for a real reason (a case with no
roster cannot resolve a phase, and `resolveLegDialog` bails silently), so it is now
ordered by how good the guess is: player-assigned characters first, then whatever the
GM has selected on the canvas, and the whole world only as a last resort — and it says
so when it does. Verified: with four tokens selected, the new case has four members.
+2
View File
@@ -723,6 +723,8 @@
"RINGBRP.Coh.Short": "Coh",
"RINGBRP.Sheet.Skill": "Skill",
"RINGBRP.Mission.Title": "Generate a case",
"RINGBRP.Mission.NewCase": "New Case",
"RINGBRP.Mission.RosterGuess": "No player characters are assigned and nothing is selected, so all {n} characters were put on this case. Edit the roster on the case file.",
"RINGBRP.Mission.Make": "Generate",
"RINGBRP.Mission.Roll": "— roll it —",
"RINGBRP.Mission.Class": "Classification",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "ringbrp",
"version": "1.0.0",
"version": "0.7.0",
"description": "The Custodians \u2014 a Basic Roleplaying game of crossings, for Foundry VTT",
"main": "ringbrp.mjs",
"scripts": {
Binary file not shown.
Binary file not shown.
View File
+1 -1
View File
@@ -1 +1 @@
MANIFEST-000007
MANIFEST-000004
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.102786 17970b000 Recovering log #6
2026/08/10-18:04:05.102816 17970b000 Level-0 table #8: started
2026/08/10-18:04:05.102965 17970b000 Level-0 table #8: 2303 bytes OK
2026/08/10-18:04:05.103319 17970b000 Delete type=0 #6
2026/08/10-18:04:05.103360 17970b000 Delete type=3 #4
2026/08/10-20:22:43.733467 171e23000 Recovering log #3
2026/08/10-20:22:43.733493 171e23000 Level-0 table #5: started
2026/08/10-20:22:43.733658 171e23000 Level-0 table #5: 1902 bytes OK
2026/08/10-20:22:43.734023 171e23000 Delete type=0 #3
2026/08/10-20:22:43.734059 171e23000 Delete type=3 #2
+1 -5
View File
@@ -1,5 +1 @@
2026/08/10-18:01:28.954232 174703000 Recovering log #3
2026/08/10-18:01:28.954258 174703000 Level-0 table #5: started
2026/08/10-18:01:28.954400 174703000 Level-0 table #5: 1902 bytes OK
2026/08/10-18:01:28.954676 174703000 Delete type=0 #3
2026/08/10-18:01:28.954726 174703000 Delete type=3 #2
2026/08/10-20:22:35.453598 1723af000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
View File
+1 -1
View File
@@ -1 +1 @@
MANIFEST-000007
MANIFEST-000004
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.115676 17970b000 Recovering log #6
2026/08/10-18:04:05.115702 17970b000 Level-0 table #8: started
2026/08/10-18:04:05.116502 17970b000 Level-0 table #8: 5058 bytes OK
2026/08/10-18:04:05.117326 17970b000 Delete type=0 #6
2026/08/10-18:04:05.118008 17970b000 Delete type=3 #4
2026/08/10-20:22:43.741301 17262f000 Recovering log #3
2026/08/10-20:22:43.741323 17262f000 Level-0 table #5: started
2026/08/10-20:22:43.741456 17262f000 Level-0 table #5: 4129 bytes OK
2026/08/10-20:22:43.741707 17262f000 Delete type=0 #3
2026/08/10-20:22:43.741744 17262f000 Delete type=3 #2
+1 -5
View File
@@ -1,5 +1 @@
2026/08/10-18:01:28.962448 17571b000 Recovering log #3
2026/08/10-18:01:28.962472 17571b000 Level-0 table #5: started
2026/08/10-18:01:28.962615 17571b000 Level-0 table #5: 4129 bytes OK
2026/08/10-18:01:28.962874 17571b000 Delete type=0 #3
2026/08/10-18:01:28.962919 17571b000 Delete type=3 #2
2026/08/10-20:22:35.478012 1723af000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
View File
+1 -1
View File
@@ -1 +1 @@
MANIFEST-000007
MANIFEST-000004
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.104689 177ee7000 Recovering log #6
2026/08/10-18:04:05.104840 177ee7000 Level-0 table #8: started
2026/08/10-18:04:05.105171 177ee7000 Level-0 table #8: 33311 bytes OK
2026/08/10-18:04:05.105428 177ee7000 Delete type=0 #6
2026/08/10-18:04:05.105470 177ee7000 Delete type=3 #4
2026/08/10-20:22:43.734698 172e3b000 Recovering log #3
2026/08/10-20:22:43.734790 172e3b000 Level-0 table #5: started
2026/08/10-20:22:43.735067 172e3b000 Level-0 table #5: 27954 bytes OK
2026/08/10-20:22:43.735279 172e3b000 Delete type=0 #3
2026/08/10-20:22:43.735322 172e3b000 Delete type=3 #2
+1 -5
View File
@@ -1,5 +1 @@
2026/08/10-18:01:28.955312 17571b000 Recovering log #3
2026/08/10-18:01:28.955407 17571b000 Level-0 table #5: started
2026/08/10-18:01:28.955661 17571b000 Level-0 table #5: 27954 bytes OK
2026/08/10-18:01:28.955877 17571b000 Delete type=0 #3
2026/08/10-18:01:28.955904 17571b000 Delete type=3 #2
2026/08/10-20:22:35.456036 172bbb000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
View File
+1 -1
View File
@@ -1 +1 @@
MANIFEST-000007
MANIFEST-000004
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.090247 178eff000 Recovering log #6
2026/08/10-18:04:05.090602 178eff000 Level-0 table #8: started
2026/08/10-18:04:05.091538 178eff000 Level-0 table #8: 76320 bytes OK
2026/08/10-18:04:05.092178 178eff000 Delete type=0 #6
2026/08/10-18:04:05.092254 178eff000 Delete type=3 #4
2026/08/10-20:22:43.726077 171e23000 Recovering log #3
2026/08/10-20:22:43.726308 171e23000 Level-0 table #5: started
2026/08/10-20:22:43.726763 171e23000 Level-0 table #5: 60660 bytes OK
2026/08/10-20:22:43.727036 171e23000 Delete type=0 #3
2026/08/10-20:22:43.727073 171e23000 Delete type=3 #2
+1 -5
View File
@@ -1,5 +1 @@
2026/08/10-18:01:28.946179 173ef7000 Recovering log #3
2026/08/10-18:01:28.946451 173ef7000 Level-0 table #5: started
2026/08/10-18:01:28.947084 173ef7000 Level-0 table #5: 60660 bytes OK
2026/08/10-18:01:28.947366 173ef7000 Delete type=0 #3
2026/08/10-18:01:28.947413 173ef7000 Delete type=3 #2
2026/08/10-20:22:35.466901 1723af000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
View File
+1 -1
View File
@@ -1 +1 @@
MANIFEST-000007
MANIFEST-000004
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.098553 17970b000 Recovering log #6
2026/08/10-18:04:05.098590 17970b000 Level-0 table #8: started
2026/08/10-18:04:05.098729 17970b000 Level-0 table #8: 3619 bytes OK
2026/08/10-18:04:05.099052 17970b000 Delete type=0 #6
2026/08/10-18:04:05.099134 17970b000 Delete type=3 #4
2026/08/10-20:22:43.730937 171e23000 Recovering log #3
2026/08/10-20:22:43.730959 171e23000 Level-0 table #5: started
2026/08/10-20:22:43.731083 171e23000 Level-0 table #5: 3295 bytes OK
2026/08/10-20:22:43.731312 171e23000 Delete type=0 #3
2026/08/10-20:22:43.731345 171e23000 Delete type=3 #2
+1 -5
View File
@@ -1,5 +1 @@
2026/08/10-18:01:28.951049 173ef7000 Recovering log #3
2026/08/10-18:01:28.951069 173ef7000 Level-0 table #5: started
2026/08/10-18:01:28.951162 173ef7000 Level-0 table #5: 3295 bytes OK
2026/08/10-18:01:28.951540 173ef7000 Delete type=0 #3
2026/08/10-18:01:28.951628 173ef7000 Delete type=3 #2
2026/08/10-20:22:35.473073 1723af000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
View File
+1 -1
View File
@@ -1 +1 @@
MANIFEST-000007
MANIFEST-000004
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.086831 178eff000 Recovering log #6
2026/08/10-18:04:05.087142 178eff000 Level-0 table #8: started
2026/08/10-18:04:05.087812 178eff000 Level-0 table #8: 69660 bytes OK
2026/08/10-18:04:05.088224 178eff000 Delete type=0 #6
2026/08/10-18:04:05.088274 178eff000 Delete type=3 #4
2026/08/10-20:22:43.723772 171e23000 Recovering log #3
2026/08/10-20:22:43.723973 171e23000 Level-0 table #5: started
2026/08/10-20:22:43.724492 171e23000 Level-0 table #5: 54921 bytes OK
2026/08/10-20:22:43.724852 171e23000 Delete type=0 #3
2026/08/10-20:22:43.724895 171e23000 Delete type=3 #2
+1 -5
View File
@@ -1,5 +1 @@
2026/08/10-18:01:28.940993 173ef7000 Recovering log #3
2026/08/10-18:01:28.941428 173ef7000 Level-0 table #5: started
2026/08/10-18:01:28.942350 173ef7000 Level-0 table #5: 54921 bytes OK
2026/08/10-18:01:28.943315 173ef7000 Delete type=0 #3
2026/08/10-18:01:28.943481 173ef7000 Delete type=3 #2
2026/08/10-20:22:35.462217 172bbb000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
View File
+1 -1
View File
@@ -1 +1 @@
MANIFEST-000007
MANIFEST-000004
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.107865 1786f3000 Recovering log #6
2026/08/10-18:04:05.107913 1786f3000 Level-0 table #8: started
2026/08/10-18:04:05.108138 1786f3000 Level-0 table #8: 17058 bytes OK
2026/08/10-18:04:05.108511 1786f3000 Delete type=0 #6
2026/08/10-18:04:05.108562 1786f3000 Delete type=3 #4
2026/08/10-20:22:43.737261 172e3b000 Recovering log #3
2026/08/10-20:22:43.737309 172e3b000 Level-0 table #5: started
2026/08/10-20:22:43.737540 172e3b000 Level-0 table #5: 18581 bytes OK
2026/08/10-20:22:43.737891 172e3b000 Delete type=0 #3
2026/08/10-20:22:43.737944 172e3b000 Delete type=3 #2
+1 -5
View File
@@ -1,5 +1 @@
2026/08/10-18:01:28.957762 17571b000 Recovering log #3
2026/08/10-18:01:28.957822 17571b000 Level-0 table #5: started
2026/08/10-18:01:28.958063 17571b000 Level-0 table #5: 16594 bytes OK
2026/08/10-18:01:28.958333 17571b000 Delete type=0 #3
2026/08/10-18:01:28.958373 17571b000 Delete type=3 #2
2026/08/10-20:22:35.476400 173bd3000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.094396 178eff000 Recovering log #3
2026/08/10-18:04:05.094453 178eff000 Level-0 table #5: started
2026/08/10-18:04:05.094771 178eff000 Level-0 table #5: 6679 bytes OK
2026/08/10-18:04:05.095121 178eff000 Delete type=0 #3
2026/08/10-18:04:05.095170 178eff000 Delete type=3 #2
2026/08/10-20:22:43.728284 171e23000 Recovering log #3
2026/08/10-20:22:43.728327 171e23000 Level-0 table #5: started
2026/08/10-20:22:43.728508 171e23000 Level-0 table #5: 6679 bytes OK
2026/08/10-20:22:43.728819 171e23000 Delete type=0 #3
2026/08/10-20:22:43.728856 171e23000 Delete type=3 #2
+1 -1
View File
@@ -1 +1 @@
2026/08/10-18:03:56.834116 16f923000 Delete type=3 #1
2026/08/10-20:22:35.439488 172bbb000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
View File
+1 -1
View File
@@ -1 +1 @@
MANIFEST-000007
MANIFEST-000004
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.110161 178eff000 Recovering log #6
2026/08/10-18:04:05.110222 178eff000 Level-0 table #8: started
2026/08/10-18:04:05.111347 178eff000 Level-0 table #8: 17462 bytes OK
2026/08/10-18:04:05.112445 178eff000 Delete type=0 #6
2026/08/10-18:04:05.112494 178eff000 Delete type=3 #4
2026/08/10-20:22:43.738727 173647000 Recovering log #3
2026/08/10-20:22:43.738770 173647000 Level-0 table #5: started
2026/08/10-20:22:43.739020 173647000 Level-0 table #5: 16892 bytes OK
2026/08/10-20:22:43.739311 173647000 Delete type=0 #3
2026/08/10-20:22:43.739337 173647000 Delete type=3 #2
+1 -5
View File
@@ -1,5 +1 @@
2026/08/10-18:01:28.959373 173ef7000 Recovering log #3
2026/08/10-18:01:28.959414 173ef7000 Level-0 table #5: started
2026/08/10-18:01:28.959665 173ef7000 Level-0 table #5: 16892 bytes OK
2026/08/10-18:01:28.960034 173ef7000 Delete type=0 #3
2026/08/10-18:01:28.960081 173ef7000 Delete type=3 #2
2026/08/10-20:22:35.471420 1733c7000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
View File
+1 -1
View File
@@ -1 +1 @@
MANIFEST-000007
MANIFEST-000004
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.113940 177ee7000 Recovering log #6
2026/08/10-18:04:05.113972 177ee7000 Level-0 table #8: started
2026/08/10-18:04:05.114101 177ee7000 Level-0 table #8: 4143 bytes OK
2026/08/10-18:04:05.114437 177ee7000 Delete type=0 #6
2026/08/10-18:04:05.114481 177ee7000 Delete type=3 #4
2026/08/10-20:22:43.740093 171e23000 Recovering log #3
2026/08/10-20:22:43.740113 171e23000 Level-0 table #5: started
2026/08/10-20:22:43.740221 171e23000 Level-0 table #5: 3739 bytes OK
2026/08/10-20:22:43.740519 171e23000 Delete type=0 #3
2026/08/10-20:22:43.740563 171e23000 Delete type=3 #2
+1 -5
View File
@@ -1,5 +1 @@
2026/08/10-18:01:28.961119 174703000 Recovering log #3
2026/08/10-18:01:28.961149 174703000 Level-0 table #5: started
2026/08/10-18:01:28.961300 174703000 Level-0 table #5: 3739 bytes OK
2026/08/10-18:01:28.961590 174703000 Delete type=0 #3
2026/08/10-18:01:28.961623 174703000 Delete type=3 #2
2026/08/10-20:22:35.469485 1723af000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.096436 1786f3000 Recovering log #3
2026/08/10-18:04:05.096490 1786f3000 Level-0 table #5: started
2026/08/10-18:04:05.096732 1786f3000 Level-0 table #5: 5105 bytes OK
2026/08/10-18:04:05.097123 1786f3000 Delete type=0 #3
2026/08/10-18:04:05.097170 1786f3000 Delete type=3 #2
2026/08/10-20:22:43.729734 172e3b000 Recovering log #3
2026/08/10-20:22:43.729768 172e3b000 Level-0 table #5: started
2026/08/10-20:22:43.729974 172e3b000 Level-0 table #5: 5105 bytes OK
2026/08/10-20:22:43.730252 172e3b000 Delete type=0 #3
2026/08/10-20:22:43.730302 172e3b000 Delete type=3 #2
+1 -1
View File
@@ -1 +1 @@
2026/08/10-18:03:56.837651 16e0ff000 Delete type=3 #1
2026/08/10-20:22:35.445214 1733c7000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
View File
+1 -1
View File
@@ -1 +1 @@
MANIFEST-000007
MANIFEST-000004
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.106622 17970b000 Recovering log #6
2026/08/10-18:04:05.106650 17970b000 Level-0 table #8: started
2026/08/10-18:04:05.106781 17970b000 Level-0 table #8: 5337 bytes OK
2026/08/10-18:04:05.106994 17970b000 Delete type=0 #6
2026/08/10-18:04:05.107040 17970b000 Delete type=3 #4
2026/08/10-20:22:43.736006 171e23000 Recovering log #3
2026/08/10-20:22:43.736029 171e23000 Level-0 table #5: started
2026/08/10-20:22:43.736168 171e23000 Level-0 table #5: 5012 bytes OK
2026/08/10-20:22:43.736419 171e23000 Delete type=0 #3
2026/08/10-20:22:43.736457 171e23000 Delete type=3 #2
+1 -5
View File
@@ -1,5 +1 @@
2026/08/10-18:01:28.956719 174703000 Recovering log #3
2026/08/10-18:01:28.956749 174703000 Level-0 table #5: started
2026/08/10-18:01:28.956901 174703000 Level-0 table #5: 5012 bytes OK
2026/08/10-18:01:28.957142 174703000 Delete type=0 #3
2026/08/10-18:01:28.957186 174703000 Delete type=3 #2
2026/08/10-20:22:35.458174 1733c7000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
View File
+1 -1
View File
@@ -1 +1 @@
MANIFEST-000007
MANIFEST-000004
+5 -5
View File
@@ -1,5 +1,5 @@
2026/08/10-18:04:05.100620 177ee7000 Recovering log #6
2026/08/10-18:04:05.100670 177ee7000 Level-0 table #8: started
2026/08/10-18:04:05.100975 177ee7000 Level-0 table #8: 8798 bytes OK
2026/08/10-18:04:05.101322 177ee7000 Delete type=0 #6
2026/08/10-18:04:05.101395 177ee7000 Delete type=3 #4
2026/08/10-20:22:43.732107 172e3b000 Recovering log #3
2026/08/10-20:22:43.732143 172e3b000 Level-0 table #5: started
2026/08/10-20:22:43.732280 172e3b000 Level-0 table #5: 7240 bytes OK
2026/08/10-20:22:43.732579 172e3b000 Delete type=0 #3
2026/08/10-20:22:43.732631 172e3b000 Delete type=3 #2
+1 -5
View File
@@ -1,5 +1 @@
2026/08/10-18:01:28.952703 17571b000 Recovering log #3
2026/08/10-18:01:28.952752 17571b000 Level-0 table #5: started
2026/08/10-18:01:28.952965 17571b000 Level-0 table #5: 7240 bytes OK
2026/08/10-18:01:28.953334 17571b000 Delete type=0 #3
2026/08/10-18:01:28.953396 17571b000 Delete type=3 #2
2026/08/10-20:22:35.450781 172bbb000 Delete type=3 #1
Binary file not shown.
Binary file not shown.
+41 -4
View File
@@ -2507,6 +2507,30 @@ export async function crossBack(actor, { aimedByAnother = false, aimedBy = null
* The journal is deliberately split brief / truth / opposition / phases / pressure,
* because the brief is the only page a player may see and it must be safe to show.
*/
/**
* Who is on a freshly generated case, in order of how good the guess is.
* Player-assigned characters first — that is the party — then the GM's current
* selection, and the whole world only if neither exists.
*/
function defaultRosterFor() {
const assigned = game.users.contents
.filter(u => u.active !== undefined && !u.isGM && u.character?.type === "character")
.map(u => u.character);
const uniq = [...new Map(assigned.map(a => [a.id, a])).values()];
if (uniq.length) return uniq;
const selected = canvas?.tokens?.controlled?.map(t => t.actor)
.filter(a => a?.type === "character") ?? [];
const uniqSel = [...new Map(selected.map(a => [a.id, a])).values()];
if (uniqSel.length) return uniqSel;
const all = game.actors.filter(a => a.type === "character");
if (all.length > 8) {
ui.notifications?.warn(game.i18n.format("RINGBRP.Mission.RosterGuess", { n: all.length }));
}
return all;
}
export async function generateMissionCase({ seed = null, notify = true, ...opts } = {}) {
const { generateMission, missionPages } = await import("./tools/mission.mjs");
const m = generateMission({ seed, ...opts });
@@ -2550,8 +2574,12 @@ export async function generateMissionCase({ seed = null, notify = true, ...opts
notes: `<p><strong>${m.codename}</strong> — ${m.classification.name}. ${m.place}.</p>`
+ `<p>${m.anomaly.brief}</p>`,
// A case with nobody assigned cannot resolve a phase: resolveLegDialog needs
// a roster to pick a lead from and bails silently without one.
members: (opts.members ?? game.actors.filter(a => a.type === "character")).map(a => a.id),
// a roster to pick a lead from and bails silently without one. But the old
// fallback was EVERY character in the world, which in a world holding more
// than one party quietly put thirty-six people on a four-agent case. Prefer
// the actors players are actually assigned to, then whatever the GM has
// selected, and only conscript the world as a last resort.
members: (opts.members ?? defaultRosterFor()).map(a => a.id),
standings: [],
// read by returnCrossing; the brief promises it, so the return must charge it
crossingModifier: m.crossingModifier,
@@ -3902,12 +3930,21 @@ Hooks.on("renderActorDirectory", (app, html) => {
if (!root || !game.user.isGM || root.querySelector(".rb-genbar")) return;
const bar = document.createElement("div");
bar.className = "rb-genbar";
// R-219. missionDialog() was exported, complete, and reachable from nothing — the
// whole case generator existed behind a console call. It sits with the other two
// generators, because a case IS an actor and this is where actors are made.
bar.innerHTML = `<button type="button" class="rb-genbtn" data-kind="character">${
game.i18n.localize("RINGBRP.Gen.NewAgent")}</button>
<button type="button" class="rb-genbtn" data-kind="npc">${
game.i18n.localize("RINGBRP.Gen.NewNPC")}</button>`;
game.i18n.localize("RINGBRP.Gen.NewNPC")}</button>
<button type="button" class="rb-genbtn rb-genbtn-case" data-kind="case">${
game.i18n.localize("RINGBRP.Mission.NewCase")}</button>`;
bar.querySelectorAll("button").forEach(b =>
b.addEventListener("click", () => generateDialog(b.dataset.kind)));
b.addEventListener("click", async () => {
if (b.dataset.kind !== "case") return generateDialog(b.dataset.kind);
const cf = await missionDialog();
if (cf) cf.sheet?.render(true);
}));
(root.querySelector(".directory-header") ?? root).prepend(bar);
});
+3
View File
@@ -1239,3 +1239,6 @@
.rb-dossier { border-left: 3px solid var(--rb-line); padding-left: 8px; }
.rb-dossier-miss { opacity: .7; }
.rb-authuse .rb-check { display: block; font-size: 11px; margin: 2px 0; }
/* The case generator sits with the others but is the one that makes a whole case. */
.rb-genbtn-case { border-color: var(--rb-yellow); color: var(--rb-yellow); }
+1 -1
View File
@@ -2,7 +2,7 @@
"id": "ringbrp",
"title": "The Custodians",
"description": "A Basic Roleplaying game of agents who cross the crossing to contain what should not be there \u2014 and who come back a little less from here each time.",
"version": "0.6.1",
"version": "0.7.0",
"compatibility": {
"minimum": 13,
"verified": "14.364"