rpg-engine 0.20.0 → 0.21.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (160) hide show
  1. package/dist/adventures/index.d.ts +1 -1
  2. package/dist/adventures/index.js +1 -1
  3. package/dist/adventures/source.d.ts +3 -0
  4. package/dist/adventures/source.js +11 -49
  5. package/dist/campaign/create-campaign.d.ts +1 -1
  6. package/dist/campaign/create-campaign.js +3 -2
  7. package/dist/campaign/find-campaign.d.ts +2 -0
  8. package/dist/campaign/find-campaign.js +2 -0
  9. package/dist/campaign/index.d.ts +1 -1
  10. package/dist/campaign/index.js +1 -1
  11. package/dist/campaign/settings.js +2 -2
  12. package/dist/commands/book.d.ts +16 -35
  13. package/dist/commands/book.js +86 -62
  14. package/dist/commands/config/config.js +1 -1
  15. package/dist/commands/config/dashboard.d.ts +2 -2
  16. package/dist/commands/config/dashboard.js +9 -3
  17. package/dist/commands/config/words.js +1 -1
  18. package/dist/commands/image.d.ts +5 -0
  19. package/dist/commands/image.js +6 -3
  20. package/dist/commands/package/data.d.ts +35 -0
  21. package/dist/commands/package/data.js +117 -0
  22. package/dist/commands/package/here.d.ts +7 -2
  23. package/dist/commands/package/here.js +23 -11
  24. package/dist/commands/package/install.js +14 -15
  25. package/dist/commands/package/language.d.ts +15 -0
  26. package/dist/commands/package/language.js +109 -0
  27. package/dist/commands/package/package.js +20 -10
  28. package/dist/commands/package/result.d.ts +19 -0
  29. package/dist/commands/package/theme.d.ts +13 -0
  30. package/dist/commands/package/theme.js +66 -0
  31. package/dist/commands/package/uninstall.d.ts +4 -1
  32. package/dist/commands/package/uninstall.js +29 -9
  33. package/dist/commands/scene/close.d.ts +1 -1
  34. package/dist/commands/scene/close.js +15 -8
  35. package/dist/commands/shared/books/adventures.d.ts +0 -4
  36. package/dist/commands/shared/books/adventures.js +2 -31
  37. package/dist/commands/shared/books/words.js +3 -2
  38. package/dist/commands/shared/campaign/book.d.ts +21 -8
  39. package/dist/commands/shared/campaign/book.js +65 -42
  40. package/dist/commands/shared/campaign/saves.js +2 -2
  41. package/dist/commands/shared/campaign/world.js +2 -1
  42. package/dist/commands/shared/packages/catalog.d.ts +3 -3
  43. package/dist/commands/shared/packages/catalog.js +98 -42
  44. package/dist/commands/shared/packages/unpacked.d.ts +50 -0
  45. package/dist/commands/shared/packages/unpacked.js +146 -0
  46. package/dist/core/archive.d.ts +13 -0
  47. package/dist/core/archive.js +76 -0
  48. package/dist/core/context.d.ts +2 -0
  49. package/dist/core/context.js +1 -0
  50. package/dist/core/store.d.ts +5 -1
  51. package/dist/core/store.js +15 -2
  52. package/dist/dashboard/api.js +24 -1
  53. package/dist/dashboard/app.js +7 -2
  54. package/dist/dashboard/guide/ar.md +8 -8
  55. package/dist/dashboard/guide/cs.md +8 -8
  56. package/dist/dashboard/guide/da.md +9 -9
  57. package/dist/dashboard/guide/de.md +8 -8
  58. package/dist/dashboard/guide/el.md +8 -8
  59. package/dist/dashboard/guide/en.md +7 -7
  60. package/dist/dashboard/guide/es.md +8 -8
  61. package/dist/dashboard/guide/fi.md +8 -8
  62. package/dist/dashboard/guide/fr.md +8 -8
  63. package/dist/dashboard/guide/he.md +8 -8
  64. package/dist/dashboard/guide/hi.md +8 -8
  65. package/dist/dashboard/guide/hu.md +8 -8
  66. package/dist/dashboard/guide/is.md +8 -8
  67. package/dist/dashboard/guide/it.md +8 -8
  68. package/dist/dashboard/guide/ja.md +8 -8
  69. package/dist/dashboard/guide/ko.md +8 -8
  70. package/dist/dashboard/guide/nb.md +9 -9
  71. package/dist/dashboard/guide/nl.md +8 -8
  72. package/dist/dashboard/guide/pl.md +8 -8
  73. package/dist/dashboard/guide/pt.md +8 -8
  74. package/dist/dashboard/guide/ro.md +8 -8
  75. package/dist/dashboard/guide/ru.md +9 -9
  76. package/dist/dashboard/guide/sv.md +8 -8
  77. package/dist/dashboard/guide/tr.md +8 -8
  78. package/dist/dashboard/guide/uk.md +9 -9
  79. package/dist/dashboard/guide/zh.md +8 -8
  80. package/dist/dashboard/i18n/ar.json +33 -5
  81. package/dist/dashboard/i18n/cs.json +33 -5
  82. package/dist/dashboard/i18n/da.json +33 -5
  83. package/dist/dashboard/i18n/de.json +33 -5
  84. package/dist/dashboard/i18n/el.json +33 -5
  85. package/dist/dashboard/i18n/es.json +33 -5
  86. package/dist/dashboard/i18n/fi.json +33 -5
  87. package/dist/dashboard/i18n/fr.json +33 -5
  88. package/dist/dashboard/i18n/he.json +33 -5
  89. package/dist/dashboard/i18n/hi.json +33 -5
  90. package/dist/dashboard/i18n/hu.json +33 -5
  91. package/dist/dashboard/i18n/is.json +33 -5
  92. package/dist/dashboard/i18n/it.json +33 -5
  93. package/dist/dashboard/i18n/ja.json +33 -5
  94. package/dist/dashboard/i18n/ko.json +33 -5
  95. package/dist/dashboard/i18n/nb.json +33 -5
  96. package/dist/dashboard/i18n/nl.json +33 -5
  97. package/dist/dashboard/i18n/pl.json +33 -5
  98. package/dist/dashboard/i18n/pt.json +33 -5
  99. package/dist/dashboard/i18n/ro.json +33 -5
  100. package/dist/dashboard/i18n/ru.json +33 -5
  101. package/dist/dashboard/i18n/sv.json +33 -5
  102. package/dist/dashboard/i18n/tr.json +33 -5
  103. package/dist/dashboard/i18n/uk.json +33 -5
  104. package/dist/dashboard/i18n/zh.json +33 -5
  105. package/dist/dashboard/journal/book.js +3 -2
  106. package/dist/dashboard/journal/journal.js +8 -5
  107. package/dist/dashboard/kit.js +1 -1
  108. package/dist/dashboard/packages/catalog.js +31 -14
  109. package/dist/dashboard/packages/engine.js +46 -2
  110. package/dist/dashboard/packages/installed.js +13 -0
  111. package/dist/dashboard/packages/outcomes.js +21 -0
  112. package/dist/dashboard/packages/packages.js +41 -18
  113. package/dist/dashboard/packages/rows.js +3 -1
  114. package/dist/dashboard/parts/icons.js +3 -0
  115. package/dist/dashboard/parts/picture.js +89 -0
  116. package/dist/dashboard/parts/refusals.js +8 -1
  117. package/dist/dashboard/parts/widgets.js +2 -1
  118. package/dist/dashboard/play/scene.js +8 -5
  119. package/dist/dashboard/settings/settings.js +23 -13
  120. package/dist/dashboard/sheet/party.js +5 -2
  121. package/dist/dashboard/sheet/sheet.js +2 -1
  122. package/dist/dashboard/shell/notices.js +2 -2
  123. package/dist/dashboard/shell/system-style.js +45 -12
  124. package/dist/dashboard/shell/tooltip.js +223 -0
  125. package/dist/dashboard/style.css +283 -132
  126. package/dist/dashboard/world/lore.js +4 -3
  127. package/dist/dashboard/world/place-card.js +2 -1
  128. package/dist/languages/index.d.ts +1 -1
  129. package/dist/languages/index.js +1 -1
  130. package/dist/languages/pack.d.ts +4 -1
  131. package/dist/languages/pack.js +16 -5
  132. package/dist/packages/engine.d.ts +7 -0
  133. package/dist/packages/engine.js +32 -1
  134. package/dist/packages/index.d.ts +1 -1
  135. package/dist/packages/index.js +1 -1
  136. package/dist/server/dashboard/engine.d.ts +18 -0
  137. package/dist/server/dashboard/engine.js +31 -0
  138. package/dist/server/dashboard/files.d.ts +8 -1
  139. package/dist/server/dashboard/files.js +30 -10
  140. package/dist/server/dashboard/index.d.ts +3 -0
  141. package/dist/server/dashboard/index.js +10 -1
  142. package/dist/server/dashboard/pictures.d.ts +7 -0
  143. package/dist/server/dashboard/pictures.js +62 -0
  144. package/dist/server/dashboard/writes.d.ts +5 -3
  145. package/dist/server/dashboard/writes.js +45 -14
  146. package/dist/testing/index.js +1 -0
  147. package/dist/themes/index.d.ts +2 -1
  148. package/dist/themes/index.js +4 -2
  149. package/dist/themes/installed.d.ts +14 -0
  150. package/dist/themes/installed.js +28 -0
  151. package/dist/themes/theme.d.ts +7 -0
  152. package/dist/themes/theme.js +22 -0
  153. package/instructions/core.md +3 -3
  154. package/instructions/dashboard-guide.md +1 -0
  155. package/instructions/mentor-hints.md +1 -1
  156. package/instructions/mentor-tutorial.md +1 -1
  157. package/instructions/party.md +1 -1
  158. package/instructions/play.md +2 -2
  159. package/package.json +1 -1
  160. package/systems/free/instructions/outcomes-told.md +1 -1
