rpg-engine 0.2.0 → 0.3.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 (1129) hide show
  1. package/README.md +3 -3
  2. package/dist/adventures/index.d.ts +3 -0
  3. package/dist/adventures/index.js +5 -0
  4. package/dist/adventures/manifest.d.ts +39 -0
  5. package/dist/adventures/manifest.js +89 -0
  6. package/dist/adventures/placement.d.ts +4 -0
  7. package/dist/adventures/placement.js +14 -0
  8. package/dist/adventures/source.d.ts +21 -0
  9. package/dist/adventures/source.js +108 -0
  10. package/dist/bell-listener.d.ts +9 -0
  11. package/dist/bell-listener.js +83 -0
  12. package/dist/campaign/create-campaign.d.ts +3 -2
  13. package/dist/campaign/create-campaign.js +5 -5
  14. package/dist/campaign/host-files.d.ts +23 -6
  15. package/dist/campaign/host-files.js +130 -40
  16. package/dist/campaign/index.d.ts +2 -2
  17. package/dist/campaign/index.js +2 -2
  18. package/dist/campaign/settings.d.ts +33 -2
  19. package/dist/campaign/settings.js +49 -12
  20. package/dist/cli.js +10 -1
  21. package/dist/command-line.js +20 -2
  22. package/dist/commands/advance.js +6 -2
  23. package/dist/commands/ask.d.ts +11 -4
  24. package/dist/commands/ask.js +249 -23
  25. package/dist/commands/change.d.ts +29 -0
  26. package/dist/commands/change.js +260 -41
  27. package/dist/commands/config.d.ts +6 -3
  28. package/dist/commands/config.js +179 -79
  29. package/dist/commands/effect.js +38 -9
  30. package/dist/commands/game-advance.d.ts +11 -2
  31. package/dist/commands/game-advance.js +22 -7
  32. package/dist/commands/game-adventures.d.ts +70 -0
  33. package/dist/commands/game-adventures.js +418 -0
  34. package/dist/commands/game-bonds.d.ts +9 -0
  35. package/dist/commands/game-bonds.js +84 -0
  36. package/dist/commands/game-catalog.d.ts +36 -0
  37. package/dist/commands/game-catalog.js +122 -0
  38. package/dist/commands/game-checks.d.ts +17 -0
  39. package/dist/commands/game-checks.js +128 -0
  40. package/dist/commands/game-damage.d.ts +18 -0
  41. package/dist/commands/game-damage.js +74 -0
  42. package/dist/commands/game-effects.d.ts +5 -0
  43. package/dist/commands/game-effects.js +2 -2
  44. package/dist/commands/game-events.js +8 -4
  45. package/dist/commands/game-experience.js +2 -2
  46. package/dist/commands/game-extensions.d.ts +8 -1
  47. package/dist/commands/game-extensions.js +8 -3
  48. package/dist/commands/game-grid-moves.d.ts +4 -1
  49. package/dist/commands/game-grid-moves.js +8 -2
  50. package/dist/commands/game-hit-dice.d.ts +39 -0
  51. package/dist/commands/game-hit-dice.js +120 -0
  52. package/dist/commands/game-import.d.ts +11 -0
  53. package/dist/commands/game-import.js +154 -0
  54. package/dist/commands/game-journey.d.ts +6 -2
  55. package/dist/commands/game-journey.js +17 -6
  56. package/dist/commands/game-knowledge.d.ts +56 -6
  57. package/dist/commands/game-knowledge.js +152 -23
  58. package/dist/commands/game-library.d.ts +112 -0
  59. package/dist/commands/game-library.js +388 -0
  60. package/dist/commands/game-limits.d.ts +7 -0
  61. package/dist/commands/game-limits.js +67 -0
  62. package/dist/commands/game-mode.js +3 -3
  63. package/dist/commands/game-moves.d.ts +14 -1
  64. package/dist/commands/game-moves.js +24 -9
  65. package/dist/commands/game-recipe-pace.d.ts +6 -0
  66. package/dist/commands/game-recipe-pace.js +25 -0
  67. package/dist/commands/game-recipes.js +10 -3
  68. package/dist/commands/game-reminders.d.ts +3 -3
  69. package/dist/commands/game-reminders.js +10 -5
  70. package/dist/commands/game-roads.d.ts +11 -4
  71. package/dist/commands/game-roads.js +89 -26
  72. package/dist/commands/game-saves.d.ts +12 -0
  73. package/dist/commands/game-saves.js +44 -5
  74. package/dist/commands/game-scene.js +3 -1
  75. package/dist/commands/game-stacks.d.ts +78 -0
  76. package/dist/commands/game-stacks.js +198 -0
  77. package/dist/commands/game-system-code.d.ts +25 -0
  78. package/dist/commands/game-system-code.js +165 -0
  79. package/dist/commands/game-thoughts.d.ts +25 -0
  80. package/dist/commands/game-thoughts.js +57 -0
  81. package/dist/commands/game-turn-uses.d.ts +33 -0
  82. package/dist/commands/game-turn-uses.js +137 -0
  83. package/dist/commands/game-upkeep.d.ts +20 -0
  84. package/dist/commands/game-upkeep.js +190 -0
  85. package/dist/commands/game-view-journal.d.ts +14 -1
  86. package/dist/commands/game-view-journal.js +5 -2
  87. package/dist/commands/game-view-map.d.ts +3 -0
  88. package/dist/commands/game-view-map.js +5 -1
  89. package/dist/commands/game-view-place.d.ts +22 -3
  90. package/dist/commands/game-view-place.js +61 -24
  91. package/dist/commands/game-view-world.d.ts +98 -0
  92. package/dist/commands/game-view-world.js +98 -0
  93. package/dist/commands/game-voices.d.ts +5 -0
  94. package/dist/commands/game-voices.js +13 -0
  95. package/dist/commands/game-widgets.d.ts +66 -0
  96. package/dist/commands/game-widgets.js +274 -0
  97. package/dist/commands/game-world.d.ts +8 -1
  98. package/dist/commands/game-world.js +23 -3
  99. package/dist/commands/image.js +2 -3
  100. package/dist/commands/import.d.ts +47 -0
  101. package/dist/commands/import.js +390 -0
  102. package/dist/commands/index.js +6 -0
  103. package/dist/commands/init.js +2 -2
  104. package/dist/commands/install.js +2 -1
  105. package/dist/commands/instructions.js +26 -1
  106. package/dist/commands/mode.js +3 -1
  107. package/dist/commands/move.d.ts +2 -0
  108. package/dist/commands/move.js +86 -12
  109. package/dist/commands/package.d.ts +85 -9
  110. package/dist/commands/package.js +378 -50
  111. package/dist/commands/parts.d.ts +3 -0
  112. package/dist/commands/parts.js +5 -0
  113. package/dist/commands/problems.js +6 -0
  114. package/dist/commands/rename.js +3 -0
  115. package/dist/commands/reveal.js +12 -7
  116. package/dist/commands/roll.d.ts +2 -0
  117. package/dist/commands/roll.js +23 -7
  118. package/dist/commands/route.js +4 -5
  119. package/dist/commands/rules.d.ts +3 -0
  120. package/dist/commands/rules.js +38 -6
  121. package/dist/commands/save.d.ts +1 -1
  122. package/dist/commands/save.js +2 -2
  123. package/dist/commands/scene.d.ts +10 -1
  124. package/dist/commands/scene.js +146 -29
  125. package/dist/commands/sheet.d.ts +47 -6
  126. package/dist/commands/sheet.js +179 -33
  127. package/dist/commands/show.d.ts +33 -0
  128. package/dist/commands/show.js +19 -2
  129. package/dist/commands/status.d.ts +9 -3
  130. package/dist/commands/status.js +59 -17
  131. package/dist/commands/thoughts.d.ts +11 -0
  132. package/dist/commands/thoughts.js +54 -0
  133. package/dist/commands/trade.d.ts +17 -0
  134. package/dist/commands/trade.js +273 -0
  135. package/dist/commands/travel.d.ts +2 -0
  136. package/dist/commands/travel.js +40 -14
  137. package/dist/commands/validate.js +2 -1
  138. package/dist/commands/view.d.ts +99 -2
  139. package/dist/commands/view.js +273 -57
  140. package/dist/commands/worked-out.d.ts +16 -0
  141. package/dist/commands/worked-out.js +108 -13
  142. package/dist/commands/write.d.ts +1 -0
  143. package/dist/commands/write.js +93 -21
  144. package/dist/confirm/confirm.d.ts +35 -0
  145. package/dist/confirm/confirm.js +94 -0
  146. package/dist/confirm/index.d.ts +1 -0
  147. package/dist/confirm/index.js +3 -0
  148. package/dist/core/archive-paths.d.ts +8 -0
  149. package/dist/core/archive-paths.js +39 -0
  150. package/dist/core/context.d.ts +131 -5
  151. package/dist/core/context.js +4 -3
  152. package/dist/core/download.d.ts +2 -0
  153. package/dist/core/download.js +31 -0
  154. package/dist/core/field-kind.d.ts +4 -3
  155. package/dist/core/field-kind.js +4 -3
  156. package/dist/core/files.d.ts +10 -0
  157. package/dist/core/files.js +58 -2
  158. package/dist/core/formula.d.ts +3 -1
  159. package/dist/core/formula.js +13 -2
  160. package/dist/core/progression-rule.d.ts +2 -0
  161. package/dist/core/version.d.ts +2 -0
  162. package/dist/core/version.js +7 -0
  163. package/dist/dashboard/act-names.js +27 -0
  164. package/dist/dashboard/act-sheet.js +100 -0
  165. package/dist/dashboard/act-strip.js +49 -0
  166. package/dist/dashboard/acts.js +140 -0
  167. package/dist/dashboard/address.js +16 -12
  168. package/dist/dashboard/api.js +140 -10
  169. package/dist/dashboard/app.js +370 -41
  170. package/dist/dashboard/asked.js +297 -19
  171. package/dist/dashboard/calendar.js +56 -0
  172. package/dist/dashboard/card.js +13 -12
  173. package/dist/dashboard/coins.js +13 -0
  174. package/dist/dashboard/death-save.js +67 -0
  175. package/dist/dashboard/dice/pool.js +22 -0
  176. package/dist/dashboard/dice/roller.js +1 -1
  177. package/dist/dashboard/dice/stage.js +12 -4
  178. package/dist/dashboard/dice/tray.js +28 -15
  179. package/dist/dashboard/dying.js +46 -0
  180. package/dist/dashboard/extension-widgets.js +160 -0
  181. package/dist/dashboard/game-words.js +33 -4
  182. package/dist/dashboard/guide/ar.md +105 -100
  183. package/dist/dashboard/guide/cs.md +111 -106
  184. package/dist/dashboard/guide/da.md +95 -90
  185. package/dist/dashboard/guide/de.md +93 -88
  186. package/dist/dashboard/guide/el.md +110 -105
  187. package/dist/dashboard/guide/en.md +21 -16
  188. package/dist/dashboard/guide/es.md +79 -74
  189. package/dist/dashboard/guide/fi.md +99 -94
  190. package/dist/dashboard/guide/fr.md +83 -78
  191. package/dist/dashboard/guide/he.md +109 -104
  192. package/dist/dashboard/guide/hi.md +103 -98
  193. package/dist/dashboard/guide/hu.md +113 -108
  194. package/dist/dashboard/guide/is.md +102 -97
  195. package/dist/dashboard/guide/it.md +22 -17
  196. package/dist/dashboard/guide/ja.md +108 -103
  197. package/dist/dashboard/guide/ko.md +113 -108
  198. package/dist/dashboard/guide/nb.md +95 -90
  199. package/dist/dashboard/guide/nl.md +89 -84
  200. package/dist/dashboard/guide/pl.md +104 -99
  201. package/dist/dashboard/guide/pt.md +82 -77
  202. package/dist/dashboard/guide/ro.md +113 -108
  203. package/dist/dashboard/guide/ru.md +109 -104
  204. package/dist/dashboard/guide/sv.md +96 -91
  205. package/dist/dashboard/guide/tr.md +102 -97
  206. package/dist/dashboard/guide/uk.md +113 -108
  207. package/dist/dashboard/guide/zh.md +110 -105
  208. package/dist/dashboard/guide-markdown.js +4 -0
  209. package/dist/dashboard/help.js +4 -5
  210. package/dist/dashboard/i18n/ar.json +361 -16
  211. package/dist/dashboard/i18n/cs.json +361 -16
  212. package/dist/dashboard/i18n/da.json +361 -16
  213. package/dist/dashboard/i18n/de.json +361 -16
  214. package/dist/dashboard/i18n/el.json +361 -16
  215. package/dist/dashboard/i18n/es.json +361 -16
  216. package/dist/dashboard/i18n/fi.json +361 -16
  217. package/dist/dashboard/i18n/fr.json +361 -16
  218. package/dist/dashboard/i18n/he.json +361 -16
  219. package/dist/dashboard/i18n/hi.json +361 -16
  220. package/dist/dashboard/i18n/hu.json +361 -16
  221. package/dist/dashboard/i18n/is.json +361 -16
  222. package/dist/dashboard/i18n/it.json +363 -18
  223. package/dist/dashboard/i18n/ja.json +361 -16
  224. package/dist/dashboard/i18n/ko.json +361 -16
  225. package/dist/dashboard/i18n/nb.json +361 -16
  226. package/dist/dashboard/i18n/nl.json +361 -16
  227. package/dist/dashboard/i18n/pl.json +361 -16
  228. package/dist/dashboard/i18n/pt.json +361 -16
  229. package/dist/dashboard/i18n/ro.json +361 -16
  230. package/dist/dashboard/i18n/ru.json +361 -16
  231. package/dist/dashboard/i18n/sv.json +361 -16
  232. package/dist/dashboard/i18n/tr.json +361 -16
  233. package/dist/dashboard/i18n/uk.json +361 -16
  234. package/dist/dashboard/i18n/zh.json +361 -16
  235. package/dist/dashboard/icons.js +38 -4
  236. package/dist/dashboard/journal.js +203 -49
  237. package/dist/dashboard/labels.js +42 -4
  238. package/dist/dashboard/languages.js +2 -2
  239. package/dist/dashboard/layout.js +35 -0
  240. package/dist/dashboard/lore.js +44 -0
  241. package/dist/dashboard/markdown.js +136 -30
  242. package/dist/dashboard/master.js +2 -2
  243. package/dist/dashboard/notes.js +5 -5
  244. package/dist/dashboard/notices.js +24 -4
  245. package/dist/dashboard/packages.js +678 -0
  246. package/dist/dashboard/pages.js +0 -8
  247. package/dist/dashboard/party.js +17 -4
  248. package/dist/dashboard/place-map-view.js +47 -9
  249. package/dist/dashboard/rolls.js +35 -93
  250. package/dist/dashboard/save-outcome.js +42 -0
  251. package/dist/dashboard/saves.js +14 -11
  252. package/dist/dashboard/scene.js +114 -20
  253. package/dist/dashboard/settings.js +70 -12
  254. package/dist/dashboard/setup.js +4 -4
  255. package/dist/dashboard/sheet.js +123 -19
  256. package/dist/dashboard/spend.js +115 -0
  257. package/dist/dashboard/status.js +22 -10
  258. package/dist/dashboard/story.js +6 -6
  259. package/dist/dashboard/style.css +8047 -3468
  260. package/dist/dashboard/table.js +145 -0
  261. package/dist/dashboard/tabs.js +34 -0
  262. package/dist/dashboard/text.js +19 -1
  263. package/dist/dashboard/top.js +91 -31
  264. package/dist/dashboard/turns.js +150 -0
  265. package/dist/dashboard/widgets.js +21 -14
  266. package/dist/dashboard/world-calendar.js +101 -0
  267. package/dist/dashboard/world-lore.js +231 -0
  268. package/dist/dashboard/world.js +87 -29
  269. package/dist/dashboard-server.d.ts +10 -1
  270. package/dist/dashboard-server.js +738 -26
  271. package/dist/documents/index.d.ts +2 -0
  272. package/dist/documents/index.js +5 -0
  273. package/dist/documents/markup.d.ts +10 -0
  274. package/dist/documents/markup.js +124 -0
  275. package/dist/documents/ocr.d.ts +9 -0
  276. package/dist/documents/ocr.js +101 -0
  277. package/dist/documents/png.d.ts +9 -0
  278. package/dist/documents/png.js +75 -0
  279. package/dist/documents/read.d.ts +54 -0
  280. package/dist/documents/read.js +375 -0
  281. package/dist/extensions/api.d.ts +91 -9
  282. package/dist/extensions/extension.d.ts +28 -2
  283. package/dist/extensions/extension.js +49 -11
  284. package/dist/extensions/index.d.ts +5 -3
  285. package/dist/extensions/index.js +4 -2
  286. package/dist/extensions/packages.d.ts +13 -4
  287. package/dist/extensions/packages.js +127 -15
  288. package/dist/extensions/tarball.d.ts +6 -0
  289. package/dist/extensions/tarball.js +87 -0
  290. package/dist/extensions/words.d.ts +13 -0
  291. package/dist/extensions/words.js +42 -0
  292. package/dist/importer/index.d.ts +1 -0
  293. package/dist/importer/index.js +3 -0
  294. package/dist/importer/work.d.ts +132 -0
  295. package/dist/importer/work.js +306 -0
  296. package/dist/index.d.ts +3 -1
  297. package/dist/instructions/index.d.ts +7 -0
  298. package/dist/instructions/index.js +10 -0
  299. package/dist/languages/index.d.ts +1 -0
  300. package/dist/languages/index.js +3 -0
  301. package/dist/languages/language-pack.d.ts +32 -0
  302. package/dist/languages/language-pack.js +86 -0
  303. package/dist/library/books.d.ts +76 -0
  304. package/dist/library/books.js +378 -0
  305. package/dist/library/folders.d.ts +11 -0
  306. package/dist/library/folders.js +70 -0
  307. package/dist/library/index.d.ts +3 -0
  308. package/dist/library/index.js +5 -0
  309. package/dist/library/language.d.ts +2 -0
  310. package/dist/library/language.js +40 -0
  311. package/dist/library-reader.d.ts +7 -0
  312. package/dist/library-reader.js +36 -0
  313. package/dist/mcp-server.js +90 -7
  314. package/dist/money/index.d.ts +1 -1
  315. package/dist/money/index.js +1 -1
  316. package/dist/money/money.d.ts +6 -0
  317. package/dist/money/money.js +11 -0
  318. package/dist/page-words.js +4 -1
  319. package/dist/pages/check.d.ts +5 -0
  320. package/dist/pages/check.js +111 -5
  321. package/dist/pages/containers.d.ts +19 -1
  322. package/dist/pages/containers.js +50 -7
  323. package/dist/pages/index.d.ts +8 -5
  324. package/dist/pages/index.js +8 -5
  325. package/dist/pages/load.d.ts +11 -0
  326. package/dist/pages/load.js +69 -0
  327. package/dist/pages/markdown.d.ts +7 -0
  328. package/dist/pages/markdown.js +27 -3
  329. package/dist/pages/page-file.d.ts +2 -0
  330. package/dist/pages/page-file.js +28 -5
  331. package/dist/pages/rename-page.js +3 -2
  332. package/dist/pages/stack-entry.d.ts +47 -0
  333. package/dist/pages/stack-entry.js +83 -0
  334. package/dist/pages/stack-writes.d.ts +22 -0
  335. package/dist/pages/stack-writes.js +128 -0
  336. package/dist/pages/stacks.d.ts +52 -0
  337. package/dist/pages/stacks.js +168 -0
  338. package/dist/pages/standard-fields.js +1 -1
  339. package/dist/pages/system-pages.d.ts +5 -2
  340. package/dist/pages/system-pages.js +11 -5
  341. package/dist/pages/world.d.ts +29 -3
  342. package/dist/pages/world.js +66 -12
  343. package/dist/pages/write-page.js +15 -6
  344. package/dist/pictures/chosen.d.ts +5 -1
  345. package/dist/pictures/chosen.js +12 -3
  346. package/dist/pictures/claude.d.ts +3 -1
  347. package/dist/pictures/claude.js +38 -0
  348. package/dist/pictures/codex.d.ts +3 -1
  349. package/dist/pictures/codex.js +32 -0
  350. package/dist/pictures/helpers.d.ts +10 -0
  351. package/dist/pictures/helpers.js +53 -6
  352. package/dist/pictures/index.d.ts +5 -4
  353. package/dist/pictures/index.js +5 -4
  354. package/dist/pictures/stop.d.ts +2 -0
  355. package/dist/pictures/stop.js +18 -0
  356. package/dist/player-acts.d.ts +27 -0
  357. package/dist/player-acts.js +56 -0
  358. package/dist/rules/index.d.ts +1 -0
  359. package/dist/rules/index.js +3 -1
  360. package/dist/rules/page-search.d.ts +36 -0
  361. package/dist/rules/page-search.js +216 -0
  362. package/dist/rules/search.d.ts +7 -0
  363. package/dist/rules/search.js +2 -2
  364. package/dist/scene/scene.d.ts +2 -0
  365. package/dist/scene/scene.js +1 -0
  366. package/dist/systems/game-system.d.ts +161 -4
  367. package/dist/systems/game-system.js +237 -34
  368. package/dist/systems/index.d.ts +3 -1
  369. package/dist/systems/index.js +3 -1
  370. package/dist/systems/system-code.d.ts +97 -0
  371. package/dist/systems/system-code.js +62 -0
  372. package/dist/systems/system-folders.d.ts +11 -0
  373. package/dist/systems/system-folders.js +11 -0
  374. package/dist/systems/words.d.ts +2 -0
  375. package/dist/systems/words.js +3 -3
  376. package/instructions/author.md +1 -1
  377. package/instructions/buttons-physical-dice.md +1 -1
  378. package/instructions/buttons.md +1 -1
  379. package/instructions/character.md +15 -0
  380. package/instructions/combat.md +3 -1
  381. package/instructions/core.md +4 -4
  382. package/instructions/dashboard.md +4 -4
  383. package/instructions/import.md +14 -0
  384. package/instructions/mentor-hints.md +1 -1
  385. package/instructions/party.md +11 -0
  386. package/instructions/play.md +5 -5
  387. package/instructions/session-zero.md +1 -1
  388. package/instructions/setup.md +1 -1
  389. package/instructions/voices-always.md +1 -0
  390. package/instructions/voices-important.md +1 -0
  391. package/instructions/voices.md +14 -0
  392. package/package.json +6 -2
  393. package/systems/5e/LICENSE.md +1 -1
  394. package/systems/5e/dist/dying.js +193 -0
  395. package/systems/5e/dist/index.js +3 -0
  396. package/systems/5e/images/abacus.svg +1 -0
  397. package/systems/5e/images/acid-tube.svg +1 -0
  398. package/systems/5e/images/animal-hide.svg +1 -0
  399. package/systems/5e/images/anvil.svg +1 -0
  400. package/systems/5e/images/arrow-cluster.svg +1 -0
  401. package/systems/5e/images/backpack.svg +1 -0
  402. package/systems/5e/images/bagpipes.svg +1 -0
  403. package/systems/5e/images/barbed-spear.svg +1 -0
  404. package/systems/5e/images/barrel.svg +1 -0
  405. package/systems/5e/images/basket.svg +1 -0
  406. package/systems/5e/images/battle-axe.svg +1 -0
  407. package/systems/5e/images/beer-horn.svg +1 -0
  408. package/systems/5e/images/belt-buckles.svg +1 -0
  409. package/systems/5e/images/bird-scepter.svg +1 -0
  410. package/systems/5e/images/blanket.svg +1 -0
  411. package/systems/5e/images/book-cover.svg +1 -0
  412. package/systems/5e/images/boots.svg +1 -0
  413. package/systems/5e/images/bottle-vapors.svg +1 -0
  414. package/systems/5e/images/bow-arrow.svg +1 -0
  415. package/systems/5e/images/bowl-spiral.svg +1 -0
  416. package/systems/5e/images/bracer.svg +1 -0
  417. package/systems/5e/images/broadsword.svg +1 -0
  418. package/systems/5e/images/broom.svg +1 -0
  419. package/systems/5e/images/bullets.svg +1 -0
  420. package/systems/5e/images/caltrops.svg +1 -0
  421. package/systems/5e/images/camp-cooking-pot.svg +1 -0
  422. package/systems/5e/images/campfire.svg +1 -0
  423. package/systems/5e/images/camping-tent.svg +1 -0
  424. package/systems/5e/images/candle-flame.svg +1 -0
  425. package/systems/5e/images/candle-light.svg +1 -0
  426. package/systems/5e/images/canoe.svg +1 -0
  427. package/systems/5e/images/cape.svg +1 -0
  428. package/systems/5e/images/caravel.svg +1 -0
  429. package/systems/5e/images/card-pick.svg +1 -0
  430. package/systems/5e/images/chain-mail.svg +1 -0
  431. package/systems/5e/images/chained-arrow-heads.svg +1 -0
  432. package/systems/5e/images/chariot.svg +1 -0
  433. package/systems/5e/images/chest.svg +1 -0
  434. package/systems/5e/images/chisel.svg +1 -0
  435. package/systems/5e/images/claw-hammer.svg +1 -0
  436. package/systems/5e/images/colombian-statue.svg +1 -0
  437. package/systems/5e/images/cooking-pot.svg +1 -0
  438. package/systems/5e/images/crescent-staff.svg +1 -0
  439. package/systems/5e/images/crossbow.svg +1 -0
  440. package/systems/5e/images/crossed-chains.svg +1 -0
  441. package/systems/5e/images/crowbar.svg +1 -0
  442. package/systems/5e/images/crystal-ball.svg +1 -0
  443. package/systems/5e/images/crystal-cluster.svg +1 -0
  444. package/systems/5e/images/crystal-eye.svg +1 -0
  445. package/systems/5e/images/cubes.svg +1 -0
  446. package/systems/5e/images/dart.svg +1 -0
  447. package/systems/5e/images/dice-six-faces-five.svg +1 -0
  448. package/systems/5e/images/dragon-orb.svg +1 -0
  449. package/systems/5e/images/drakkar.svg +1 -0
  450. package/systems/5e/images/drum.svg +1 -0
  451. package/systems/5e/images/empty-wood-bucket-handle.svg +1 -0
  452. package/systems/5e/images/eye-shield.svg +1 -0
  453. package/systems/5e/images/fairy-wand.svg +1 -0
  454. package/systems/5e/images/feather.svg +1 -0
  455. package/systems/5e/images/feathered-wing.svg +1 -0
  456. package/systems/5e/images/fire-bottle.svg +1 -0
  457. package/systems/5e/images/fire-gem.svg +1 -0
  458. package/systems/5e/images/first-aid-kit.svg +1 -0
  459. package/systems/5e/images/fishing-hook.svg +1 -0
  460. package/systems/5e/images/fishing-net.svg +1 -0
  461. package/systems/5e/images/fishing-pole.svg +1 -0
  462. package/systems/5e/images/fist.svg +1 -0
  463. package/systems/5e/images/flail.svg +1 -0
  464. package/systems/5e/images/flanged-mace.svg +1 -0
  465. package/systems/5e/images/flat-hammer.svg +1 -0
  466. package/systems/5e/images/flint-spark.svg +1 -0
  467. package/systems/5e/images/floating-crystal.svg +1 -0
  468. package/systems/5e/images/flute.svg +1 -0
  469. package/systems/5e/images/galleon.svg +1 -0
  470. package/systems/5e/images/gauntlet.svg +1 -0
  471. package/systems/5e/images/gem-necklace.svg +1 -0
  472. package/systems/5e/images/gem-pendant.svg +1 -0
  473. package/systems/5e/images/gems.svg +1 -0
  474. package/systems/5e/images/gladius.svg +1 -0
  475. package/systems/5e/images/glaive.svg +1 -0
  476. package/systems/5e/images/glass-ball.svg +1 -0
  477. package/systems/5e/images/gloves.svg +1 -0
  478. package/systems/5e/images/gold-scarab.svg +1 -0
  479. package/systems/5e/images/grain-bundle.svg +1 -0
  480. package/systems/5e/images/halberd.svg +1 -0
  481. package/systems/5e/images/hand-saw.svg +1 -0
  482. package/systems/5e/images/handheld-fan.svg +1 -0
  483. package/systems/5e/images/harp.svg +1 -0
  484. package/systems/5e/images/hatchet.svg +1 -0
  485. package/systems/5e/images/headband-knot.svg +1 -0
  486. package/systems/5e/images/health-potion.svg +1 -0
  487. package/systems/5e/images/heart-bottle.svg +1 -0
  488. package/systems/5e/images/herbs-bundle.svg +1 -0
  489. package/systems/5e/images/hole-ladder.svg +1 -0
  490. package/systems/5e/images/holy-symbol.svg +1 -0
  491. package/systems/5e/images/holy-water.svg +1 -0
  492. package/systems/5e/images/honey-jar.svg +1 -0
  493. package/systems/5e/images/hood.svg +1 -0
  494. package/systems/5e/images/horseshoe.svg +1 -0
  495. package/systems/5e/images/hourglass.svg +1 -0
  496. package/systems/5e/images/hunting-horn.svg +1 -0
  497. package/systems/5e/images/jester-hat.svg +1 -0
  498. package/systems/5e/images/jug.svg +1 -0
  499. package/systems/5e/images/katana.svg +1 -0
  500. package/systems/5e/images/key-lock.svg +1 -0
  501. package/systems/5e/images/kitchen-scale.svg +1 -0
  502. package/systems/5e/images/knapsack.svg +1 -0
  503. package/systems/5e/images/ladder.svg +1 -0
  504. package/systems/5e/images/lantern.svg +1 -0
  505. package/systems/5e/images/leather-armor.svg +1 -0
  506. package/systems/5e/images/leather-boot.svg +1 -0
  507. package/systems/5e/images/leather-vest.svg +1 -0
  508. package/systems/5e/images/light-backpack.svg +1 -0
  509. package/systems/5e/images/light-helm.svg +1 -0
  510. package/systems/5e/images/locked-box.svg +1 -0
  511. package/systems/5e/images/locked-fortress.svg +1 -0
  512. package/systems/5e/images/lockpicks.svg +1 -0
  513. package/systems/5e/images/lunar-wand.svg +1 -0
  514. package/systems/5e/images/lyre.svg +1 -0
  515. package/systems/5e/images/magic-lamp.svg +1 -0
  516. package/systems/5e/images/magnifying-glass.svg +1 -0
  517. package/systems/5e/images/mail-shirt.svg +1 -0
  518. package/systems/5e/images/manacles.svg +1 -0
  519. package/systems/5e/images/marbles.svg +1 -0
  520. package/systems/5e/images/meat.svg +1 -0
  521. package/systems/5e/images/medal.svg +1 -0
  522. package/systems/5e/images/mirror-mirror.svg +1 -0
  523. package/systems/5e/images/mountain-climbing.svg +1 -0
  524. package/systems/5e/images/oil-can.svg +1 -0
  525. package/systems/5e/images/old-lantern.svg +1 -0
  526. package/systems/5e/images/old-wagon.svg +1 -0
  527. package/systems/5e/images/orb-wand.svg +1 -0
  528. package/systems/5e/images/oyster-pearl.svg +1 -0
  529. package/systems/5e/images/paint-brush.svg +1 -0
  530. package/systems/5e/images/painted-pottery.svg +1 -0
  531. package/systems/5e/images/palette.svg +1 -0
  532. package/systems/5e/images/paper.svg +1 -0
  533. package/systems/5e/images/pencil.svg +1 -0
  534. package/systems/5e/images/perfume-bottle.svg +1 -0
  535. package/systems/5e/images/pilgrim-hat.svg +1 -0
  536. package/systems/5e/images/pipes.svg +1 -0
  537. package/systems/5e/images/plain-arrow.svg +1 -0
  538. package/systems/5e/images/plain-dagger.svg +1 -0
  539. package/systems/5e/images/poison-bottle.svg +1 -0
  540. package/systems/5e/images/powder-bag.svg +1 -0
  541. package/systems/5e/images/prayer-beads.svg +1 -0
  542. package/systems/5e/images/pulley-hook.svg +1 -0
  543. package/systems/5e/images/quill-ink.svg +1 -0
  544. package/systems/5e/images/quill.svg +1 -0
  545. package/systems/5e/images/quiver.svg +1 -0
  546. package/systems/5e/images/red-carpet.svg +1 -0
  547. package/systems/5e/images/ring.svg +1 -0
  548. package/systems/5e/images/ringing-bell.svg +1 -0
  549. package/systems/5e/images/robe.svg +1 -0
  550. package/systems/5e/images/rope-coil.svg +1 -0
  551. package/systems/5e/images/round-bottom-flask.svg +1 -0
  552. package/systems/5e/images/round-potion.svg +1 -0
  553. package/systems/5e/images/rune-stone.svg +1 -0
  554. package/systems/5e/images/saddle.svg +1 -0
  555. package/systems/5e/images/scale-mail.svg +1 -0
  556. package/systems/5e/images/scroll-unfurled.svg +1 -0
  557. package/systems/5e/images/secret-book.svg +1 -0
  558. package/systems/5e/images/sewing-needle.svg +1 -0
  559. package/systems/5e/images/shield.svg +1 -0
  560. package/systems/5e/images/shirt-button.svg +1 -0
  561. package/systems/5e/images/sickle.svg +1 -0
  562. package/systems/5e/images/siege-ram.svg +1 -0
  563. package/systems/5e/images/skull-staff.svg +1 -0
  564. package/systems/5e/images/sleeping-bag.svg +1 -0
  565. package/systems/5e/images/sling.svg +1 -0
  566. package/systems/5e/images/slippers.svg +1 -0
  567. package/systems/5e/images/small-fishing-sailboat.svg +1 -0
  568. package/systems/5e/images/smoking-orb.svg +1 -0
  569. package/systems/5e/images/soap.svg +1 -0
  570. package/systems/5e/images/spade.svg +1 -0
  571. package/systems/5e/images/sparkling-sabre.svg +1 -0
  572. package/systems/5e/images/spell-book.svg +1 -0
  573. package/systems/5e/images/spiked-armor.svg +1 -0
  574. package/systems/5e/images/spiked-mace.svg +1 -0
  575. package/systems/5e/images/spikes.svg +1 -0
  576. package/systems/5e/images/spinning-wheel.svg +1 -0
  577. package/systems/5e/images/spyglass.svg +1 -0
  578. package/systems/5e/images/steampunk-goggles.svg +1 -0
  579. package/systems/5e/images/stone-block.svg +1 -0
  580. package/systems/5e/images/stone-pile.svg +1 -0
  581. package/systems/5e/images/stone-sphere.svg +1 -0
  582. package/systems/5e/images/straight-pipe.svg +1 -0
  583. package/systems/5e/images/swap-bag.svg +1 -0
  584. package/systems/5e/images/thor-hammer.svg +1 -0
  585. package/systems/5e/images/thrown-spear.svg +1 -0
  586. package/systems/5e/images/tiara.svg +1 -0
  587. package/systems/5e/images/tied-scroll.svg +1 -0
  588. package/systems/5e/images/tinker.svg +1 -0
  589. package/systems/5e/images/torch.svg +1 -0
  590. package/systems/5e/images/totem.svg +1 -0
  591. package/systems/5e/images/trap-mask.svg +1 -0
  592. package/systems/5e/images/treasure-map.svg +1 -0
  593. package/systems/5e/images/tribal-pendant.svg +1 -0
  594. package/systems/5e/images/trident.svg +1 -0
  595. package/systems/5e/images/two-handed-sword.svg +1 -0
  596. package/systems/5e/images/vial.svg +1 -0
  597. package/systems/5e/images/violin.svg +1 -0
  598. package/systems/5e/images/war-axe.svg +1 -0
  599. package/systems/5e/images/war-pick.svg +1 -0
  600. package/systems/5e/images/warhammer.svg +1 -0
  601. package/systems/5e/images/water-bottle.svg +1 -0
  602. package/systems/5e/images/waterskin.svg +1 -0
  603. package/systems/5e/images/wavy-chains.svg +1 -0
  604. package/systems/5e/images/wax-seal.svg +1 -0
  605. package/systems/5e/images/wheelbarrow.svg +1 -0
  606. package/systems/5e/images/whip.svg +1 -0
  607. package/systems/5e/images/whistle.svg +1 -0
  608. package/systems/5e/images/wing-cloak.svg +1 -0
  609. package/systems/5e/images/winged-scepter.svg +1 -0
  610. package/systems/5e/images/wizard-staff.svg +1 -0
  611. package/systems/5e/images/wolf-trap.svg +1 -0
  612. package/systems/5e/images/wood-canoe.svg +1 -0
  613. package/systems/5e/images/wood-club.svg +1 -0
  614. package/systems/5e/instructions/import.md +1 -0
  615. package/systems/5e/instructions/play.md +5 -0
  616. package/systems/5e/instructions/session-zero.md +1 -1
  617. package/systems/5e/package.json +11 -0
  618. package/systems/5e/system.yaml +231 -31
  619. package/systems/5e/words/ar.yaml +74 -0
  620. package/systems/5e/words/cs.yaml +74 -0
  621. package/systems/5e/words/da.yaml +74 -0
  622. package/systems/5e/words/de.yaml +74 -0
  623. package/systems/5e/words/el.yaml +74 -0
  624. package/systems/5e/words/en.yaml +20 -0
  625. package/systems/5e/words/es.yaml +74 -0
  626. package/systems/5e/words/fi.yaml +74 -0
  627. package/systems/5e/words/fr.yaml +74 -0
  628. package/systems/5e/words/he.yaml +74 -0
  629. package/systems/5e/words/hi.yaml +74 -0
  630. package/systems/5e/words/hu.yaml +74 -0
  631. package/systems/5e/words/is.yaml +74 -0
  632. package/systems/5e/words/it.yaml +84 -1
  633. package/systems/5e/words/ja.yaml +74 -0
  634. package/systems/5e/words/ko.yaml +74 -0
  635. package/systems/5e/words/nb.yaml +74 -0
  636. package/systems/5e/words/nl.yaml +74 -0
  637. package/systems/5e/words/pl.yaml +74 -0
  638. package/systems/5e/words/pt.yaml +74 -0
  639. package/systems/5e/words/ro.yaml +74 -0
  640. package/systems/5e/words/ru.yaml +74 -0
  641. package/systems/5e/words/sv.yaml +74 -0
  642. package/systems/5e/words/tr.yaml +74 -0
  643. package/systems/5e/words/uk.yaml +74 -0
  644. package/systems/5e/words/zh.yaml +74 -0
  645. package/systems/5e/world/creatures/Aboleth.md +1 -0
  646. package/systems/5e/world/creatures/Adult Black Dragon.md +2 -0
  647. package/systems/5e/world/creatures/Adult Blue Dragon.md +2 -0
  648. package/systems/5e/world/creatures/Adult Brass Dragon.md +2 -0
  649. package/systems/5e/world/creatures/Adult Bronze Dragon.md +2 -0
  650. package/systems/5e/world/creatures/Adult Copper Dragon.md +2 -0
  651. package/systems/5e/world/creatures/Adult Gold Dragon.md +2 -0
  652. package/systems/5e/world/creatures/Adult Green Dragon.md +2 -0
  653. package/systems/5e/world/creatures/Adult Red Dragon.md +2 -0
  654. package/systems/5e/world/creatures/Adult Silver Dragon.md +2 -0
  655. package/systems/5e/world/creatures/Adult White Dragon.md +2 -0
  656. package/systems/5e/world/creatures/Ancient Black Dragon.md +2 -0
  657. package/systems/5e/world/creatures/Ancient Blue Dragon.md +2 -0
  658. package/systems/5e/world/creatures/Ancient Brass Dragon.md +2 -0
  659. package/systems/5e/world/creatures/Ancient Bronze Dragon.md +2 -0
  660. package/systems/5e/world/creatures/Ancient Copper Dragon.md +2 -0
  661. package/systems/5e/world/creatures/Ancient Gold Dragon.md +2 -0
  662. package/systems/5e/world/creatures/Ancient Green Dragon.md +2 -0
  663. package/systems/5e/world/creatures/Ancient Red Dragon.md +2 -0
  664. package/systems/5e/world/creatures/Ancient Silver Dragon.md +2 -0
  665. package/systems/5e/world/creatures/Ancient White Dragon.md +2 -0
  666. package/systems/5e/world/creatures/Androsphinx.md +1 -0
  667. package/systems/5e/world/creatures/Dwarf.md +1 -0
  668. package/systems/5e/world/creatures/Gynosphinx.md +1 -0
  669. package/systems/5e/world/creatures/Kraken.md +1 -0
  670. package/systems/5e/world/creatures/Lich.md +2 -0
  671. package/systems/5e/world/creatures/Mummy Lord.md +1 -0
  672. package/systems/5e/world/creatures/Solar.md +1 -0
  673. package/systems/5e/world/creatures/Tarrasque.md +2 -0
  674. package/systems/5e/world/creatures/Unicorn.md +1 -0
  675. package/systems/5e/world/creatures/Vampire.md +2 -0
  676. package/systems/5e/world/items/Abacus.md +1 -0
  677. package/systems/5e/world/items/Acid.md +1 -0
  678. package/systems/5e/world/items/Adamantine Armor.md +1 -0
  679. package/systems/5e/world/items/Alchemist's Fire.md +1 -0
  680. package/systems/5e/world/items/Alchemist's Supplies.md +1 -0
  681. package/systems/5e/world/items/Ammunition, +1, +2, or +3.md +1 -0
  682. package/systems/5e/world/items/Amulet of Health.md +2 -0
  683. package/systems/5e/world/items/Amulet of Proof against Detection and Location.md +1 -0
  684. package/systems/5e/world/items/Amulet of the Planes.md +1 -0
  685. package/systems/5e/world/items/Amulet.md +1 -0
  686. package/systems/5e/world/items/Animated Shield.md +1 -0
  687. package/systems/5e/world/items/Antitoxin.md +1 -0
  688. package/systems/5e/world/items/Apparatus of the Crab.md +1 -0
  689. package/systems/5e/world/items/Armor of Invulnerability.md +2 -0
  690. package/systems/5e/world/items/Armor of Resistance.md +1 -0
  691. package/systems/5e/world/items/Armor of Vulnerability.md +1 -0
  692. package/systems/5e/world/items/Armor, +1, +2, or +3.md +1 -0
  693. package/systems/5e/world/items/Arrow of Slaying.md +1 -0
  694. package/systems/5e/world/items/Arrow-Catching Shield.md +1 -0
  695. package/systems/5e/world/items/Arrows.md +2 -0
  696. package/systems/5e/world/items/Backpack.md +1 -0
  697. package/systems/5e/world/items/Bag of Beans.md +1 -0
  698. package/systems/5e/world/items/Bag of Devouring.md +1 -0
  699. package/systems/5e/world/items/Bag of Holding.md +3 -0
  700. package/systems/5e/world/items/Bag of Tricks.md +1 -0
  701. package/systems/5e/world/items/Bagpipes.md +1 -0
  702. package/systems/5e/world/items/Ball Bearings.md +1 -0
  703. package/systems/5e/world/items/Barding.md +1 -0
  704. package/systems/5e/world/items/Barrel.md +1 -0
  705. package/systems/5e/world/items/Basic Poison.md +1 -0
  706. package/systems/5e/world/items/Basket.md +1 -0
  707. package/systems/5e/world/items/Battleaxe.md +1 -0
  708. package/systems/5e/world/items/Bead of Force.md +1 -0
  709. package/systems/5e/world/items/Bedroll.md +1 -0
  710. package/systems/5e/world/items/Bell.md +1 -0
  711. package/systems/5e/world/items/Belt of Dwarvenkind.md +1 -0
  712. package/systems/5e/world/items/Belt of Giant Strength.md +1 -0
  713. package/systems/5e/world/items/Berserker Axe.md +1 -0
  714. package/systems/5e/world/items/Bit and Bridle.md +1 -0
  715. package/systems/5e/world/items/Blanket.md +1 -0
  716. package/systems/5e/world/items/Block and Tackle.md +1 -0
  717. package/systems/5e/world/items/Blowgun Needles.md +2 -0
  718. package/systems/5e/world/items/Blowgun.md +1 -0
  719. package/systems/5e/world/items/Book.md +1 -0
  720. package/systems/5e/world/items/Boots of Elvenkind.md +1 -0
  721. package/systems/5e/world/items/Boots of Levitation.md +1 -0
  722. package/systems/5e/world/items/Boots of Speed.md +1 -0
  723. package/systems/5e/world/items/Boots of Striding and Springing.md +1 -0
  724. package/systems/5e/world/items/Boots of the Winterlands.md +2 -0
  725. package/systems/5e/world/items/Bowl of Commanding Water Elementals.md +1 -0
  726. package/systems/5e/world/items/Bracers of Archery.md +1 -0
  727. package/systems/5e/world/items/Bracers of Defense.md +1 -0
  728. package/systems/5e/world/items/Brazier of Commanding Fire Elementals.md +1 -0
  729. package/systems/5e/world/items/Breastplate.md +1 -0
  730. package/systems/5e/world/items/Brewer's Supplies.md +1 -0
  731. package/systems/5e/world/items/Brooch of Shielding.md +2 -0
  732. package/systems/5e/world/items/Broom of Flying.md +1 -0
  733. package/systems/5e/world/items/Bucket.md +1 -0
  734. package/systems/5e/world/items/Bullseye Lantern.md +1 -0
  735. package/systems/5e/world/items/Burglar's Pack.md +3 -0
  736. package/systems/5e/world/items/Calligrapher's Supplies.md +1 -0
  737. package/systems/5e/world/items/Caltrops.md +1 -0
  738. package/systems/5e/world/items/Candle of Invocation.md +1 -0
  739. package/systems/5e/world/items/Candle.md +1 -0
  740. package/systems/5e/world/items/Cape of the Mountebank.md +1 -0
  741. package/systems/5e/world/items/Carpenter's Tools.md +1 -0
  742. package/systems/5e/world/items/Carpet of Flying.md +1 -0
  743. package/systems/5e/world/items/Carriage.md +1 -0
  744. package/systems/5e/world/items/Cart.md +1 -0
  745. package/systems/5e/world/items/Cartographer's Tools.md +1 -0
  746. package/systems/5e/world/items/Censer of Controlling Air Elementals.md +1 -0
  747. package/systems/5e/world/items/Chain Mail.md +2 -0
  748. package/systems/5e/world/items/Chain Shirt.md +1 -0
  749. package/systems/5e/world/items/Chain.md +1 -0
  750. package/systems/5e/world/items/Chalk.md +1 -0
  751. package/systems/5e/world/items/Chariot.md +1 -0
  752. package/systems/5e/world/items/Chest.md +1 -0
  753. package/systems/5e/world/items/Chime of Opening.md +1 -0
  754. package/systems/5e/world/items/Circlet of Blasting.md +1 -0
  755. package/systems/5e/world/items/Climber's Kit.md +1 -0
  756. package/systems/5e/world/items/Cloak of Arachnida.md +2 -0
  757. package/systems/5e/world/items/Cloak of Displacement.md +1 -0
  758. package/systems/5e/world/items/Cloak of Elvenkind.md +1 -0
  759. package/systems/5e/world/items/Cloak of Protection.md +3 -0
  760. package/systems/5e/world/items/Cloak of the Bat.md +1 -0
  761. package/systems/5e/world/items/Cloak of the Manta Ray.md +1 -0
  762. package/systems/5e/world/items/Club.md +1 -0
  763. package/systems/5e/world/items/Cobbler's Tools.md +1 -0
  764. package/systems/5e/world/items/Common Clothes.md +1 -0
  765. package/systems/5e/world/items/Component Pouch.md +1 -0
  766. package/systems/5e/world/items/Cook's Utensils.md +1 -0
  767. package/systems/5e/world/items/Costume Clothes.md +1 -0
  768. package/systems/5e/world/items/Crossbow Bolt Case.md +1 -0
  769. package/systems/5e/world/items/Crossbow Bolts.md +2 -0
  770. package/systems/5e/world/items/Crowbar.md +1 -0
  771. package/systems/5e/world/items/Crystal Ball.md +1 -0
  772. package/systems/5e/world/items/Crystal.md +1 -0
  773. package/systems/5e/world/items/Cube of Force.md +2 -0
  774. package/systems/5e/world/items/Cubic Gate.md +2 -0
  775. package/systems/5e/world/items/Dagger of Venom.md +1 -0
  776. package/systems/5e/world/items/Dagger.md +1 -0
  777. package/systems/5e/world/items/Dancing Sword.md +1 -0
  778. package/systems/5e/world/items/Dart.md +1 -0
  779. package/systems/5e/world/items/Decanter of Endless Water.md +1 -0
  780. package/systems/5e/world/items/Deck of Illusions.md +1 -0
  781. package/systems/5e/world/items/Deck of Many Things.md +1 -0
  782. package/systems/5e/world/items/Defender.md +1 -0
  783. package/systems/5e/world/items/Demon Armor.md +1 -0
  784. package/systems/5e/world/items/Dice Set.md +1 -0
  785. package/systems/5e/world/items/Dimensional Shackles.md +1 -0
  786. package/systems/5e/world/items/Diplomat's Pack.md +3 -0
  787. package/systems/5e/world/items/Disguise Kit.md +1 -0
  788. package/systems/5e/world/items/Dragon Scale Mail.md +1 -0
  789. package/systems/5e/world/items/Dragon Slayer.md +1 -0
  790. package/systems/5e/world/items/Drum.md +1 -0
  791. package/systems/5e/world/items/Dulcimer.md +1 -0
  792. package/systems/5e/world/items/Dungeoneer's Pack.md +3 -0
  793. package/systems/5e/world/items/Dust of Disappearance.md +1 -0
  794. package/systems/5e/world/items/Dust of Dryness.md +1 -0
  795. package/systems/5e/world/items/Dust of Sneezing and Choking.md +1 -0
  796. package/systems/5e/world/items/Dwarven Plate.md +1 -0
  797. package/systems/5e/world/items/Dwarven Thrower.md +1 -0
  798. package/systems/5e/world/items/Efficient Quiver.md +1 -0
  799. package/systems/5e/world/items/Efreeti Bottle.md +1 -0
  800. package/systems/5e/world/items/Elemental Gem.md +1 -0
  801. package/systems/5e/world/items/Elven Chain.md +1 -0
  802. package/systems/5e/world/items/Emblem.md +1 -0
  803. package/systems/5e/world/items/Entertainer's Pack.md +3 -0
  804. package/systems/5e/world/items/Eversmoking Bottle.md +1 -0
  805. package/systems/5e/world/items/Exotic Saddle.md +1 -0
  806. package/systems/5e/world/items/Explorer's Pack.md +3 -0
  807. package/systems/5e/world/items/Eyes of Charming.md +1 -0
  808. package/systems/5e/world/items/Eyes of Minute Seeing.md +1 -0
  809. package/systems/5e/world/items/Eyes of the Eagle.md +1 -0
  810. package/systems/5e/world/items/Feather Token.md +1 -0
  811. package/systems/5e/world/items/Feed.md +1 -0
  812. package/systems/5e/world/items/Figurine of Wondrous Power.md +1 -0
  813. package/systems/5e/world/items/Fine Clothes.md +1 -0
  814. package/systems/5e/world/items/Fishing Tackle.md +1 -0
  815. package/systems/5e/world/items/Flail.md +1 -0
  816. package/systems/5e/world/items/Flame Tongue.md +1 -0
  817. package/systems/5e/world/items/Flask or Tankard.md +1 -0
  818. package/systems/5e/world/items/Flute.md +1 -0
  819. package/systems/5e/world/items/Folding Boat.md +1 -0
  820. package/systems/5e/world/items/Forgery Kit.md +1 -0
  821. package/systems/5e/world/items/Frost Brand.md +2 -0
  822. package/systems/5e/world/items/Galley.md +1 -0
  823. package/systems/5e/world/items/Gauntlets of Ogre Power.md +2 -0
  824. package/systems/5e/world/items/Gem of Brightness.md +2 -0
  825. package/systems/5e/world/items/Gem of Seeing.md +2 -0
  826. package/systems/5e/world/items/Giant Slayer.md +1 -0
  827. package/systems/5e/world/items/Glaive.md +1 -0
  828. package/systems/5e/world/items/Glamoured Studded Leather.md +1 -0
  829. package/systems/5e/world/items/Glass Bottle.md +1 -0
  830. package/systems/5e/world/items/Glassblower's Tools.md +1 -0
  831. package/systems/5e/world/items/Gloves of Missile Snaring.md +1 -0
  832. package/systems/5e/world/items/Gloves of Swimming and Climbing.md +1 -0
  833. package/systems/5e/world/items/Goggles of Night.md +1 -0
  834. package/systems/5e/world/items/Grappling Hook.md +1 -0
  835. package/systems/5e/world/items/Greataxe.md +1 -0
  836. package/systems/5e/world/items/Greatclub.md +1 -0
  837. package/systems/5e/world/items/Greatsword.md +1 -0
  838. package/systems/5e/world/items/Halberd.md +1 -0
  839. package/systems/5e/world/items/Half Plate Armor.md +1 -0
  840. package/systems/5e/world/items/Hammer of Thunderbolts.md +2 -0
  841. package/systems/5e/world/items/Hammer.md +1 -0
  842. package/systems/5e/world/items/Hand Crossbow.md +1 -0
  843. package/systems/5e/world/items/Handaxe.md +1 -0
  844. package/systems/5e/world/items/Handy Haversack.md +3 -0
  845. package/systems/5e/world/items/Hat of Disguise.md +1 -0
  846. package/systems/5e/world/items/Headband of Intellect.md +2 -0
  847. package/systems/5e/world/items/Healer's Kit.md +1 -0
  848. package/systems/5e/world/items/Heavy Crossbow.md +1 -0
  849. package/systems/5e/world/items/Helm of Brilliance.md +1 -0
  850. package/systems/5e/world/items/Helm of Comprehending Languages.md +1 -0
  851. package/systems/5e/world/items/Helm of Telepathy.md +1 -0
  852. package/systems/5e/world/items/Helm of Teleportation.md +2 -0
  853. package/systems/5e/world/items/Hempen Rope.md +1 -0
  854. package/systems/5e/world/items/Herbalism Kit.md +1 -0
  855. package/systems/5e/world/items/Hide Armor.md +1 -0
  856. package/systems/5e/world/items/Holy Avenger.md +1 -0
  857. package/systems/5e/world/items/Holy Water.md +1 -0
  858. package/systems/5e/world/items/Hooded Lantern.md +1 -0
  859. package/systems/5e/world/items/Horn of Blasting.md +1 -0
  860. package/systems/5e/world/items/Horn of Valhalla.md +1 -0
  861. package/systems/5e/world/items/Horn.md +1 -0
  862. package/systems/5e/world/items/Horseshoes of Speed.md +1 -0
  863. package/systems/5e/world/items/Horseshoes of a Zephyr.md +1 -0
  864. package/systems/5e/world/items/Hourglass.md +1 -0
  865. package/systems/5e/world/items/Hunting Trap.md +1 -0
  866. package/systems/5e/world/items/Immovable Rod.md +1 -0
  867. package/systems/5e/world/items/Ink Pen.md +1 -0
  868. package/systems/5e/world/items/Ink.md +1 -0
  869. package/systems/5e/world/items/Instant Fortress.md +1 -0
  870. package/systems/5e/world/items/Ioun Stone.md +1 -0
  871. package/systems/5e/world/items/Iron Bands of Binding.md +1 -0
  872. package/systems/5e/world/items/Iron Flask.md +1 -0
  873. package/systems/5e/world/items/Iron Pot.md +1 -0
  874. package/systems/5e/world/items/Iron Spikes.md +2 -0
  875. package/systems/5e/world/items/Javelin of Lightning.md +1 -0
  876. package/systems/5e/world/items/Javelin.md +1 -0
  877. package/systems/5e/world/items/Jeweler's Tools.md +1 -0
  878. package/systems/5e/world/items/Jug or Pitcher.md +1 -0
  879. package/systems/5e/world/items/Keelboat.md +1 -0
  880. package/systems/5e/world/items/Ladder.md +1 -0
  881. package/systems/5e/world/items/Lamp.md +1 -0
  882. package/systems/5e/world/items/Lance.md +1 -0
  883. package/systems/5e/world/items/Lantern of Revealing.md +1 -0
  884. package/systems/5e/world/items/Leather Armor.md +1 -0
  885. package/systems/5e/world/items/Leatherworker's Tools.md +1 -0
  886. package/systems/5e/world/items/Light Crossbow.md +1 -0
  887. package/systems/5e/world/items/Light Hammer.md +1 -0
  888. package/systems/5e/world/items/Lock.md +1 -0
  889. package/systems/5e/world/items/Longbow.md +1 -0
  890. package/systems/5e/world/items/Longship.md +1 -0
  891. package/systems/5e/world/items/Longsword.md +1 -0
  892. package/systems/5e/world/items/Luck Blade.md +1 -0
  893. package/systems/5e/world/items/Lute.md +1 -0
  894. package/systems/5e/world/items/Lyre.md +1 -0
  895. package/systems/5e/world/items/Mace of Disruption.md +1 -0
  896. package/systems/5e/world/items/Mace of Smiting.md +1 -0
  897. package/systems/5e/world/items/Mace of Terror.md +2 -0
  898. package/systems/5e/world/items/Mace.md +1 -0
  899. package/systems/5e/world/items/Magnifying Glass.md +1 -0
  900. package/systems/5e/world/items/Manacles.md +1 -0
  901. package/systems/5e/world/items/Mantle of Spell Resistance.md +1 -0
  902. package/systems/5e/world/items/Manual of Bodily Health.md +1 -0
  903. package/systems/5e/world/items/Manual of Gainful Exercise.md +1 -0
  904. package/systems/5e/world/items/Manual of Golems.md +1 -0
  905. package/systems/5e/world/items/Manual of Quickness of Action.md +1 -0
  906. package/systems/5e/world/items/Map or Scroll Case.md +1 -0
  907. package/systems/5e/world/items/Marvelous Pigments.md +1 -0
  908. package/systems/5e/world/items/Mason's Tools.md +1 -0
  909. package/systems/5e/world/items/Maul.md +1 -0
  910. package/systems/5e/world/items/Medallion of Thoughts.md +2 -0
  911. package/systems/5e/world/items/Merchant's Scale.md +1 -0
  912. package/systems/5e/world/items/Mess Kit.md +1 -0
  913. package/systems/5e/world/items/Military Saddle.md +1 -0
  914. package/systems/5e/world/items/Miner's Pick.md +1 -0
  915. package/systems/5e/world/items/Mirror of Life Trapping.md +1 -0
  916. package/systems/5e/world/items/Mithral Armor.md +1 -0
  917. package/systems/5e/world/items/Morningstar.md +1 -0
  918. package/systems/5e/world/items/Navigator's Tools.md +1 -0
  919. package/systems/5e/world/items/Necklace of Adaptation.md +1 -0
  920. package/systems/5e/world/items/Necklace of Fireballs.md +1 -0
  921. package/systems/5e/world/items/Necklace of Prayer Beads.md +1 -0
  922. package/systems/5e/world/items/Net.md +1 -0
  923. package/systems/5e/world/items/Nine Lives Stealer.md +1 -0
  924. package/systems/5e/world/items/Oathbow.md +1 -0
  925. package/systems/5e/world/items/Oil of Etherealness.md +1 -0
  926. package/systems/5e/world/items/Oil of Sharpness.md +1 -0
  927. package/systems/5e/world/items/Oil of Slipperiness.md +1 -0
  928. package/systems/5e/world/items/Oil.md +1 -0
  929. package/systems/5e/world/items/Orb of Dragonkind.md +2 -0
  930. package/systems/5e/world/items/Orb.md +1 -0
  931. package/systems/5e/world/items/Pack Saddle.md +1 -0
  932. package/systems/5e/world/items/Padded Armor.md +1 -0
  933. package/systems/5e/world/items/Painter's Supplies.md +1 -0
  934. package/systems/5e/world/items/Pan Flute.md +1 -0
  935. package/systems/5e/world/items/Paper.md +1 -0
  936. package/systems/5e/world/items/Parchment.md +1 -0
  937. package/systems/5e/world/items/Pearl of Power.md +1 -0
  938. package/systems/5e/world/items/Perfume.md +1 -0
  939. package/systems/5e/world/items/Periapt of Health.md +1 -0
  940. package/systems/5e/world/items/Periapt of Proof against Poison.md +1 -0
  941. package/systems/5e/world/items/Periapt of Wound Closure.md +1 -0
  942. package/systems/5e/world/items/Philter of Love.md +1 -0
  943. package/systems/5e/world/items/Pike.md +1 -0
  944. package/systems/5e/world/items/Pipes of Haunting.md +1 -0
  945. package/systems/5e/world/items/Pipes of the Sewers.md +1 -0
  946. package/systems/5e/world/items/Piton.md +1 -0
  947. package/systems/5e/world/items/Plate Armor of Etherealness.md +1 -0
  948. package/systems/5e/world/items/Plate Armor.md +2 -0
  949. package/systems/5e/world/items/Playing Card Set.md +1 -0
  950. package/systems/5e/world/items/Poisoner's Kit.md +1 -0
  951. package/systems/5e/world/items/Pole.md +1 -0
  952. package/systems/5e/world/items/Portable Hole.md +2 -0
  953. package/systems/5e/world/items/Portable Ram.md +1 -0
  954. package/systems/5e/world/items/Potion of Animal Friendship.md +1 -0
  955. package/systems/5e/world/items/Potion of Clairvoyance.md +1 -0
  956. package/systems/5e/world/items/Potion of Climbing.md +1 -0
  957. package/systems/5e/world/items/Potion of Diminution.md +1 -0
  958. package/systems/5e/world/items/Potion of Flying.md +1 -0
  959. package/systems/5e/world/items/Potion of Gaseous Form.md +1 -0
  960. package/systems/5e/world/items/Potion of Giant Strength.md +1 -0
  961. package/systems/5e/world/items/Potion of Growth.md +1 -0
  962. package/systems/5e/world/items/Potion of Healing.md +1 -0
  963. package/systems/5e/world/items/Potion of Heroism.md +1 -0
  964. package/systems/5e/world/items/Potion of Invisibility.md +1 -0
  965. package/systems/5e/world/items/Potion of Mind Reading.md +1 -0
  966. package/systems/5e/world/items/Potion of Poison.md +1 -0
  967. package/systems/5e/world/items/Potion of Resistance.md +1 -0
  968. package/systems/5e/world/items/Potion of Speed.md +1 -0
  969. package/systems/5e/world/items/Potion of Water Breathing.md +1 -0
  970. package/systems/5e/world/items/Potter's Tools.md +1 -0
  971. package/systems/5e/world/items/Pouch.md +1 -0
  972. package/systems/5e/world/items/Priest's Pack.md +3 -0
  973. package/systems/5e/world/items/Quarterstaff.md +1 -0
  974. package/systems/5e/world/items/Quiver.md +1 -0
  975. package/systems/5e/world/items/Rapier.md +1 -0
  976. package/systems/5e/world/items/Rations.md +1 -0
  977. package/systems/5e/world/items/Reliquary.md +1 -0
  978. package/systems/5e/world/items/Restorative Ointment.md +1 -0
  979. package/systems/5e/world/items/Riding Saddle.md +1 -0
  980. package/systems/5e/world/items/Ring Mail.md +1 -0
  981. package/systems/5e/world/items/Ring of Animal Influence.md +2 -0
  982. package/systems/5e/world/items/Ring of Djinni Summoning.md +1 -0
  983. package/systems/5e/world/items/Ring of Elemental Command.md +2 -0
  984. package/systems/5e/world/items/Ring of Evasion.md +2 -0
  985. package/systems/5e/world/items/Ring of Feather Falling.md +1 -0
  986. package/systems/5e/world/items/Ring of Free Action.md +1 -0
  987. package/systems/5e/world/items/Ring of Invisibility.md +1 -0
  988. package/systems/5e/world/items/Ring of Jumping.md +1 -0
  989. package/systems/5e/world/items/Ring of Mind Shielding.md +1 -0
  990. package/systems/5e/world/items/Ring of Protection.md +3 -0
  991. package/systems/5e/world/items/Ring of Regeneration.md +1 -0
  992. package/systems/5e/world/items/Ring of Resistance.md +1 -0
  993. package/systems/5e/world/items/Ring of Shooting Stars.md +2 -0
  994. package/systems/5e/world/items/Ring of Spell Storing.md +1 -0
  995. package/systems/5e/world/items/Ring of Spell Turning.md +1 -0
  996. package/systems/5e/world/items/Ring of Swimming.md +1 -0
  997. package/systems/5e/world/items/Ring of Telekinesis.md +1 -0
  998. package/systems/5e/world/items/Ring of Three Wishes.md +1 -0
  999. package/systems/5e/world/items/Ring of Warmth.md +2 -0
  1000. package/systems/5e/world/items/Ring of Water Walking.md +1 -0
  1001. package/systems/5e/world/items/Ring of X-ray Vision.md +1 -0
  1002. package/systems/5e/world/items/Ring of the Ram.md +2 -0
  1003. package/systems/5e/world/items/Robe of Eyes.md +1 -0
  1004. package/systems/5e/world/items/Robe of Scintillating Colors.md +2 -0
  1005. package/systems/5e/world/items/Robe of Stars.md +1 -0
  1006. package/systems/5e/world/items/Robe of Useful Items.md +1 -0
  1007. package/systems/5e/world/items/Robe of the Archmagi.md +3 -0
  1008. package/systems/5e/world/items/Robes.md +1 -0
  1009. package/systems/5e/world/items/Rod of Absorption.md +1 -0
  1010. package/systems/5e/world/items/Rod of Alertness.md +1 -0
  1011. package/systems/5e/world/items/Rod of Lordly Might.md +1 -0
  1012. package/systems/5e/world/items/Rod of Rulership.md +1 -0
  1013. package/systems/5e/world/items/Rod of Security.md +1 -0
  1014. package/systems/5e/world/items/Rod.md +1 -0
  1015. package/systems/5e/world/items/Rope of Climbing.md +1 -0
  1016. package/systems/5e/world/items/Rope of Entanglement.md +1 -0
  1017. package/systems/5e/world/items/Rowboat.md +1 -0
  1018. package/systems/5e/world/items/Sack.md +1 -0
  1019. package/systems/5e/world/items/Saddlebags.md +1 -0
  1020. package/systems/5e/world/items/Sailing Ship.md +1 -0
  1021. package/systems/5e/world/items/Scale Mail.md +1 -0
  1022. package/systems/5e/world/items/Scarab of Protection.md +2 -0
  1023. package/systems/5e/world/items/Scholar's Pack.md +3 -0
  1024. package/systems/5e/world/items/Scimitar of Speed.md +1 -0
  1025. package/systems/5e/world/items/Scimitar.md +1 -0
  1026. package/systems/5e/world/items/Sealing Wax.md +1 -0
  1027. package/systems/5e/world/items/Shawm.md +1 -0
  1028. package/systems/5e/world/items/Shield of Missile Attraction.md +2 -0
  1029. package/systems/5e/world/items/Shield, +1, +2, or +3.md +1 -0
  1030. package/systems/5e/world/items/Shield.md +1 -0
  1031. package/systems/5e/world/items/Shortbow.md +1 -0
  1032. package/systems/5e/world/items/Shortsword.md +1 -0
  1033. package/systems/5e/world/items/Shovel.md +1 -0
  1034. package/systems/5e/world/items/Sickle.md +1 -0
  1035. package/systems/5e/world/items/Signal Whistle.md +1 -0
  1036. package/systems/5e/world/items/Signet Ring.md +1 -0
  1037. package/systems/5e/world/items/Silk Rope.md +1 -0
  1038. package/systems/5e/world/items/Sled.md +1 -0
  1039. package/systems/5e/world/items/Sledgehammer.md +1 -0
  1040. package/systems/5e/world/items/Sling Bullets.md +2 -0
  1041. package/systems/5e/world/items/Sling.md +1 -0
  1042. package/systems/5e/world/items/Slippers of Spider Climbing.md +1 -0
  1043. package/systems/5e/world/items/Smith's Tools.md +1 -0
  1044. package/systems/5e/world/items/Soap.md +1 -0
  1045. package/systems/5e/world/items/Sovereign Glue.md +1 -0
  1046. package/systems/5e/world/items/Spear.md +1 -0
  1047. package/systems/5e/world/items/Spell Scroll.md +1 -0
  1048. package/systems/5e/world/items/Spellbook.md +1 -0
  1049. package/systems/5e/world/items/Spellguard Shield.md +1 -0
  1050. package/systems/5e/world/items/Sphere of Annihilation.md +1 -0
  1051. package/systems/5e/world/items/Splint Armor.md +2 -0
  1052. package/systems/5e/world/items/Sprig of Mistletoe.md +1 -0
  1053. package/systems/5e/world/items/Spyglass.md +1 -0
  1054. package/systems/5e/world/items/Staff of Charming.md +1 -0
  1055. package/systems/5e/world/items/Staff of Fire.md +3 -0
  1056. package/systems/5e/world/items/Staff of Frost.md +3 -0
  1057. package/systems/5e/world/items/Staff of Healing.md +2 -0
  1058. package/systems/5e/world/items/Staff of Power.md +5 -0
  1059. package/systems/5e/world/items/Staff of Striking.md +2 -0
  1060. package/systems/5e/world/items/Staff of Swarming Insects.md +2 -0
  1061. package/systems/5e/world/items/Staff of Thunder and Lightning.md +1 -0
  1062. package/systems/5e/world/items/Staff of Withering.md +2 -0
  1063. package/systems/5e/world/items/Staff of the Magi.md +3 -0
  1064. package/systems/5e/world/items/Staff of the Python.md +1 -0
  1065. package/systems/5e/world/items/Staff of the Woodlands.md +2 -0
  1066. package/systems/5e/world/items/Staff.md +1 -0
  1067. package/systems/5e/world/items/Steel Mirror.md +1 -0
  1068. package/systems/5e/world/items/Stone of Controlling Earth Elementals.md +1 -0
  1069. package/systems/5e/world/items/Stone of Good Luck.md +4 -0
  1070. package/systems/5e/world/items/Studded Leather Armor.md +1 -0
  1071. package/systems/5e/world/items/Sun Blade.md +1 -0
  1072. package/systems/5e/world/items/Sword of Life Stealing.md +1 -0
  1073. package/systems/5e/world/items/Sword of Sharpness.md +1 -0
  1074. package/systems/5e/world/items/Sword of Wounding.md +1 -0
  1075. package/systems/5e/world/items/Talisman of Pure Good.md +2 -0
  1076. package/systems/5e/world/items/Talisman of Ultimate Evil.md +2 -0
  1077. package/systems/5e/world/items/Talisman of the Sphere.md +1 -0
  1078. package/systems/5e/world/items/Thieves' Tools.md +1 -0
  1079. package/systems/5e/world/items/Tinderbox.md +1 -0
  1080. package/systems/5e/world/items/Tinker's Tools.md +1 -0
  1081. package/systems/5e/world/items/Tome of Clear Thought.md +1 -0
  1082. package/systems/5e/world/items/Tome of Leadership and Influence.md +1 -0
  1083. package/systems/5e/world/items/Tome of Understanding.md +1 -0
  1084. package/systems/5e/world/items/Torch.md +1 -0
  1085. package/systems/5e/world/items/Totem.md +1 -0
  1086. package/systems/5e/world/items/Traveler's Clothes.md +1 -0
  1087. package/systems/5e/world/items/Trident of Fish Command.md +2 -0
  1088. package/systems/5e/world/items/Trident.md +1 -0
  1089. package/systems/5e/world/items/Two-Person Tent.md +1 -0
  1090. package/systems/5e/world/items/Unarmed Strike.md +1 -0
  1091. package/systems/5e/world/items/Universal Solvent.md +1 -0
  1092. package/systems/5e/world/items/Vial.md +1 -0
  1093. package/systems/5e/world/items/Vicious Weapon.md +1 -0
  1094. package/systems/5e/world/items/Viol.md +1 -0
  1095. package/systems/5e/world/items/Vorpal Sword.md +1 -0
  1096. package/systems/5e/world/items/Wagon.md +1 -0
  1097. package/systems/5e/world/items/Wand of Binding.md +2 -0
  1098. package/systems/5e/world/items/Wand of Enemy Detection.md +2 -0
  1099. package/systems/5e/world/items/Wand of Fear.md +2 -0
  1100. package/systems/5e/world/items/Wand of Fireballs.md +2 -0
  1101. package/systems/5e/world/items/Wand of Lightning Bolts.md +2 -0
  1102. package/systems/5e/world/items/Wand of Magic Detection.md +2 -0
  1103. package/systems/5e/world/items/Wand of Magic Missiles.md +2 -0
  1104. package/systems/5e/world/items/Wand of Paralysis.md +2 -0
  1105. package/systems/5e/world/items/Wand of Polymorph.md +2 -0
  1106. package/systems/5e/world/items/Wand of Secrets.md +2 -0
  1107. package/systems/5e/world/items/Wand of Web.md +2 -0
  1108. package/systems/5e/world/items/Wand of Wonder.md +2 -0
  1109. package/systems/5e/world/items/Wand of the War Mage, +1, +2, or +3.md +1 -0
  1110. package/systems/5e/world/items/Wand.md +1 -0
  1111. package/systems/5e/world/items/War Pick.md +1 -0
  1112. package/systems/5e/world/items/Warhammer.md +1 -0
  1113. package/systems/5e/world/items/Warship.md +1 -0
  1114. package/systems/5e/world/items/Waterskin.md +1 -0
  1115. package/systems/5e/world/items/Weapon, +1, +2, or +3.md +1 -0
  1116. package/systems/5e/world/items/Weaver's Tools.md +1 -0
  1117. package/systems/5e/world/items/Well of Many Worlds.md +1 -0
  1118. package/systems/5e/world/items/Whetstone.md +1 -0
  1119. package/systems/5e/world/items/Whip.md +1 -0
  1120. package/systems/5e/world/items/Wind Fan.md +1 -0
  1121. package/systems/5e/world/items/Winged Boots.md +1 -0
  1122. package/systems/5e/world/items/Wings of Flying.md +1 -0
  1123. package/systems/5e/world/items/Woodcarver's Tools.md +1 -0
  1124. package/systems/5e/world/items/Wooden Staff.md +1 -0
  1125. package/systems/5e/world/items/Yew Wand.md +1 -0
  1126. package/systems/free/instructions/play.md +5 -0
  1127. package/systems/free/instructions/session-zero.md +1 -0
  1128. package/systems/free/system.yaml +12 -0
  1129. package/dist/dashboard/combat.js +0 -72
@@ -10,6 +10,8 @@ import { helperChanges, helperEnvironment, helperState } from "./helpers.js";
10
10
  import { stopTree } from "./stop.js";
11
11
  // How long a picture may take before the engine gives it up (D-308): the probe's took 31 to 45 seconds.
12
12
  const longest = 3 * 60 * 1000;
13
+ // How long a run of the importer may take (D-489).
14
+ const longestReading = 30 * 60 * 1000;
13
15
  /** Why Codex makes no pictures, for the master, and how the player has them, which the dashboard writes in its language (D-308). */
14
16
  export const codexSays = {
15
17
  missing: {
@@ -56,6 +58,10 @@ export function codexPictures() {
56
58
  export function codexWriter(maker = codexPictures()) {
57
59
  return { ready: () => maker.ready().ready, write };
58
60
  }
61
+ /** Codex on this computer as the importer (D-489 (1)): ready where its ChatGPT login makes pictures too. */
62
+ export function codexReader(maker = codexPictures()) {
63
+ return { ready: () => maker.ready().ready, program: () => "Codex", read };
64
+ }
59
65
  /** Whether Codex is there and logged in with ChatGPT: asked in about a second, without spending anything. */
60
66
  function codexReady() {
61
67
  const { state, line } = helperState("codex");
@@ -132,6 +138,32 @@ function write(brief) {
132
138
  child.stdin.end(brief);
133
139
  });
134
140
  }
141
+ /** One run of the importer: Codex in the import's folder, which its sandbox lets it write in and nowhere else (D-489 (1)); its last words, or why it stopped. */
142
+ function read(folder, brief, _writable, signal) {
143
+ const last = join(folder, ".last.txt");
144
+ // The folder is the working one, never in the line: the shell would read a title's $(…) or %…% (Matteo's review, D-489).
145
+ const line = `${codex} exec --ephemeral --skip-git-repo-check -s workspace-write -o .last.txt --ignore-user-config --ignore-rules -`;
146
+ return new Promise((done) => {
147
+ const child = spawn(line, { shell: true, windowsHide: true, cwd: folder, env: helperEnvironment("codex"), stdio: ["pipe", "ignore", "pipe"] });
148
+ // Dropped while it runs: the helper stops with all it started.
149
+ const stop = () => stopTree(child);
150
+ signal?.addEventListener("abort", stop, { once: true });
151
+ let errors = "";
152
+ const timer = setTimeout(() => stopTree(child), longestReading);
153
+ child.stderr.on("data", (chunk) => (errors += chunk.toString()));
154
+ child.stdin.on("error", () => undefined);
155
+ child.on("error", () => undefined);
156
+ child.on("close", (code) => {
157
+ clearTimeout(timer);
158
+ signal?.removeEventListener("abort", stop);
159
+ const said = existsSync(last) ? readFileSync(last, "utf8").trim() : "";
160
+ rmSync(last, { force: true });
161
+ const stopped = errors.trim().split("\n").at(-1)?.trim() ?? "";
162
+ done(code === 0 && said !== "" ? { said } : { failed: stopped === "" ? "Codex stopped without an answer" : `Codex said: ${stopped}` });
163
+ });
164
+ child.stdin.end(brief);
165
+ });
166
+ }
135
167
  /** Why no picture came: the generator's safety check, a failed turn, what Codex said, or the time that ran out. */
136
168
  function refusal(errors, failed, said) {
137
169
  if (/moderation_blocked/.test(errors)) {
@@ -24,3 +24,13 @@ export declare function helperEnvironment(name: HelperName): NodeJS.ProcessEnv;
24
24
  export declare function startLogin(name: HelperName, line: string, wait?: number): Promise<HelperLogin>;
25
25
  /** The line that starts a program installed in the engine's folder, from its package's own bin: node and a script, or the program itself; undefined where it is not there. */
26
26
  export declare function installedLine(name: HelperName, folder: string): string | undefined;
27
+ /**
28
+ * A program as it starts without a shell, for words the player wrote that no shell may read (D-495): node and its package's script, or the program itself;
29
+ * from the engine's folder, else from npm's beside a folder of the PATH. Undefined where neither has it.
30
+ */
31
+ export declare function helperCommand(name: HelperName, folder?: string): {
32
+ command: string;
33
+ args: string[];
34
+ } | undefined;
35
+ /** Queues a message in a Codex thread, as the player's own (D-495): whether Codex took it, in fifteen seconds at most. */
36
+ export declare function queueInCodex(thread: string, message: string, folder?: string): Promise<boolean>;
@@ -3,7 +3,7 @@
3
3
  import { spawn, spawnSync } from "node:child_process";
4
4
  import { existsSync, readFileSync } from "node:fs";
5
5
  import { homedir, tmpdir } from "node:os";
6
- import { join } from "node:path";
6
+ import { delimiter, join } from "node:path";
7
7
  import { stopTree } from "./stop.js";
8
8
  // The npm package of each program.
9
9
  const packages = { codex: "@openai/codex", claude: "@anthropic-ai/claude-code" };
@@ -111,6 +111,7 @@ export function helperChanges() {
111
111
  */
112
112
  export function helperEnvironment(name) {
113
113
  const kept = new Set(["CLAUDE_CONFIG_DIR", "CLAUDE_CODE_GIT_BASH_PATH", "CODEX_HOME"]);
114
+ // Never an API key (D-493): it pays by the call, and a player could spend thousands without noticing; only the player's own plan.
114
115
  const dropped = name === "codex" ? /^(OPENAI_API_KEY|CODEX_API_KEY)$/i : /^(CLAUDE|ANTHROPIC)/i;
115
116
  const own = Object.fromEntries(Object.entries(process.env).filter(([variable]) => kept.has(variable.toUpperCase()) || !dropped.test(variable)));
116
117
  return { ...own, NoDefaultCurrentDirectoryInExePath: "1" };
@@ -171,15 +172,61 @@ export function startLogin(name, line, wait = linkWait) {
171
172
  }
172
173
  /** The line that starts a program installed in the engine's folder, from its package's own bin: node and a script, or the program itself; undefined where it is not there. */
173
174
  export function installedLine(name, folder) {
174
- const packageFolder = join(folder, "node_modules", ...packages[name].split("/"));
175
+ const file = packageBin(name, join(folder, "node_modules"));
176
+ if (file === undefined) {
177
+ return undefined;
178
+ }
179
+ return /\.[cm]?js$/i.test(file) ? `"${process.execPath}" "${file}"` : `"${file}"`;
180
+ }
181
+ /**
182
+ * A program as it starts without a shell, for words the player wrote that no shell may read (D-495): node and its package's script, or the program itself;
183
+ * from the engine's folder, else from npm's beside a folder of the PATH. Undefined where neither has it.
184
+ */
185
+ export function helperCommand(name, folder = toolsFolder()) {
186
+ const folders = (process.env.PATH ?? "").split(delimiter).filter((one) => one !== "");
187
+ const roots = [join(folder, "node_modules"), ...folders.flatMap((one) => [join(one, "node_modules"), join(one, "..", "lib", "node_modules")])];
188
+ for (const root of roots) {
189
+ const file = packageBin(name, root);
190
+ if (file !== undefined) {
191
+ return /\.[cm]?js$/i.test(file) ? { command: process.execPath, args: [file] } : { command: file, args: [] };
192
+ }
193
+ }
194
+ return undefined;
195
+ }
196
+ /** Queues a message in a Codex thread, as the player's own (D-495): whether Codex took it, in fifteen seconds at most. */
197
+ export function queueInCodex(thread, message, folder = toolsFolder()) {
198
+ const codex = helperCommand("codex", folder);
199
+ if (codex === undefined) {
200
+ return Promise.resolve(false);
201
+ }
202
+ return new Promise((done) => {
203
+ let child;
204
+ try {
205
+ // The message joined to its option, so that one that begins with a dash is never read as another.
206
+ child = spawn(codex.command, [...codex.args, "queue", "--thread", thread, `--message=${message}`], { windowsHide: true, cwd: tmpdir(), env: helperEnvironment("codex"), stdio: "ignore" });
207
+ }
208
+ catch {
209
+ done(false);
210
+ return;
211
+ }
212
+ const timer = setTimeout(() => stopTree(child), queueWait).unref();
213
+ child.on("error", () => done(false));
214
+ child.on("exit", (code) => {
215
+ clearTimeout(timer);
216
+ done(code === 0);
217
+ });
218
+ });
219
+ }
220
+ // How long Codex may take to queue a message: the probe's took well under a second.
221
+ const queueWait = 15_000;
222
+ /** The file a package's bin names for a program, in a node_modules folder; undefined where it is not there. */
223
+ function packageBin(name, modules) {
224
+ const packageFolder = join(modules, ...packages[name].split("/"));
175
225
  try {
176
226
  const bin = JSON.parse(readFileSync(join(packageFolder, "package.json"), "utf8")).bin;
177
227
  const relative = typeof bin === "string" ? bin : bin?.[name];
178
228
  const file = relative === undefined ? undefined : join(packageFolder, relative);
179
- if (file === undefined || !existsSync(file)) {
180
- return undefined;
181
- }
182
- return /\.[cm]?js$/i.test(file) ? `"${process.execPath}" "${file}"` : `"${file}"`;
229
+ return file !== undefined && existsSync(file) ? file : undefined;
183
230
  }
184
231
  catch {
185
232
  return undefined;
@@ -1,6 +1,7 @@
1
1
  export { creatureBrief, paintedBrief, placeBrief, portraitBrief, questBrief, svgBrief } from "./briefs.ts";
2
- export { hostPictures, hostWriter } from "./chosen.ts";
3
- export { claudePictures, claudeSays, claudeWriter } from "./claude.ts";
4
- export { codexPictures, codexSays, codexWriter } from "./codex.ts";
5
- export { computerHelpers, helperChanges, helperEnvironment, helperLine, helperState, toolsFolder } from "./helpers.ts";
2
+ export { codexClient, hostPictures, hostReader, hostWriter } from "./chosen.ts";
3
+ export { claudePictures, claudeReader, claudeSays, claudeWriter } from "./claude.ts";
4
+ export { codexPictures, codexReader, codexSays, codexWriter } from "./codex.ts";
5
+ export { computerHelpers, helperChanges, helperCommand, helperEnvironment, helperLine, helperState, queueInCodex, toolsFolder } from "./helpers.ts";
6
+ export { stopProcess } from "./stop.ts";
6
7
  export { cleanSvg, svgIn } from "./svg.ts";
@@ -1,8 +1,9 @@
1
1
  // Pictures made from words (D-308, D-390): what makes them on the player's computer, chosen by the chat in use, injected through Context so that tests never
2
2
  // spend: Codex's painted ones, else Claude's SVG ones; and the two programs themselves, found, installed and signed in with the player's yes (D-424).
3
3
  export { creatureBrief, paintedBrief, placeBrief, portraitBrief, questBrief, svgBrief } from "./briefs.js";
4
- export { hostPictures, hostWriter } from "./chosen.js";
5
- export { claudePictures, claudeSays, claudeWriter } from "./claude.js";
6
- export { codexPictures, codexSays, codexWriter } from "./codex.js";
7
- export { computerHelpers, helperChanges, helperEnvironment, helperLine, helperState, toolsFolder } from "./helpers.js";
4
+ export { codexClient, hostPictures, hostReader, hostWriter } from "./chosen.js";
5
+ export { claudePictures, claudeReader, claudeSays, claudeWriter } from "./claude.js";
6
+ export { codexPictures, codexReader, codexSays, codexWriter } from "./codex.js";
7
+ export { computerHelpers, helperChanges, helperCommand, helperEnvironment, helperLine, helperState, queueInCodex, toolsFolder } from "./helpers.js";
8
+ export { stopProcess } from "./stop.js";
8
9
  export { cleanSvg, svgIn } from "./svg.js";
@@ -1,3 +1,5 @@
1
1
  import { type ChildProcess } from "node:child_process";
2
+ /** Stops a process of another's, by its number, with every process it started: on Windows its tree, elsewhere its group, as a detached process leads one. */
3
+ export declare function stopProcess(pid: number): void;
2
4
  /** Stops a process and, on Windows, every process it started. */
3
5
  export declare function stopTree(child: ChildProcess): void;
@@ -1,5 +1,23 @@
1
1
  // A maker of pictures run through the shell, stopped whole when its time runs out: on Windows the shell's child lives on after the shell, so its tree goes.
2
2
  import { spawnSync } from "node:child_process";
3
+ /** Stops a process of another's, by its number, with every process it started: on Windows its tree, elsewhere its group, as a detached process leads one. */
4
+ export function stopProcess(pid) {
5
+ if (process.platform === "win32") {
6
+ spawnSync("taskkill", ["/pid", String(pid), "/T", "/F"], { windowsHide: true });
7
+ return;
8
+ }
9
+ try {
10
+ process.kill(-pid, "SIGTERM");
11
+ }
12
+ catch {
13
+ try {
14
+ process.kill(pid, "SIGTERM");
15
+ }
16
+ catch {
17
+ // Gone already.
18
+ }
19
+ }
20
+ }
3
21
  /** Stops a process and, on Windows, every process it started. */
4
22
  export function stopTree(child) {
5
23
  if (process.platform === "win32" && child.pid !== undefined) {
@@ -0,0 +1,27 @@
1
+ /** A sentence the player said on the dashboard; rung once the doorbell called the master for it. */
2
+ export interface Act {
3
+ id: string;
4
+ text: string;
5
+ rung?: boolean;
6
+ }
7
+ /** The sentences said and not yet heard, in order, and the ids of those heard lately, for the page to tell. */
8
+ export interface Acts {
9
+ pending: Act[];
10
+ heard: string[];
11
+ }
12
+ export declare function newActs(): Acts;
13
+ /** The player's words as one sentence: what does not show taken away, every break a space; empty when nothing is left. */
14
+ export declare function actText(text: string): string;
15
+ /** Takes back a sentence the master has not heard yet, nor been called for: what became of it. */
16
+ export declare function withdrawAct(acts: Acts, id: string): "withdrawn" | "heard" | "unknown";
17
+ /** Marks the sentences waiting as rung for: the master is called for them. */
18
+ export declare function markRung(acts: Acts): void;
19
+ /** Marks sentences heard, as a call or Codex's queue took them. */
20
+ export declare function markHeard(acts: Acts, ids: string[]): void;
21
+ /** Gives a sentence back to the head of those waiting, as one Codex never took. */
22
+ export declare function giveBackAct(acts: Acts, act: Act): void;
23
+ /** The sentences for the head of the master's call, marked heard; given back, in order, when that call never answers. */
24
+ export declare function takeActs(acts: Acts, quoted: (text: string) => string): {
25
+ lines: string[];
26
+ restore(): void;
27
+ };
@@ -0,0 +1,56 @@
1
+ // What the player does on the dashboard, in their own words (D-493 (1), D-495): sentences the master hears at their next call as said in chat, kept in the
2
+ // chat's memory only, never in the log, and lost with the chat; the player takes one back until the master hears it, or is called for it.
3
+ // How many heard ids the page can still ask about: the strip shows one sentence or two.
4
+ const heardKept = 20;
5
+ // What does not show, or breaks a line in the player's words, from a single sentence: control characters, which no process could take either.
6
+ const unseen = /[\u0000-\u001f\u007f]+/g;
7
+ export function newActs() {
8
+ return { pending: [], heard: [] };
9
+ }
10
+ /** The player's words as one sentence: what does not show taken away, every break a space; empty when nothing is left. */
11
+ export function actText(text) {
12
+ return text.replace(unseen, " ").replace(/\s+/g, " ").trim();
13
+ }
14
+ /** Takes back a sentence the master has not heard yet, nor been called for: what became of it. */
15
+ export function withdrawAct(acts, id) {
16
+ const index = acts.pending.findIndex((act) => act.id === id);
17
+ if (index === -1) {
18
+ return acts.heard.includes(id) ? "heard" : "unknown";
19
+ }
20
+ // The doorbell rang for it: the master is called, and would find nothing.
21
+ if (acts.pending[index].rung === true) {
22
+ return "heard";
23
+ }
24
+ acts.pending.splice(index, 1);
25
+ return "withdrawn";
26
+ }
27
+ /** Marks the sentences waiting as rung for: the master is called for them. */
28
+ export function markRung(acts) {
29
+ acts.pending.forEach((act) => (act.rung = true));
30
+ }
31
+ /** Marks sentences heard, as a call or Codex's queue took them. */
32
+ export function markHeard(acts, ids) {
33
+ acts.pending = acts.pending.filter((act) => !ids.includes(act.id));
34
+ acts.heard = [...acts.heard.filter((id) => !ids.includes(id)), ...ids].slice(-heardKept);
35
+ }
36
+ /** Gives a sentence back to the head of those waiting, as one Codex never took. */
37
+ export function giveBackAct(acts, act) {
38
+ acts.pending.unshift(act);
39
+ acts.heard = acts.heard.filter((id) => id !== act.id);
40
+ }
41
+ /** The sentences for the head of the master's call, marked heard; given back, in order, when that call never answers. */
42
+ export function takeActs(acts, quoted) {
43
+ const taken = [...acts.pending];
44
+ markHeard(acts, taken.map((act) => act.id));
45
+ return {
46
+ lines: taken.map((act) => actNews(act.text, quoted)),
47
+ restore: () => {
48
+ acts.pending = [...taken, ...acts.pending];
49
+ acts.heard = acts.heard.filter((id) => !taken.some((act) => act.id === id));
50
+ },
51
+ };
52
+ }
53
+ /** What the master hears of a sentence: the player's words quoted, as their move in the story, which the master rules as any other (D-493 (1)). */
54
+ function actNews(text, quoted) {
55
+ return `The player acts on the dashboard, in their own words, as if said in chat:\n${quoted(text)}\nRule it as the player's move, and answer as to their words in chat.`;
56
+ }
@@ -1,3 +1,4 @@
1
+ export { bookHeadings, findPages, type PageExcerpt, pageExcerpt, type PageFinding, pageTitle, type SearchedBook } from "./page-search.ts";
1
2
  export { bookTitles, readRuleBook, ruleFiles, type RuleSection, ruleSections } from "./rule-book.ts";
2
3
  export { findRules, hasAllWords, isTitled, type RuleFinding } from "./search.ts";
3
4
  export { type ShownRule, shownRules } from "./shown.ts";
@@ -1,4 +1,6 @@
1
- // Rules as text (D-161, D-178, RUL): the sections of markdown files, found by their words and read exactly as they are written.
1
+ // Rules as text (D-161, D-178, RUL): the sections of markdown files, found by their words and read exactly as they are written; and the pages of the player's
2
+ // books, found as BM25 counts them, each shown by the section the words are in (D-491, LIB-6, LIB-7).
3
+ export { bookHeadings, findPages, pageExcerpt, pageTitle } from "./page-search.js";
2
4
  export { bookTitles, readRuleBook, ruleFiles, ruleSections } from "./rule-book.js";
3
5
  export { findRules, hasAllWords, isTitled } from "./search.js";
4
6
  export { shownRules } from "./shown.js";
@@ -0,0 +1,36 @@
1
+ /** A book as a search reads it: its name, and its pages, or the parts of a document without pages, each with how it is cited. */
2
+ export interface SearchedBook {
3
+ name: string;
4
+ parts: readonly {
5
+ label: string;
6
+ text: string;
7
+ }[];
8
+ }
9
+ /** A page a search finds (LIB-6): its book, where it is among the book's parts, and how well. */
10
+ export interface PageFinding<Book extends SearchedBook = SearchedBook> {
11
+ book: Book;
12
+ part: number;
13
+ score: number;
14
+ }
15
+ /** A page's section as an answer shows it (LIB-7): whether it goes on at the next page, and whether it was cut short of its end. */
16
+ export interface PageExcerpt {
17
+ text: string;
18
+ goesOn: boolean;
19
+ cut: boolean;
20
+ }
21
+ /**
22
+ * The pages a text finds, best first (LIB-6): as BM25 counts them, a word weighing more the fewer pages have it and the more a page repeats it for its length;
23
+ * again for a word in a title of the page, and again for the words in a row. `also` are more searches whose words count as the text's, such as the system's
24
+ * words in the books' language; each is a row of its own. A word that more than half of the pages have finds nothing by itself.
25
+ */
26
+ export declare function findPages<Book extends SearchedBook>(books: Book[], text: string, also?: string[]): PageFinding<Book>[];
27
+ /**
28
+ * The section of a page of a book an answer shows (LIB-7): from the title of the page that holds the most words searched, or else from the title above the line
29
+ * that does, to the next title once it has about sixty words, within about `words` words; the line the words are on always in it. It goes on when it reaches
30
+ * the end of the page unfinished.
31
+ */
32
+ export declare function pageExcerpt(book: SearchedBook, part: number, search: string, also: string[], words: number): PageExcerpt;
33
+ /** The title of a page found that names what was searched, as an answer lists the pages it does not show; undefined when none of its titles does. */
34
+ export declare function pageTitle(book: SearchedBook, part: number, search: string, also: string[]): string | undefined;
35
+ /** The titles of a book in their order, each once: what it holds, as the master hears it when the player turns the book on. */
36
+ export declare function bookHeadings(book: SearchedBook): string[];
@@ -0,0 +1,216 @@
1
+ import { sameWord, searchWords } from "./search.js";
2
+ /**
3
+ * The pages a text finds, best first (LIB-6): as BM25 counts them, a word weighing more the fewer pages have it and the more a page repeats it for its length;
4
+ * again for a word in a title of the page, and again for the words in a row. `also` are more searches whose words count as the text's, such as the system's
5
+ * words in the books' language; each is a row of its own. A word that more than half of the pages have finds nothing by itself.
6
+ */
7
+ export function findPages(books, text, also = []) {
8
+ const rows = [text, ...also].map(searchWords).filter((row) => row.length > 0);
9
+ const searched = [...new Set(rows.flat())];
10
+ const indexed = books.map((book) => ({ book, words: wordsOfBook(book) }));
11
+ const pages = indexed.reduce((sum, { words }) => sum + words.lengths.length, 0);
12
+ const written = indexed.flatMap(({ words }) => words.lengths).filter((length) => length > 0);
13
+ const averageLength = written.length === 0 ? 1 : written.reduce((sum, length) => sum + length, 0) / written.length;
14
+ if (searched.length === 0 || pages === 0) {
15
+ return [];
16
+ }
17
+ // For each book, the forms of each word searched that it has (RUL-4), and on which pages, how many times.
18
+ const counts = indexed.map(({ words }) => searched.map((word) => countsOf(words, word)));
19
+ const having = searched.map((_, index) => counts.reduce((sum, book) => sum + book[index].size, 0));
20
+ const weights = having.map((count) => Math.log(1 + (pages - count + 0.5) / (count + 0.5)));
21
+ const telling = having.map((count) => pages < 2 || count <= pages / 2);
22
+ const found = [];
23
+ indexed.forEach(({ book, words }, bookIndex) => {
24
+ const candidates = new Set(counts[bookIndex].flatMap((perPage, index) => (telling[index] ? [...perPage.keys()] : [])));
25
+ for (const part of [...candidates].sort((first, second) => first - second)) {
26
+ const length = words.lengths[part];
27
+ let score = 0;
28
+ searched.forEach((word, index) => {
29
+ const times = counts[bookIndex][index].get(part) ?? 0;
30
+ score += times === 0 ? 0 : (weights[index] * times * (saturation + 1)) / (times + saturation * (1 - lengthWeight + (lengthWeight * length) / averageLength));
31
+ score += weights[index] * titleShare(words.titles[part], searched, word);
32
+ });
33
+ const inRow = rows.filter((row) => row.length > 1 && hasRow(words.sequences[part], row));
34
+ score += Math.max(0, ...inRow.map((row) => row.reduce((sum, word) => sum + weights[searched.indexOf(word)], 0)));
35
+ found.push({ book, part, score });
36
+ }
37
+ });
38
+ return found.sort((first, second) => second.score - first.score || books.indexOf(first.book) - books.indexOf(second.book) || first.part - second.part);
39
+ }
40
+ /**
41
+ * The section of a page of a book an answer shows (LIB-7): from the title of the page that holds the most words searched, or else from the title above the line
42
+ * that does, to the next title once it has about sixty words, within about `words` words; the line the words are on always in it. It goes on when it reaches
43
+ * the end of the page unfinished.
44
+ */
45
+ export function pageExcerpt(book, part, search, also, words) {
46
+ const { lines, headings, hits, titled } = pageLines(book, part, search, also);
47
+ const bestOf = (indexes) => indexes.filter((index) => hits[index] > 0).sort((first, second) => hits[second] - hits[first] || first - second)[0];
48
+ const best = titled ?? bestOf(lines.map((_, index) => index)) ?? 0;
49
+ let start = titled ?? headingAbove(headings, best) ?? Math.max(0, best - 2);
50
+ // A title too far above leaves the words out: the excerpt starts just before them.
51
+ if (wordCount(lines.slice(start, best + 1).join(" ")) > words * 0.6) {
52
+ start = Math.max(0, best - 2);
53
+ }
54
+ const shown = [];
55
+ let used = 0;
56
+ let index = start;
57
+ let cut = false;
58
+ for (; index < lines.length; index++) {
59
+ const size = wordCount(lines[index]);
60
+ if (index > start && headings[index] && used >= fewestWords) {
61
+ break;
62
+ }
63
+ // A line longer than what is left, as a paragraph of a document without pages, is cut at its words.
64
+ if (used + size > words) {
65
+ shown.push(lines[index].split(/\s+/).filter((word) => word !== "").slice(0, Math.max(0, words - used)).join(" "));
66
+ cut = true;
67
+ break;
68
+ }
69
+ shown.push(lines[index]);
70
+ used += size;
71
+ }
72
+ return { text: `${shown.join("\n").trim()}${cut ? " …" : ""}`, goesOn: !cut && index >= lines.length, cut };
73
+ }
74
+ /** The title of a page found that names what was searched, as an answer lists the pages it does not show; undefined when none of its titles does. */
75
+ export function pageTitle(book, part, search, also) {
76
+ const { lines, titled } = pageLines(book, part, search, also);
77
+ return titled === undefined ? undefined : lines[titled].trim().replace(/^#+\s*/, "");
78
+ }
79
+ /** The titles of a book in their order, each once: what it holds, as the master hears it when the player turns the book on. */
80
+ export function bookHeadings(book) {
81
+ const { running } = wordsOfBook(book);
82
+ const titles = book.parts.flatMap((part) => {
83
+ const lines = part.text.split("\n");
84
+ const headings = titleLines(lines, running);
85
+ return lines.filter((_, index) => headings[index]).map((line) => line.trim().replace(/^#+\s*/, ""));
86
+ });
87
+ return [...new Set(titles)];
88
+ }
89
+ /**
90
+ * A page's lines, which are its titles, how many words searched each holds, and the title that holds the most of them. Words of two letters count only when the
91
+ * search has no longer ones, so that "di" never makes a title.
92
+ */
93
+ function pageLines(book, part, search, also) {
94
+ const lines = book.parts[part].text.split("\n");
95
+ const all = [...new Set([search, ...also].flatMap(searchWords))];
96
+ const searched = all.some((word) => word.length > 2) ? all.filter((word) => word.length > 2) : all;
97
+ const hits = lines.map((line) => {
98
+ const own = searchWords(line);
99
+ return searched.filter((word) => own.some((form) => sameWord(word, form))).length;
100
+ });
101
+ const headings = titleLines(lines, wordsOfBook(book).running);
102
+ const titled = lines.flatMap((_, index) => (headings[index] && hits[index] > 0 ? [index] : [])).sort((first, second) => hits[second] - hits[first] || first - second)[0];
103
+ return { lines, headings, hits, ...(titled === undefined ? {} : { titled }) };
104
+ }
105
+ // BM25's own: how soon a word repeated stops adding, and how much a page's length counts.
106
+ const saturation = 1.2;
107
+ const lengthWeight = 0.75;
108
+ // The longest line that can be a title, in letters and in words, and the fewest letters it has; the fewest words a section shows before the next title ends
109
+ // it, so that a creature's block or a spell keeps its parts.
110
+ const longestTitle = 60;
111
+ const mostTitleWords = 6;
112
+ const fewestTitleLetters = 4;
113
+ const fewestWords = 60;
114
+ // A line on this many pages of a book or more, and on one in fifty, is the page's running head, never a title.
115
+ const runningPages = 3;
116
+ const runningShare = 0.02;
117
+ // How far above a line its title may be.
118
+ const titleDistance = 15;
119
+ // Cut once for each book's parts, which never change: the MCP server keeps a book read (LIB-3).
120
+ const wordsByBook = new WeakMap();
121
+ function wordsOfBook(book) {
122
+ let words = wordsByBook.get(book.parts);
123
+ if (words === undefined) {
124
+ const pagesOf = new Map();
125
+ const sequences = book.parts.map((part) => searchWords(part.text));
126
+ sequences.forEach((sequence, part) => {
127
+ for (const word of sequence) {
128
+ const pages = pagesOf.get(word) ?? new Map();
129
+ pages.set(part, (pages.get(part) ?? 0) + 1);
130
+ pagesOf.set(word, pages);
131
+ }
132
+ });
133
+ const running = runningLines(book);
134
+ const titles = book.parts.map((part) => {
135
+ const lines = part.text.split("\n");
136
+ const headings = titleLines(lines, running);
137
+ return lines.filter((_, index) => headings[index]).map(searchWords);
138
+ });
139
+ words = { pagesOf, lengths: sequences.map((sequence) => sequence.length), titles, sequences, running };
140
+ wordsByBook.set(book.parts, words);
141
+ }
142
+ return words;
143
+ }
144
+ /**
145
+ * Which lines of a page are its titles: a markdown heading, or a short line almost all in capitals, as printed books set them; never a page's running head, a
146
+ * column of short words as FOR DEX CON, or the first line of a paragraph set in capitals, which a line in small letters goes on from.
147
+ */
148
+ function titleLines(lines, running) {
149
+ return lines.map((line, index) => {
150
+ const trimmed = line.trim();
151
+ if (/^#{1,6}\s/.test(trimmed)) {
152
+ return true;
153
+ }
154
+ const cased = trimmed.match(/[\p{Lu}\p{Ll}]/gu)?.length ?? 0;
155
+ const capitals = trimmed.match(/\p{Lu}/gu)?.length ?? 0;
156
+ const short = trimmed.length <= longestTitle && trimmed.split(/\s+/).length <= mostTitleWords;
157
+ const goesOn = /^\s*\p{Ll}/u.test(lines[index + 1] ?? "");
158
+ return short && cased >= 3 && capitals >= cased * 0.7 && new RegExp(`\\p{L}{${fewestTitleLetters}}`, "u").test(trimmed) && !goesOn && !running.has(lineKey(trimmed));
159
+ });
160
+ }
161
+ /**
162
+ * How much of a page's best title a word searched brings (LIB-6): nothing when no title of the page has it; else the share of that title's words the search
163
+ * has, so that CADUTE weighs more than CADUTA MORBIDA for "caduta".
164
+ */
165
+ function titleShare(titles, searched, word) {
166
+ const shares = titles.filter((title) => title.some((form) => sameWord(word, form)))
167
+ .map((title) => title.filter((form) => searched.some((one) => sameWord(one, form))).length / title.length);
168
+ return Math.max(0, ...shares);
169
+ }
170
+ /** The lines a book repeats on many of its pages, as its running heads: by their words, without their numbers. */
171
+ function runningLines(book) {
172
+ const pagesWith = new Map();
173
+ for (const part of book.parts) {
174
+ for (const key of new Set(part.text.split("\n").map(lineKey).filter((key) => key !== ""))) {
175
+ pagesWith.set(key, (pagesWith.get(key) ?? 0) + 1);
176
+ }
177
+ }
178
+ const least = Math.max(runningPages, book.parts.length * runningShare);
179
+ return new Set([...pagesWith].filter(([, count]) => count >= least).map(([key]) => key));
180
+ }
181
+ /** A line as the same running head on every page: its words, without the numbers of the page or chapter. */
182
+ function lineKey(line) {
183
+ return searchWords(line).filter((word) => !/^\d+$/.test(word)).join(" ");
184
+ }
185
+ /** On which pages of a book the forms of a word are, and how many times. */
186
+ function countsOf(words, searched) {
187
+ const counts = new Map();
188
+ for (const [word, pages] of words.pagesOf) {
189
+ if (sameWord(searched, word)) {
190
+ for (const [part, times] of pages) {
191
+ counts.set(part, (counts.get(part) ?? 0) + times);
192
+ }
193
+ }
194
+ }
195
+ return counts;
196
+ }
197
+ /** Whether a page has the words of a row one after another, each in one of its forms. */
198
+ function hasRow(sequence, row) {
199
+ for (let start = 0; start + row.length <= sequence.length; start++) {
200
+ if (row.every((word, offset) => sameWord(word, sequence[start + offset]))) {
201
+ return true;
202
+ }
203
+ }
204
+ return false;
205
+ }
206
+ function headingAbove(headings, line) {
207
+ for (let index = line; index >= Math.max(0, line - titleDistance); index--) {
208
+ if (headings[index]) {
209
+ return index;
210
+ }
211
+ }
212
+ return undefined;
213
+ }
214
+ function wordCount(text) {
215
+ return text.split(/\s+/).filter((word) => word !== "").length;
216
+ }
@@ -16,3 +16,10 @@ export declare function findRules(sections: RuleSection[], text: string): RuleFi
16
16
  export declare function isTitled(section: RuleSection, text: string): boolean;
17
17
  /** Whether a text holds every word of a search, as search compares words: what finds a precedent. */
18
18
  export declare function hasAllWords(text: string, search: string): boolean;
19
+ /** The words of a text as a search compares them: letters and digits, in any case and however accents are written. */
20
+ export declare function searchWords(text: string): string[];
21
+ /**
22
+ * Whether a word of a text is a form of a word searched (RUL-4): the two differ at most in their last three letters, and share at least the first four, or all of a shorter word.
23
+ * Grapple finds grappled and grappling, rest finds resting but not restrained, concentration not conceal; two letters find only themselves.
24
+ */
25
+ export declare function sameWord(searched: string, word: string): boolean;
@@ -49,7 +49,7 @@ export function hasAllWords(text, search) {
49
49
  return searchWords(search).every((searched) => hasForm(words, searched));
50
50
  }
51
51
  /** The words of a text as a search compares them: letters and digits, in any case and however accents are written. */
52
- function searchWords(text) {
52
+ export function searchWords(text) {
53
53
  return comparableText(text).match(/[\p{L}\p{N}]+/gu) ?? [];
54
54
  }
55
55
  /** The words of a section's title, of the titles above it and of its own text, each once: cut once for each section, which never changes (D-194). */
@@ -73,7 +73,7 @@ function hasForm(words, searched) {
73
73
  * Whether a word of a text is a form of a word searched (RUL-4): the two differ at most in their last three letters, and share at least the first four, or all of a shorter word.
74
74
  * Grapple finds grappled and grappling, rest finds resting but not restrained, concentration not conceal; two letters find only themselves.
75
75
  */
76
- function sameWord(searched, word) {
76
+ export function sameWord(searched, word) {
77
77
  if (searched.length <= 2) {
78
78
  return word === searched;
79
79
  }
@@ -30,6 +30,8 @@ export interface Scene {
30
30
  turn: string;
31
31
  squares: number;
32
32
  };
33
+ /** What each one used of their turn since it last came back, as the master marks it (TRN-1): action, attack, reaction. */
34
+ used?: Record<string, string[]>;
33
35
  /** Who attacks the party, as the master marks them, characters or copies by name (D-415): the player's dashboard shows it in a fight. */
34
36
  hostile?: string[];
35
37
  /** What the player character sees of who it does not know by name, by the character's or the creature's name, such as brigante incappucciato (D-416). */
@@ -21,6 +21,7 @@ const sceneSchema = z.looseObject({
21
21
  seen: z.record(z.string(), z.union([z.string(), z.number().transform(String)])).optional(),
22
22
  // What the engine counts, never the master: written wrongly by hand it is forgotten, never a scene that cannot be read.
23
23
  moved: z.object({ round: z.number().int().positive(), turn: z.string(), squares: z.number().nonnegative() }).optional().catch(undefined),
24
+ used: z.record(z.string(), z.array(z.string())).optional().catch(undefined),
24
25
  });
25
26
  /** The open scene, checked; a scene written wrongly by hand fails with what is wrong. */
26
27
  export function readScene(value) {