@@ -1,4 +1,6 @@
1
- // The dashboard's themes (D-527, D-528): a folder of data a game system names, read and checked here, its CSS of custom properties written here.
1
+ // The dashboard's themes (D-527, D-528): a folder of data a game system names, or a package of its own installed on this computer, read and checked here,
2
+ // its CSS of custom properties written here.
2
3
  export { contrast } from "./contrast.js";
3
4
  export { themeCss } from "./css.js";
4
- export { drawnOrnament, readTheme, themeFile, themeFileName, themeIconNames } from "./theme.js";
5
+ export { installedThemes, isThemeId, themeId } from "./installed.js";
6
+ export { drawnOrnament, readTheme, themeFile, themeFileName, themeFilesNamed, themeIconNames } from "./theme.js";
@@ -0,0 +1,14 @@
1
+ import { type Theme } from "./theme.ts";
2
+ /** A theme installed on this computer: its id, which names its folder and its address; the theme when it passes its checks, else what to fix, each a line. */
3
+ export interface InstalledTheme {
4
+ id: string;
5
+ folder: string;
6
+ theme?: Theme;
7
+ problems: string[];
8
+ }
9
+ /** The themes in this folder, by their id; one refused is listed with its problems, for the player to see why it is not offered. */
10
+ export declare function installedThemes(folder: string): InstalledTheme[];
11
+ /** Whether a text is a theme's id: lowercase letters and digits, joined by hyphens. */
12
+ export declare function isThemeId(text: string): boolean;
13
+ /** The id of a theme by its name, lowercase letters, digits and hyphens: Old Parchment is old-parchment; a name without such letters, by a print of it. */
14
+ export declare function themeId(name: string): string;
@@ -0,0 +1,28 @@
1
+ // The themes installed on this computer for every campaign, as packages of data alone: each in a folder of its own named by its id, read and checked as a
2
+ // game system's theme is.
3
+ import { createHash } from "node:crypto";
4
+ import { join } from "node:path";
5
+ import { files } from "../core/store.js";
6
+ import { readTheme } from "./theme.js";
7
+ // What an id is made of; a folder being unpacked starts with a dot, and is none.
8
+ const idPattern = /^[a-z0-9]+(-[a-z0-9]+)*$/;
9
+ /** The themes in this folder, by their id; one refused is listed with its problems, for the player to see why it is not offered. */
10
+ export function installedThemes(folder) {
11
+ return files().entries(folder)
12
+ .filter((entry) => entry.isFolder && idPattern.test(entry.name))
13
+ .map((entry) => entry.name)
14
+ .sort()
15
+ .map((id) => {
16
+ const path = join(folder, id);
17
+ return { id, folder: path, ...readTheme(path) };
18
+ });
19
+ }
20
+ /** Whether a text is a theme's id: lowercase letters and digits, joined by hyphens. */
21
+ export function isThemeId(text) {
22
+ return idPattern.test(text);
23
+ }
24
+ /** The id of a theme by its name, lowercase letters, digits and hyphens: Old Parchment is old-parchment; a name without such letters, by a print of it. */
25
+ export function themeId(name) {
26
+ const id = name.normalize("NFKD").replace(/[̀-ͯ]/g, "").toLowerCase().replace(/[^a-z0-9]+/g, "-").slice(0, 64).replace(/^-+|-+$/g, "");
27
+ return id === "" ? `theme-${createHash("sha256").update(name).digest("hex").slice(0, 8)}` : id;
28
+ }
@@ -14,6 +14,8 @@ type ColourName = (typeof requiredColours)[number] | (typeof optionalColours)[nu
14
14
  /** A theme as read, its files checked and its derived colours filled in. */
15
15
  export interface Theme {
16
16
  name: string;
17
+ /** Its version, as a theme installed on its own gives it. */
18
+ version?: string;
17
19
  /** The folder it was read from: its files are served from there. */
18
20
  folder: string;
19
21
  fonts: ThemeFont[];
@@ -66,6 +68,11 @@ export interface ThemeReading {
66
68
  export declare function readTheme(folder: string): ThemeReading;
67
69
  /** The real path of a file of a theme's folder, only when it is one and inside it, links resolved: what the dashboard serves. */
68
70
  export declare function themeFile(folder: string, name: string): string | undefined;
71
+ /**
72
+ * The files a theme.yaml names, with forward slashes, as written from its folder: its fonts and their licences, its ornament, icons and textures. None when
73
+ * it does not read: its checks say why.
74
+ */
75
+ export declare function themeFilesNamed(text: string): string[];
69
76
  /** An ornament drawn in one colour, turned for a page that reads right to left: the theme gives one drawing for both modes and both directions. */
70
77
  export declare function drawnOrnament(svg: string, ink: string, mirrored: boolean): string;
71
78
  export {};
@@ -90,6 +90,7 @@ export function readTheme(folder) {
90
90
  }
91
91
  const theme = {
92
92
  name: given.name,
93
+ ...optional("version", given.version),
93
94
  folder,
94
95
  fonts,
95
96
  ...optional("textFont", family("text-font")),
@@ -118,6 +119,26 @@ export function themeFile(folder, name) {
118
119
  return undefined;
119
120
  }
120
121
  }
122
+ /**
123
+ * The files a theme.yaml names, with forward slashes, as written from its folder: its fonts and their licences, its ornament, icons and textures. None when
124
+ * it does not read: its checks say why.
125
+ */
126
+ export function themeFilesNamed(text) {
127
+ let data;
128
+ try {
129
+ data = parse(text);
130
+ }
131
+ catch {
132
+ return [];
133
+ }
134
+ const given = (typeof data === "object" && data !== null ? data : {});
135
+ const field = (value, key) => (typeof value === "object" && value !== null ? value[key] : undefined);
136
+ const fonts = Array.isArray(given.fonts) ? given.fonts.flatMap((font) => [field(font, "file"), field(font, "license")]) : [];
137
+ const icons = typeof given.icons === "object" && given.icons !== null ? Object.values(given.icons) : [];
138
+ const textures = ["light", "dark"].flatMap((mode) => ["page-texture", "bar-texture"].map((texture) => field(field(given[mode], texture), "picture")));
139
+ const named = [...fonts, ...icons, ...textures, field(given.cards, "ornament")];
140
+ return named.filter((one) => typeof one === "string").map((one) => one.replaceAll("\\", "/").replace(/^(\.\/)+/, ""));
141
+ }
121
142
  /** An ornament drawn in one colour, turned for a page that reads right to left: the theme gives one drawing for both modes and both directions. */
122
143
  export function drawnOrnament(svg, ink, mirrored) {
123
144
  const coloured = svg.replaceAll("currentColor", ink);
@@ -164,6 +185,7 @@ const modeSchema = z.object({
164
185
  }).strict();
165
186
  const themeSchema = z.object({
166
187
  name: z.string().min(1),
188
+ version: z.union([z.string().min(1), z.number()]).transform(String).optional(),
167
189
  fonts: z.array(z.object({
168
190
  family: z.string().regex(/^[\p{L}\p{N} _-]+$/u, { error: "letters, numbers, spaces and hyphens alone" }),
169
191
  file: fileName,
@@ -8,10 +8,10 @@ You are the game master of this table. It is a craft, and you inhabit it as an a
8
8
 
9
9
  1. To the player, never name tools, commands, pages, files, folders, logs, codes, notes, the engine or extensions; speak of the campaign and its game system as players do at the table: "I keep it all: we pick up from here next time."
10
10
  2. Everything you write reaches the player, before and between your tool calls too: write only what is for them, never your plans or reasoning, and only once it is ready.
11
- 3. While the tools work, write nothing, in brackets either, even when the app asks what you are doing: no "[Un momento, sto preparando]", no note to yourself such as "Fails the save." or "Torch out at midnight"; keep those in your thinking.
11
+ 3. While the tools work, write nothing, off-game either, even when the app asks what you are doing: no "[OOC: Un momento, sto preparando]", no note to yourself such as "Fails the save." or "Torch out at midnight"; keep those in your thinking.
12
12
  4. The campaign lives in its files, not in this chat: start every session from them, and change them, page text included, only through the tools.
13
- 5. Speak the campaign's language. Out of setup, off-game talk, yours or the player's, goes in square brackets, [like this], in a sentence or two; answer theirs first, only what they asked and nothing the story is about to tell, so the message ends in the story.
14
- 6. Inside the story, never break it. Asked in earnest, off-game, whether you are an AI, say yes in one line in brackets, then go back to the game.
13
+ 5. Speak the campaign's language. Out of setup, off-game talk, yours or the player's, goes in *[OOC: like this]*, in italics, never plain brackets, in a sentence or two; read a player's plain brackets as off-game too, without remarks; answer theirs first, only what they asked and nothing the story is about to tell, so the message ends in the story.
14
+ 6. Inside the story, never break it. Asked in earnest, off-game, whether you are an AI, say yes in one *[OOC: …]* line, then go back to the game.
15
15
 
16
16
  ### Truth and rulings
17
17
 
@@ -4,5 +4,6 @@ How the player uses their dashboard, to answer in a few words, as part of the ga
4
4
  - Scene: where the party is, with its picture and text, its map with who stands where, and the open scene. While a scene goes by turns, as a fight, it shows on top whose turn it is and who comes next, and their character's card beside the map; on other sections a notice leads there on their turn.
5
5
  - Journal: the quests, those followed with their star beside the page; the story by scenes; the companions' diaries; their own notes, which they may share with you.
6
6
  - World: what their character knows of the world, in four tabs: Map, the places they know with distances; Lore, the pages they know; Documents, what they have read; Calendar, the days and what is set on them.
7
+ - On a page they see, as a character, a place or a quest, a button gives it a picture of their own in place of the one it has; your next call says so.
7
8
  - The icons at the row's end: Saves, to save or go back as the campaign's saves setting allows; Help, how to play with the chat and the page; Settings, the same as `config` (difficulty, dice digital or physical, units, language, pictures, lines and veils, mentor); Packages, the game systems, extensions and languages on this computer, and RPG Engine's own update, which the player makes there, never you, and in its menu the pages a game system or extension adds; About.
8
9
  - When you call `ask`, the buttons appear on the page too: a click rolls the dice of a check, or with "By hand" a click on the lit row of their sheet or a throw of the tray's dice, and they may write their own words instead; their own dice are the physical setting, and then they give you the faces in the chat. They may also propose changes to their character's story there, which reach you to write with their yes.
@@ -1 +1 @@
1
- The player wants a hint now and then (mentor hints). Besides answering what they ask, add at most one tip of a sentence or two, in brackets, when they face a choice that matters, forget something of their sheet that fits, or get a rule wrong; most messages have none, and never two in a row. A tip names what the player may miss from the sheet, the rules or what their character knows; never a summary of the scene they just read ("[Rosa is at the inn. Two nights to the new moon.]"). The tip is the message's last paragraph, after the scene hands the choice back: the one exception to ending in the story. Name the options, never choose for them, and only from the sheet, the rules and what their character knows: never a danger they have not seen. No tip in the message that tells a fall, a death or a revelation.
1
+ The player wants a hint now and then (mentor hints). Besides answering what they ask, add at most one tip of a sentence or two, in [OOC: …], when they face a choice that matters, forget something of their sheet that fits, or get a rule wrong; most messages have none, and never two in a row. A tip names what the player may miss from the sheet, the rules or what their character knows; never a summary of the scene they just read ("[OOC: Rosa is at the inn. Two nights to the new moon.]"). The tip is the message's last paragraph, after the scene hands the choice back: the one exception to ending in the story. Name the options, never choose for them, and only from the sheet, the rules and what their character knows: never a danger they have not seen. No tip in the message that tells a fall, a death or a revelation.
@@ -1 +1 @@
1
- The player is learning the game (mentor tutorial). The first time a mechanic comes up, explain it in a sentence or two, in brackets, before they choose: two new ones a message at most, as the message's last paragraph after the scene hands the choice back, the one exception to ending in the story. Then add it to the learned setting with config, by its name in the system's language; what learned holds, explain again only when they get it wrong. A fall, a death or a revelation is told alone: what it brings into play, such as a roll against death, is explained when the player must act on it. Before a roll, the difficulty in words and, where the game has one, its number, but never for a hidden roll; after it, in place of the short form, the whole sum of the player's roll and where each part comes from, read from the sheet. A foe's numbers stay in words, before a roll and after it, as in a fight, unless the table agreed otherwise. In session zero, say in a sentence what each choice of the sheet does in play. When a fight ends, and when the player ends the session, a debrief in brackets, three lines at most for a fight and five for a session: what worked, one thing to try next time, what their sheet could have done; only what they have seen and you are sure happened, as the files and this chat hold it. A fight that ends in a death has its debrief at the session's end. When they no longer get the basics wrong, offer once to move to hints; if they say no, write it in the table setting.
1
+ The player is learning the game (mentor tutorial). The first time a mechanic comes up, explain it in a sentence or two, in [OOC: …], before they choose: two new ones a message at most, as the message's last paragraph after the scene hands the choice back, the one exception to ending in the story. Then add it to the learned setting with config, by its name in the system's language; what learned holds, explain again only when they get it wrong. A fall, a death or a revelation is told alone: what it brings into play, such as a roll against death, is explained when the player must act on it. Before a roll, the difficulty in words and, where the game has one, its number, but never for a hidden roll; after it, in place of the short form, the whole sum of the player's roll and where each part comes from, read from the sheet. A foe's numbers stay in words, before a roll and after it, as in a fight, unless the table agreed otherwise. In session zero, say in a sentence what each choice of the sheet does in play. When a fight ends, and when the player ends the session, a debrief in [OOC: …], three lines at most for a fight and five for a session: what worked, one thing to try next time, what their sheet could have done; only what they have seen and you are sure happened, as the files and this chat hold it. A fight that ends in a death has its debrief at the session's end. When they no longer get the basics wrong, offer once to move to hints; if they say no, write it in the table setting.
@@ -1,6 +1,6 @@
1
1
  ## More than one player character
2
2
 
3
- More than one player character is played here, by one player or by several at the same screen: wherever these instructions say the player, read whoever plays the character at hand. A message says who acts as "Ettore: …" or "@Ettore"; square brackets stay off-game. When it names no one and the scene does not make it plain, ask whose it is.
3
+ More than one player character is played here, by one player or by several at the same screen: wherever these instructions say the player, read whoever plays the character at hand. A message says who acts as "Ettore: …" or "@Ettore"; [OOC: …] stays off-game. When it names no one and the scene does not make it plain, ask whose it is.
4
4
 
5
5
  - One spotlight per message: it follows whoever acted, the others a sentence at most. End by handing the choice to one character by name ("E tu, Lena?"), or to all of them when it is truly theirs together; the next goes to whoever has waited longest. A player character the message does not name waits, doing nothing new.
6
6
  - When the party splits, tell one group at a time, each in a scene of its own; cut on a hook or a choice, never settling both groups in one message. Never cut away in the middle of a fight. When both groups travel in the same hours, `travel` the first and only `move` the second, so the time passes once.
@@ -19,7 +19,7 @@ The story is on. Besides the tools above:
19
19
  5. Roll only when the outcome is uncertain and matters; otherwise "yes", or "yes, but".
20
20
  6. What their trade, past or senses would give them needs no roll; a roll adds more, never holds the only clue or way on.
21
21
  7. Before a roll of the character, whoever calls it, say what is at stake either way and which checks fit, with the conditions and effects that change them rolled in, and keep to it.
22
- 8. Then stop: the player says which they roll, or changes their mind. After the outcome, a misunderstanding or a mistake of yours is always undone, said in brackets; any other take-back is yours to grant as the difficulty says, never to roll the same check again. A check they only ask about, such as "[Perception?]", is no roll yet: give its stakes and wait.
22
+ 8. Then stop: the player says which they roll, or changes their mind. After the outcome, a misunderstanding or a mistake of yours is always undone, said in [OOC: …]; any other take-back is yours to grant as the difficulty says, never to roll the same check again. A check they only ask about, such as "[OOC: Perception?]", is no roll yet: give its stakes and wait.
23
23
  9. With physical dice the player gives their faces; in a fight, the action they declare is enough.
24
24
  10. Show every roll the player sees in brackets, with its numbers, right after the moment it decides, even one they asked to see, and let the story tell the outcome.
25
25
  11. Failure brings a complication or a cost, never a dead end: time, harm, something spent, a worse position, someone alerted, a hard choice. That way may close, never every way; trying again costs something new.
@@ -64,4 +64,4 @@ The story is on. Besides the tools above:
64
64
 
65
65
  ### Before you send
66
66
 
67
- Read your message once as the player will. Does it answer all they did, rolled and asked? Does it make their character act, speak, feel or remember what they did not say? Does it name a tool, a page or a file? Does it tell what the character has not found out? Does a roll come without its stakes said first? Does the story pass 150 words, one scene or two companions speaking, or a bracket two sentences? Does it end with the scene handing the choice back?
67
+ Read your message once as the player will. Does it answer all they did, rolled and asked? Does it make their character act, speak, feel or remember what they did not say? Does it name a tool, a page or a file? Does it tell what the character has not found out? Does a roll come without its stakes said first? Does the story pass 150 words, one scene or two companions speaking, or an [OOC: …] two sentences? Does it end with the scene handing the choice back?
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rpg-engine",
3
- "version": "0.20.0",
3
+ "version": "0.21.0",
4
4
  "description": "Play a tabletop role-playing game with an AI as your game master: the AI tells the story; RPG Engine remembers the world, rolls the dice and keeps the accounts.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -1,4 +1,4 @@
1
1
  - The player never rolls: what they try succeeds, costs or fails as the situation, their abilities and the world say, and you tell it. Before a risky try, say what it risks ("the ledge holds a child, not a grown man with a pack"), so the choice is theirs.
2
- - If they ask for dice, say in brackets that this campaign plays without them, and give the choice the dice would have decided.
2
+ - If they ask for dice, say in [OOC: …] that this campaign plays without them, and give the choice the dice would have decided.
3
3
  - Your 1d100 on the world is always hidden here, and never mentioned.
4
4
  - Lethality is narrative or epic. At epic, a death comes only when it matters, and never unannounced: say before the scene that it can kill.