@heroiclands/package-build 22.15.0 → 22.16.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.
- package/CHANGELOG.md +103 -0
- package/README.md +39 -678
- package/bin/{content-build.mjs → content-commands.mjs} +197 -118
- package/bin/package-build.mjs +303 -42
- package/bin/report.mjs +1 -1
- package/ci/ci-docker.mjs +6 -3
- package/ci/ci-steps.mjs +6 -4
- package/ci/content-format-reference.mjs +106 -0
- package/config.mjs +22 -2
- package/content-config.mjs +74 -134
- package/docs/api.md +294 -234
- package/docs/authoring/assets.md +31 -0
- package/docs/authoring/dates-and-calendars.md +33 -0
- package/docs/authoring/first-note.md +48 -0
- package/docs/authoring/frontmatter.md +40 -0
- package/docs/authoring/links-and-markup.md +137 -0
- package/docs/commands.md +631 -162
- package/docs/configuration.md +176 -140
- package/docs/content-format.md +50 -4229
- package/docs/design.md +32 -0
- package/docs/diagnostics.md +29 -22
- package/docs/getting-started.md +21 -877
- package/docs/guides/book.md +153 -0
- package/docs/guides/e2e.md +143 -0
- package/docs/guides/icons.md +126 -0
- package/docs/guides/localization.md +120 -0
- package/docs/guides/module-project.md +915 -0
- package/docs/guides/packs.md +167 -0
- package/docs/guides/reference-pages.md +148 -0
- package/docs/guides/release-and-deploy.md +114 -0
- package/docs/guides/site.md +152 -0
- package/docs/guides/system-project.md +45 -0
- package/docs/index.md +16 -0
- package/docs/project-setup.md +54 -35
- package/docs/reference/format-details.md +4420 -0
- package/docs/reference/note-types.md +531 -0
- package/engine/address-render.mjs +26 -0
- package/engine/address.mjs +3 -20
- package/engine/anchors.mjs +15 -6
- package/engine/asset-bindings.mjs +6 -2
- package/engine/base-compiler.mjs +47 -11
- package/engine/being-measurements.mjs +70 -0
- package/engine/calendar-artifacts.mjs +1 -1
- package/engine/calendar-choice.mjs +32 -0
- package/engine/calendar-human.mjs +71 -0
- package/engine/calendar-notes.mjs +41 -3
- package/engine/calendars.mjs +8 -1
- package/engine/changelog-lint.mjs +2 -2
- package/engine/code-fences.mjs +23 -97
- package/engine/compile-corpus.mjs +6 -7
- package/engine/content-admonitions.mjs +114 -0
- package/engine/content-captions.mjs +181 -0
- package/engine/content-embeds.mjs +2 -2
- package/engine/content-footnotes.mjs +34 -0
- package/engine/content-format-check.mjs +2 -2
- package/engine/content-format.mjs +127 -73
- package/engine/content-format.yaml +745 -0
- package/engine/content-html.mjs +1 -1
- package/engine/content-icons.mjs +45 -92
- package/engine/content-images.mjs +22 -74
- package/engine/content-index.mjs +12 -3
- package/engine/content-links.mjs +21 -26
- package/engine/content-lint.mjs +1 -5
- package/engine/content-secrets.mjs +3 -1
- package/engine/content-tables.mjs +47 -1257
- package/engine/culture-choice.mjs +32 -0
- package/engine/date-conversion.mjs +47 -0
- package/engine/declaration-check.mjs +87 -0
- package/engine/docs-checks.mjs +140 -0
- package/engine/documentation-links.mjs +31 -0
- package/engine/exported-scene.mjs +1 -1
- package/engine/extension-attributes.mjs +74 -0
- package/engine/field-reference.mjs +1 -1
- package/engine/field-spec.mjs +4 -0
- package/engine/foreign-catalog.mjs +5 -5
- package/engine/format-generated.mjs +15 -0
- package/engine/foundry-entries.mjs +3 -1
- package/engine/frontmatter-lint.mjs +5 -1
- package/engine/frontmatter.mjs +10 -0
- package/engine/generate.mjs +2 -2
- package/engine/helpers.mjs +71 -117
- package/engine/homepage.mjs +2 -3
- package/engine/index-records.mjs +1 -0
- package/engine/index.mjs +18 -3
- package/engine/infobox-registry.mjs +3 -1
- package/engine/infobox.mjs +38 -20
- package/engine/item-compiler.mjs +10 -8
- package/engine/item-docs.mjs +7 -6
- package/engine/itinerary-scenes.mjs +4 -2
- package/engine/journals.mjs +51 -10
- package/engine/macros.mjs +1 -1
- package/engine/map-build.mjs +1 -1
- package/engine/map-dot.mjs +1 -1
- package/engine/map-raster.mjs +4 -2
- package/engine/markdown-expressions.mjs +117 -0
- package/engine/metadata-index.mjs +7 -3
- package/engine/note-addresses.mjs +1 -0
- package/engine/note-dates.mjs +283 -61
- package/engine/note-package.mjs +5 -25
- package/engine/note-state.mjs +6 -2
- package/engine/note-vocabulary.mjs +74 -19
- package/engine/number-words.mjs +75 -0
- package/engine/office-holders.mjs +188 -0
- package/engine/pack-config.mjs +2 -15
- package/engine/pack-router.mjs +24 -5
- package/engine/packages.mjs +3 -2
- package/engine/pathnames.mjs +21 -24
- package/engine/pdf-build.mjs +217 -55
- package/engine/pdf-fonts.mjs +2 -2
- package/engine/pdf-images.mjs +82 -0
- package/engine/pdf-render.mjs +174 -22
- package/engine/populations.mjs +3 -2
- package/engine/project-init.mjs +499 -0
- package/engine/prose-config.mjs +1 -1
- package/engine/prose-lint.mjs +7 -6
- package/engine/readability-lint.mjs +86 -0
- package/engine/reckoning-markers.mjs +205 -93
- package/engine/scenes.mjs +5 -2
- package/engine/schema-check.mjs +3 -3
- package/engine/site-build.mjs +87 -37
- package/engine/site-config.mjs +8 -8
- package/engine/site-index.mjs +4 -0
- package/engine/site-maps.mjs +1 -1
- package/engine/site-preview.mjs +19 -8
- package/engine/social-ties.mjs +5 -1
- package/engine/sql-tables.mjs +92 -22
- package/engine/web-wikilinks.mjs +15 -31
- package/engine/wikilink-syntax.mjs +4 -1
- package/engine/wikilinks.mjs +12 -14
- package/hm3/item-fields.mjs +1 -1
- package/hm3/items.mjs +12 -45
- package/index.mjs +2 -14
- package/manifest.mjs +31 -4
- package/markdownlint-config.mjs +1 -1
- package/package.json +32 -11
- package/prettier-config.mjs +1 -1
- package/sohl/being-info.mjs +3 -145
- package/sohl/index.mjs +1 -1
- package/sohl/infobox.mjs +2 -1
- package/sohl/item-builders.mjs +3 -27
- package/sohl/item-fields.mjs +61 -22
- package/sohl/kb-passes.mjs +2 -2
- package/sohl/note-schemas.mjs +0 -8
- package/stage.mjs +19 -0
- package/types/config.d.mts +12 -3
- package/types/content-config.d.mts +15 -81
- package/types/engine/address-render.d.mts +13 -0
- package/types/engine/address.d.mts +2 -11
- package/types/engine/anchors.d.mts +3 -4
- package/types/engine/asset-bindings.d.mts +9 -2
- package/types/engine/base-compiler.d.mts +1 -2
- package/types/engine/being-measurements.d.mts +16 -0
- package/types/engine/calendar-choice.d.mts +14 -0
- package/types/engine/calendar-human.d.mts +4 -0
- package/types/engine/calendar-notes.d.mts +2 -0
- package/types/engine/calendars.d.mts +5 -3
- package/types/engine/code-fences.d.mts +6 -72
- package/types/engine/compile-corpus.d.mts +1 -3
- package/types/engine/content-admonitions.d.mts +24 -0
- package/types/engine/content-captions.d.mts +45 -0
- package/types/engine/content-footnotes.d.mts +10 -0
- package/types/engine/content-format-check.d.mts +17 -4
- package/types/engine/content-format.d.mts +24 -11
- package/types/engine/content-icons.d.mts +14 -23
- package/types/engine/content-images.d.mts +2 -2
- package/types/engine/content-index.d.mts +9 -2
- package/types/engine/content-links.d.mts +3 -5
- package/types/engine/content-tables.d.mts +11 -140
- package/types/engine/culture-choice.d.mts +14 -0
- package/types/engine/date-conversion.d.mts +4 -0
- package/types/engine/declaration-check.d.mts +24 -0
- package/types/engine/docs-checks.d.mts +28 -0
- package/types/engine/documentation-links.d.mts +7 -0
- package/types/engine/exported-scene.d.mts +6 -2
- package/types/engine/extension-attributes.d.mts +14 -0
- package/types/engine/field-spec.d.mts +9 -0
- package/types/engine/format-generated.d.mts +7 -0
- package/types/engine/frontmatter.d.mts +14 -4
- package/types/engine/generate.d.mts +1 -1
- package/types/engine/helpers.d.mts +37 -92
- package/types/engine/homepage.d.mts +2 -3
- package/types/engine/index.d.mts +5 -0
- package/types/engine/infobox-registry.d.mts +3 -1
- package/types/engine/infobox.d.mts +17 -6
- package/types/engine/item-compiler.d.mts +4 -4
- package/types/engine/item-docs.d.mts +4 -3
- package/types/engine/journals.d.mts +10 -7
- package/types/engine/map-graphviz.d.mts +1 -1
- package/types/engine/markdown-expressions.d.mts +17 -0
- package/types/engine/note-dates.d.mts +47 -1
- package/types/engine/note-package.d.mts +3 -19
- package/types/engine/note-state.d.mts +2 -1
- package/types/engine/note-vocabulary.d.mts +9 -0
- package/types/engine/number-words.d.mts +4 -0
- package/types/engine/office-holders.d.mts +14 -0
- package/types/engine/pack-config.d.mts +1 -1
- package/types/engine/packages.d.mts +3 -2
- package/types/engine/pdf-images.d.mts +38 -0
- package/types/engine/populations.d.mts +2 -2
- package/types/engine/project-init.d.mts +17 -0
- package/types/engine/prose-config.d.mts +1 -1
- package/types/engine/prose-lint.d.mts +3 -2
- package/types/engine/readability-lint.d.mts +22 -0
- package/types/engine/reckoning-markers.d.mts +4 -2
- package/types/engine/schema-check.d.mts +3 -3
- package/types/engine/site-build.d.mts +38 -28
- package/types/engine/site-config.d.mts +2 -2
- package/types/engine/site-index.d.mts +4 -0
- package/types/engine/site-preview.d.mts +1 -1
- package/types/engine/social-ties.d.mts +8 -2
- package/types/engine/sql-tables.d.mts +13 -2
- package/types/engine/web-wikilinks.d.mts +2 -1
- package/types/engine/wikilinks.d.mts +7 -1
- package/types/hm3/items.d.mts +5 -6
- package/types/labels.d.mts +40 -0
- package/types/manifest.d.mts +3 -3
- package/types/sohl/actors.d.mts +2 -2
- package/types/sohl/being-info.d.mts +3 -43
- package/types/sohl/index.d.mts +1 -1
- package/types/sohl/infobox.d.mts +5 -2
- package/types/sohl/item-fields.d.mts +4 -13
- package/types/stage.d.mts +9 -0
- package/CONTENT.md +0 -3239
|
@@ -0,0 +1,531 @@
|
|
|
1
|
+
---
|
|
2
|
+
shortcode: referencenotetypes
|
|
3
|
+
name: { full: "Note types and fields" }
|
|
4
|
+
type: doc
|
|
5
|
+
subType: reference
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# Note types and fields
|
|
9
|
+
|
|
10
|
+
Choose a note's `type` for the subject it describes. Use `subType` when its type declares a more specific genre. Field rules are declared in `engine/note-vocabulary.mjs`; mapping claims and closed vocabularies are recorded in `engine/content-format.yaml`. This page is checked against both declarations.
|
|
11
|
+
|
|
12
|
+
The [first-note guide](../authoring/first-note.md) teaches the shape of a note. [Frontmatter](../authoring/frontmatter.md) explains shared and system-specific values. The [detailed reference](format-details.md) gives the full behavior and examples.
|
|
13
|
+
|
|
14
|
+
## Shared `data` fields
|
|
15
|
+
|
|
16
|
+
These fields are accepted by every note type. A field's value can still be irrelevant to a particular output; the build reports that where it can.
|
|
17
|
+
|
|
18
|
+
| Field | Shape | Meaning |
|
|
19
|
+
| ----------------- | ----------------------------------------------- | ------------------------------------------------------------------------- |
|
|
20
|
+
| `data.id` | string | A fixed document identity when the derived identity is unsuitable. |
|
|
21
|
+
| `data.pack` | string | The shared compendium route, with a system block overriding it. |
|
|
22
|
+
| `data.packFolder` | an Address, or a map of Addresses keyed by pack | The shared compendium folder Address, with a system block overriding it. |
|
|
23
|
+
| `data.harnworld` | map | HârnWorld source details shared by every system. |
|
|
24
|
+
| `data.icon` | an Address | The document's profile art — an `icon` address, resolved into `img`. |
|
|
25
|
+
| `data.banner` | an Address | The page's hero image — an `image` address. Reaches no compiled document. |
|
|
26
|
+
|
|
27
|
+
## Type-specific fields
|
|
28
|
+
|
|
29
|
+
### being
|
|
30
|
+
|
|
31
|
+
**Subtypes:** Open vocabulary.
|
|
32
|
+
|
|
33
|
+
| Field | Shape | Meaning |
|
|
34
|
+
| -------------------------------- | ------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
35
|
+
| `data.social` | map | The being's social profile. |
|
|
36
|
+
| `data.tokenIcon` | an Address | What a token on the canvas wears — an `icon` address; unset, it follows `icon`. |
|
|
37
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
38
|
+
| `data.archetypes` | list | Archetypal behaviours the being fits. |
|
|
39
|
+
| `data.occupation` | string | What the being does for a living. |
|
|
40
|
+
| `data.stations` | list of Addresses | Stations the being holds. |
|
|
41
|
+
| `data.lore` | list of Addresses | Lore concerning this being, such as the standing it holds or the law it lives under. |
|
|
42
|
+
| `data.culture` | an Address | The being's primary culture, as a culture lore note. |
|
|
43
|
+
| `data.homes` | list of Addresses | Places the being calls home. |
|
|
44
|
+
| `data.affiliations` | list of Addresses | Affiliations the being belongs to — traditions, polities, and the rest. |
|
|
45
|
+
| `data.socialTies` | a map keyed by Address | Defining ties directed from this being to others: `patron` (Supports the subject from greater power, wealth, or status.); `friend` (Supports the subject out of goodwill.); `dependent` (Relies on the subject's support or protection.); `acquaintance` (Knows the subject without a strong disposition.); `rival` (Opposes the subject without implacable hostility.); `nemesis` (Opposes the subject personally and implacably.) |
|
|
46
|
+
| `data.gender` | string | `male`, `female` or `other`. |
|
|
47
|
+
| `data.species` | an Address | The being's species, as a lore note. |
|
|
48
|
+
| `data.born` | string | When the being was born — a date, or `unknown` where the birth is unrecorded. Absent, the being was never born. |
|
|
49
|
+
| `data.calendar` | an Address | Calendar used to display this being's dates. |
|
|
50
|
+
| `data.died` | string | When the being died — a date, or `unknown` where the death is unrecorded. Absent, the being is alive. |
|
|
51
|
+
| `data.age` | string | Age in years, stated only to override what `born` says — `34`, or `~34` for an estimate. Unstated beside a dated `born` it is computed; unstated beside an unknown or absent `born` the age is unknown. |
|
|
52
|
+
| `data.ageYears` | number | Written by the compiler beside an `age` estimate — the `~` stripped, the magnitude alone. A note never authors this. |
|
|
53
|
+
| `data.height` | metres or feet and inches | Height in metres or feet and inches. |
|
|
54
|
+
| `data.weight` | kilograms or pounds | Body weight in kilograms or pounds. |
|
|
55
|
+
| `data.frame` | string | Relative frame — `scant`, `light`, `medium`, `large` or `massive`. |
|
|
56
|
+
| `data.appearance.eye_color` | string | Eye colour. |
|
|
57
|
+
| `data.appearance.hair_color` | string | Hair colour. |
|
|
58
|
+
| `data.appearance.skin_color` | string | Skin colour. |
|
|
59
|
+
| `data.appearance.complexion` | string | Complexion. |
|
|
60
|
+
| `data.appearance.extra_features` | list | Anything else a stranger would notice. |
|
|
61
|
+
|
|
62
|
+
**System mappings**
|
|
63
|
+
|
|
64
|
+
| Source | System | Target |
|
|
65
|
+
| ----------------- | ------ | ------------------- |
|
|
66
|
+
| `data.gender` | hm3 | `system.gender` |
|
|
67
|
+
| `data.occupation` | hm3 | `system.occupation` |
|
|
68
|
+
|
|
69
|
+
### homepage
|
|
70
|
+
|
|
71
|
+
**Subtypes:** None.
|
|
72
|
+
|
|
73
|
+
| Field | Shape | Meaning |
|
|
74
|
+
| ----- | ----- | ------------------------------- |
|
|
75
|
+
| — | — | No type-specific `data` fields. |
|
|
76
|
+
|
|
77
|
+
### vehicle
|
|
78
|
+
|
|
79
|
+
**Subtypes:** Open vocabulary.
|
|
80
|
+
|
|
81
|
+
| Field | Shape | Meaning |
|
|
82
|
+
| ----------------------- | ---------- | ------------------------------------------------------------------------------- |
|
|
83
|
+
| `data.tokenIcon` | an Address | What a token on the canvas wears — an `icon` address; unset, it follows `icon`. |
|
|
84
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
85
|
+
|
|
86
|
+
### affiliation
|
|
87
|
+
|
|
88
|
+
**Subtypes:** `guild`, `order`, `polity`, `faithtradition`, `arcanetradition`, `spirittradition`, `lineage`, `venture`, `criminal`, `governmental`, `fellowship`.
|
|
89
|
+
|
|
90
|
+
| Field | Shape | Meaning |
|
|
91
|
+
| ------------------------- | ---------------------- | ----------------------------------------------------------------------------------------------- |
|
|
92
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
93
|
+
| `data.demonym` | string | What one member is called — a Vylarian. |
|
|
94
|
+
| `data.epithet` | string | The by-name it is known by — a god's, an order's, a company's. |
|
|
95
|
+
| `data.symbol` | string | Its emblem in words: a feather atop a golden scale, a chisel carving a star. |
|
|
96
|
+
| `data.governance.model` | string | How the affiliation is governed, where it is. |
|
|
97
|
+
| `data.governance.summary` | string | A sentence on how the governance actually works. |
|
|
98
|
+
| `data.governance.ranks` | list | The ladder of ranks the body confers — level, title, description. |
|
|
99
|
+
| `data.governance.offices` | as authored | Named offices, each with a description and optional dated holders. |
|
|
100
|
+
| `data.seat` | an Address | Where the affiliation's authority sits. |
|
|
101
|
+
| `data.domains` | list of Addresses | Places over which it holds sway. |
|
|
102
|
+
| `data.population` | number | How many people it counts. |
|
|
103
|
+
| `data.economy` | list of Addresses | What its economic life runs on — currencies, banking bodies, goods. |
|
|
104
|
+
| `data.lore` | list of Addresses | Lore concerning it — the peoples it draws on, the god a faith venerates, its law, its calendar. |
|
|
105
|
+
| `data.parents` | list of Addresses | Affiliations it is subordinate to. |
|
|
106
|
+
| `data.relations` | a map keyed by Address | Standing with other affiliations — aligned, unaligned, rival, nemesis. |
|
|
107
|
+
|
|
108
|
+
**System mappings**
|
|
109
|
+
|
|
110
|
+
| Source | System | Target |
|
|
111
|
+
| ---------------- | ------ | ------------------ |
|
|
112
|
+
| `subType` | sohl | `system.subType` |
|
|
113
|
+
| `data.seat` | sohl | `system.seat` |
|
|
114
|
+
| `data.domains` | sohl | `system.domain` |
|
|
115
|
+
| `data.parents` | sohl | `system.parents` |
|
|
116
|
+
| `data.relations` | sohl | `system.relations` |
|
|
117
|
+
|
|
118
|
+
### affliction
|
|
119
|
+
|
|
120
|
+
**Subtypes:** `disease`, `poisontoxin`, `maladiction`.
|
|
121
|
+
|
|
122
|
+
| Field | Shape | Meaning |
|
|
123
|
+
| ---------------------------------- | ------ | -------------------------------------------------------------- |
|
|
124
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
125
|
+
| `data.transmission` | string | How it passes from one host to another. |
|
|
126
|
+
| `data.outcome` | string | Where it ends once it has run its course — `death` or `cured`. |
|
|
127
|
+
| `data.healingRate` | number | How readily a healing test goes well. |
|
|
128
|
+
| `data.contagionIndex` | number | How contagious it is. |
|
|
129
|
+
| `data.outcomeTraumas` | string | Expression returning the traumas recovery leaves behind. |
|
|
130
|
+
| `data.onsetDurationFormula` | string | Roll formula for the delay between contraction and onset. |
|
|
131
|
+
| `data.onsetDurationBase` | number | That delay in seconds, stated outright instead of rolled. |
|
|
132
|
+
| `data.healingCheckDurationFormula` | string | Roll formula for the interval between healing checks. |
|
|
133
|
+
| `data.healingCheckDurationBase` | number | That interval in seconds, stated outright instead of rolled. |
|
|
134
|
+
| `data.resolutionDurationFormula` | string | Roll formula for the time from onset to resolution. |
|
|
135
|
+
| `data.resolutionDurationBase` | number | That time in seconds, stated outright instead of rolled. |
|
|
136
|
+
|
|
137
|
+
**System mappings**
|
|
138
|
+
|
|
139
|
+
| Source | System | Target |
|
|
140
|
+
| ---------------------------------- | ------ | ------------------------------------ |
|
|
141
|
+
| `subType` | sohl | `system.subType` |
|
|
142
|
+
| `data.transmission` | sohl | `system.transmission` |
|
|
143
|
+
| `data.outcome` | sohl | `system.outcome` |
|
|
144
|
+
| `data.contagionIndex` | sohl | `system.contagionIndexBase` |
|
|
145
|
+
| `data.onsetDurationFormula` | sohl | `system.onsetDurationFormula` |
|
|
146
|
+
| `data.onsetDurationBase` | sohl | `system.onsetDurationBase` |
|
|
147
|
+
| `data.healingCheckDurationFormula` | sohl | `system.healingCheckDurationFormula` |
|
|
148
|
+
| `data.healingCheckDurationBase` | sohl | `system.healingCheckDurationBase` |
|
|
149
|
+
| `data.resolutionDurationFormula` | sohl | `system.resolutionDurationFormula` |
|
|
150
|
+
| `data.resolutionDurationBase` | sohl | `system.resolutionDurationBase` |
|
|
151
|
+
|
|
152
|
+
### armorgear
|
|
153
|
+
|
|
154
|
+
**Subtypes:** None.
|
|
155
|
+
|
|
156
|
+
| Field | Shape | Meaning |
|
|
157
|
+
| ----------------------- | ------ | ---------------------------------------------------------- |
|
|
158
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
159
|
+
| `data.weight` | number | What the thing weighs. |
|
|
160
|
+
| `data.value` | number | What the thing is worth. |
|
|
161
|
+
| `data.quality` | number | How well it is made. |
|
|
162
|
+
| `data.durability` | number | How much wear it takes before it fails. |
|
|
163
|
+
|
|
164
|
+
**System mappings**
|
|
165
|
+
|
|
166
|
+
| Source | System | Target |
|
|
167
|
+
| ----------------- | ------ | ----------------------- |
|
|
168
|
+
| `data.weight` | sohl | `system.weightBase` |
|
|
169
|
+
| `data.weight` | hm3 | `system.weight` |
|
|
170
|
+
| `data.value` | sohl | `system.valueBase` |
|
|
171
|
+
| `data.value` | hm3 | `system.value` |
|
|
172
|
+
| `data.quality` | sohl | `system.qualityBase` |
|
|
173
|
+
| `data.durability` | sohl | `system.durabilityBase` |
|
|
174
|
+
|
|
175
|
+
### armorlocation
|
|
176
|
+
|
|
177
|
+
**Subtypes:** Open vocabulary.
|
|
178
|
+
|
|
179
|
+
| Field | Shape | Meaning |
|
|
180
|
+
| ----------------------- | ------ | ---------------------------------------------------------- |
|
|
181
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
182
|
+
|
|
183
|
+
### attribute
|
|
184
|
+
|
|
185
|
+
**Subtypes:** None.
|
|
186
|
+
|
|
187
|
+
| Field | Shape | Meaning |
|
|
188
|
+
| ----------------------- | ------ | ---------------------------------------------------------- |
|
|
189
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
190
|
+
|
|
191
|
+
### concoctiongear
|
|
192
|
+
|
|
193
|
+
**Subtypes:** `mundane`, `exotic`, `elixir`.
|
|
194
|
+
|
|
195
|
+
| Field | Shape | Meaning |
|
|
196
|
+
| ----------------------- | ------ | ---------------------------------------------------------- |
|
|
197
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
198
|
+
| `data.weight` | number | What the thing weighs. |
|
|
199
|
+
| `data.value` | number | What the thing is worth. |
|
|
200
|
+
| `data.quality` | number | How well it is made. |
|
|
201
|
+
| `data.durability` | number | How much wear it takes before it fails. |
|
|
202
|
+
| `data.quantity` | number | How many of the thing there are; one when unstated. |
|
|
203
|
+
| `data.potency` | string | Potency — `na`, `mild`, `strong` or `great`. |
|
|
204
|
+
| `data.strength` | number | Strength; the higher, the stronger. |
|
|
205
|
+
|
|
206
|
+
**System mappings**
|
|
207
|
+
|
|
208
|
+
| Source | System | Target |
|
|
209
|
+
| ----------------- | ------ | ----------------------- |
|
|
210
|
+
| `subType` | sohl | `system.subType` |
|
|
211
|
+
| `data.weight` | sohl | `system.weightBase` |
|
|
212
|
+
| `data.value` | sohl | `system.valueBase` |
|
|
213
|
+
| `data.quality` | sohl | `system.qualityBase` |
|
|
214
|
+
| `data.durability` | sohl | `system.durabilityBase` |
|
|
215
|
+
|
|
216
|
+
### containergear
|
|
217
|
+
|
|
218
|
+
**Subtypes:** None.
|
|
219
|
+
|
|
220
|
+
| Field | Shape | Meaning |
|
|
221
|
+
| ----------------------- | ------ | ---------------------------------------------------------- |
|
|
222
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
223
|
+
| `data.weight` | number | What the thing weighs. |
|
|
224
|
+
| `data.value` | number | What the thing is worth. |
|
|
225
|
+
| `data.quality` | number | How well it is made. |
|
|
226
|
+
| `data.durability` | number | How much wear it takes before it fails. |
|
|
227
|
+
| `data.capacity` | number | How much it holds. |
|
|
228
|
+
|
|
229
|
+
**System mappings**
|
|
230
|
+
|
|
231
|
+
| Source | System | Target |
|
|
232
|
+
| ----------------- | ------ | ----------------------- |
|
|
233
|
+
| `data.weight` | sohl | `system.weightBase` |
|
|
234
|
+
| `data.weight` | hm3 | `system.weight` |
|
|
235
|
+
| `data.value` | sohl | `system.valueBase` |
|
|
236
|
+
| `data.value` | hm3 | `system.value` |
|
|
237
|
+
| `data.quality` | sohl | `system.qualityBase` |
|
|
238
|
+
| `data.durability` | sohl | `system.durabilityBase` |
|
|
239
|
+
| `data.capacity` | hm3 | `system.capacity.max` |
|
|
240
|
+
|
|
241
|
+
### miscgear
|
|
242
|
+
|
|
243
|
+
**Subtypes:** None.
|
|
244
|
+
|
|
245
|
+
| Field | Shape | Meaning |
|
|
246
|
+
| ----------------------- | ------ | ---------------------------------------------------------- |
|
|
247
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
248
|
+
| `data.weight` | number | What the thing weighs. |
|
|
249
|
+
| `data.value` | number | What the thing is worth. |
|
|
250
|
+
| `data.quality` | number | How well it is made. |
|
|
251
|
+
| `data.durability` | number | How much wear it takes before it fails. |
|
|
252
|
+
| `data.quantity` | number | How many of the thing there are; one when unstated. |
|
|
253
|
+
|
|
254
|
+
**System mappings**
|
|
255
|
+
|
|
256
|
+
| Source | System | Target |
|
|
257
|
+
| ----------------- | ------ | ----------------------- |
|
|
258
|
+
| `data.weight` | sohl | `system.weightBase` |
|
|
259
|
+
| `data.weight` | hm3 | `system.weight` |
|
|
260
|
+
| `data.value` | sohl | `system.valueBase` |
|
|
261
|
+
| `data.value` | hm3 | `system.value` |
|
|
262
|
+
| `data.quality` | sohl | `system.qualityBase` |
|
|
263
|
+
| `data.durability` | sohl | `system.durabilityBase` |
|
|
264
|
+
| `data.quantity` | hm3 | `system.quantity` |
|
|
265
|
+
|
|
266
|
+
### mystery
|
|
267
|
+
|
|
268
|
+
**Subtypes:** `boon`, `boost`, `fate`, `grace`, `birthsign`, `other`, `piety`.
|
|
269
|
+
|
|
270
|
+
| Field | Shape | Meaning |
|
|
271
|
+
| ----------------------- | -------------------------------------------- | -------------------------------------------------------------------------- |
|
|
272
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
273
|
+
| `data.assocSkill` | an Address | The skill it is associated with. |
|
|
274
|
+
| `data.assocAffiliation` | an Address | The affiliation it is associated with. |
|
|
275
|
+
| `data.skillAptitudes` | a map keyed by Shortcode or subType selector | Bonuses and penalties, each naming a skill or a `subType:<skill-subtype>`. |
|
|
276
|
+
| `data.level` | number | The magnitude of the mystery. |
|
|
277
|
+
| `data.charges.value` | number | Charges available now; unset means charges are not used. |
|
|
278
|
+
| `data.charges.max` | number | Most charges it can hold; unset means no maximum. |
|
|
279
|
+
|
|
280
|
+
**System mappings**
|
|
281
|
+
|
|
282
|
+
| Source | System | Target |
|
|
283
|
+
| --------------------- | ------ | ----------------------- |
|
|
284
|
+
| `subType` | sohl | `system.subType` |
|
|
285
|
+
| `data.skillAptitudes` | sohl | `system.skillAptitudes` |
|
|
286
|
+
| `data.charges.value` | sohl | `system.charges.value` |
|
|
287
|
+
| `data.charges.max` | sohl | `system.charges.max` |
|
|
288
|
+
|
|
289
|
+
### mysticalability
|
|
290
|
+
|
|
291
|
+
**Subtypes:** `spiritrite`, `spiritaction`, `spiritpower`, `ritualaction`, `divineincantation`, `arcaneincantation`, `arcanetalent`, `spirittalent`, `alchemy`, `divination`.
|
|
292
|
+
|
|
293
|
+
| Field | Shape | Meaning |
|
|
294
|
+
| ----------------------- | ---------- | ---------------------------------------------------------- |
|
|
295
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
296
|
+
| `data.assocSkill` | an Address | The skill it is associated with. |
|
|
297
|
+
| `data.assocAffiliation` | an Address | The affiliation it is associated with. |
|
|
298
|
+
| `data.masteryLevel` | number | Mastery before any modifier. |
|
|
299
|
+
| `data.level` | number | The magnitude of the ability. |
|
|
300
|
+
| `data.charges.value` | number | Charges available now; unset means charges are not used. |
|
|
301
|
+
| `data.charges.max` | number | Most charges it can hold; unset means no maximum. |
|
|
302
|
+
|
|
303
|
+
**System mappings**
|
|
304
|
+
|
|
305
|
+
| Source | System | Target |
|
|
306
|
+
| -------------------- | ------ | ---------------------- |
|
|
307
|
+
| `subType` | sohl | `system.subType` |
|
|
308
|
+
| `data.charges.value` | sohl | `system.charges.value` |
|
|
309
|
+
| `data.charges.max` | sohl | `system.charges.max` |
|
|
310
|
+
|
|
311
|
+
### projectilegear
|
|
312
|
+
|
|
313
|
+
**Subtypes:** `none`, `arrow`, `bolt`, `bullet`, `dart`, `other`.
|
|
314
|
+
|
|
315
|
+
| Field | Shape | Meaning |
|
|
316
|
+
| ----------------------- | ------ | ---------------------------------------------------------- |
|
|
317
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
318
|
+
| `data.weight` | number | What the thing weighs. |
|
|
319
|
+
| `data.value` | number | What the thing is worth. |
|
|
320
|
+
| `data.quality` | number | How well it is made. |
|
|
321
|
+
| `data.durability` | number | How much wear it takes before it fails. |
|
|
322
|
+
| `data.quantity` | number | How many of the thing there are; one when unstated. |
|
|
323
|
+
|
|
324
|
+
**System mappings**
|
|
325
|
+
|
|
326
|
+
| Source | System | Target |
|
|
327
|
+
| ----------------- | ------ | ----------------------- |
|
|
328
|
+
| `subType` | sohl | `system.subType` |
|
|
329
|
+
| `data.weight` | sohl | `system.weightBase` |
|
|
330
|
+
| `data.weight` | hm3 | `system.weight` |
|
|
331
|
+
| `data.value` | sohl | `system.valueBase` |
|
|
332
|
+
| `data.value` | hm3 | `system.value` |
|
|
333
|
+
| `data.quality` | sohl | `system.qualityBase` |
|
|
334
|
+
| `data.durability` | sohl | `system.durabilityBase` |
|
|
335
|
+
| `data.quantity` | hm3 | `system.quantity` |
|
|
336
|
+
|
|
337
|
+
### skill
|
|
338
|
+
|
|
339
|
+
**Subtypes:** `social`, `nature`, `craft`, `lore`, `language`, `script`, `mystical`, `physical`, `combat`, `combattechnique`.
|
|
340
|
+
|
|
341
|
+
| Field | Shape | Meaning |
|
|
342
|
+
| ----------------------- | ---------- | ---------------------------------------------------------- |
|
|
343
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
344
|
+
| `data.masteryLevel` | number | Mastery before any modifier. |
|
|
345
|
+
| `data.parentSkill` | an Address | The skill this one specialises. |
|
|
346
|
+
|
|
347
|
+
**System mappings**
|
|
348
|
+
|
|
349
|
+
| Source | System | Target |
|
|
350
|
+
| ------------------- | ------ | --------------------- |
|
|
351
|
+
| `subType` | sohl | `system.subType` |
|
|
352
|
+
| `data.masteryLevel` | hm3 | `system.masteryLevel` |
|
|
353
|
+
|
|
354
|
+
### trauma
|
|
355
|
+
|
|
356
|
+
**Subtypes:** `injury`, `fear`, `morale`, `pall`, `psycond`, `physcond`, `auralshock`, `fatigue`, `infection`, `shock`, `coma`.
|
|
357
|
+
|
|
358
|
+
| Field | Shape | Meaning |
|
|
359
|
+
| -------------------------------------- | ------ | ------------------------------------------------------------------- |
|
|
360
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
361
|
+
| `data.healingCheckDurationFormula` | string | Roll formula for the interval between healing checks. |
|
|
362
|
+
| `data.healingCheckDurationBase` | number | That interval in seconds, stated outright instead of rolled. |
|
|
363
|
+
| `data.bloodLossAdvanceDurationFormula` | string | Roll formula for the interval between blood-loss advances. |
|
|
364
|
+
| `data.bloodLossAdvanceDurationBase` | number | That interval in seconds. Setting it is what makes the wound bleed. |
|
|
365
|
+
| `data.courseDurationFormula` | string | Roll formula for the interval between course tests. |
|
|
366
|
+
| `data.courseDurationBase` | number | That interval in seconds, stated outright instead of rolled. |
|
|
367
|
+
|
|
368
|
+
**System mappings**
|
|
369
|
+
|
|
370
|
+
| Source | System | Target |
|
|
371
|
+
| -------------------------------------- | ------ | ---------------------------------------- |
|
|
372
|
+
| `subType` | sohl | `system.subType` |
|
|
373
|
+
| `data.healingCheckDurationFormula` | sohl | `system.healingCheckDurationFormula` |
|
|
374
|
+
| `data.healingCheckDurationBase` | sohl | `system.healingCheckDurationBase` |
|
|
375
|
+
| `data.bloodLossAdvanceDurationFormula` | sohl | `system.bloodLossAdvanceDurationFormula` |
|
|
376
|
+
| `data.bloodLossAdvanceDurationBase` | sohl | `system.bloodLossAdvanceDurationBase` |
|
|
377
|
+
| `data.courseDurationFormula` | sohl | `system.courseDurationFormula` |
|
|
378
|
+
| `data.courseDurationBase` | sohl | `system.courseDurationBase` |
|
|
379
|
+
|
|
380
|
+
### weapongear
|
|
381
|
+
|
|
382
|
+
**Subtypes:** None.
|
|
383
|
+
|
|
384
|
+
| Field | Shape | Meaning |
|
|
385
|
+
| ----------------------- | ------ | ---------------------------------------------------------- |
|
|
386
|
+
| `data.templatePriority` | number | Template priority; unset means the note is not a template. |
|
|
387
|
+
| `data.weight` | number | What the thing weighs. |
|
|
388
|
+
| `data.value` | number | What the thing is worth. |
|
|
389
|
+
| `data.quality` | number | How well it is made. |
|
|
390
|
+
| `data.durability` | number | How much wear it takes before it fails. |
|
|
391
|
+
|
|
392
|
+
**System mappings**
|
|
393
|
+
|
|
394
|
+
| Source | System | Target |
|
|
395
|
+
| ----------------- | ------ | ----------------------- |
|
|
396
|
+
| `data.weight` | sohl | `system.weightBase` |
|
|
397
|
+
| `data.weight` | hm3 | `system.weight` |
|
|
398
|
+
| `data.value` | sohl | `system.valueBase` |
|
|
399
|
+
| `data.value` | hm3 | `system.value` |
|
|
400
|
+
| `data.quality` | sohl | `system.qualityBase` |
|
|
401
|
+
| `data.durability` | sohl | `system.durabilityBase` |
|
|
402
|
+
|
|
403
|
+
### lore
|
|
404
|
+
|
|
405
|
+
**Subtypes:** `cosmology`, `deity`, `theology`, `arcana`, `spirit`, `economy`, `law`, `calendar`, `history`, `material`, `folk`, `culture`, `custom`, `bestiary`, `gathering`.
|
|
406
|
+
|
|
407
|
+
Lore records in-world knowledge. A `culture` describes a people; a `custom` describes how they practice a rite, observance, or usage. A `material` describes a physical constituent and its qualities, which may vary by region. See the [lore subtype definitions](format-details.md#type-lore) for the complete vocabulary.
|
|
408
|
+
|
|
409
|
+
| Field | Shape | Meaning |
|
|
410
|
+
| ------------------ | ----------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
|
|
411
|
+
| `data.epoch` | a date | Which in-world day the world's clock reads zero on — `720/1/1`. |
|
|
412
|
+
| `data.months` | list of `{ name, abbreviation?, days }` | The months this calendar keeps, in order — position in the list is position in the year, and the day counts sum to the world's year. |
|
|
413
|
+
| `data.weekdays` | list of `{ name, abbreviation? }` | The days of the week this calendar names, in order. A calendar with no week writes none. |
|
|
414
|
+
| `data.seasons` | list of `{ name, abbreviation?, monthStart?, monthEnd?, dayStart?, dayEnd? }` | The seasons this calendar marks, bounded by month or by day of year. |
|
|
415
|
+
| `data.eras` | list of `{ shortcode, name, marker?, abbreviation?, proclaimedBy?, start, end?, label? }` | The year-counts kept in this calendar. A marker names one era and uses these months. |
|
|
416
|
+
| `data.dateFormats` | map of short, long, full, time, weekHeader, yearHeader, yearLabel, crossCalendar strings | How this calendar writes dates and time in each display context. |
|
|
417
|
+
| `data.event` | event metadata map | A dated occurrence and its relationships to other events and places. |
|
|
418
|
+
|
|
419
|
+
### map
|
|
420
|
+
|
|
421
|
+
**Subtypes:** `battlemap`, `localmap`, `regionalmap`, `totm`.
|
|
422
|
+
|
|
423
|
+
| Field | Shape | Meaning |
|
|
424
|
+
| ---------------------- | ----------- | -------------------------------------------------------------------------------------------------------------------------- |
|
|
425
|
+
| `data.scene` | as authored | A Foundry Scene export with all its authored fields. |
|
|
426
|
+
| `data.fixup` | list | Asset address replacements in an exported Scene. |
|
|
427
|
+
| `data.bgImage` | an Address | The map's background art — an `image` address. |
|
|
428
|
+
| `data.scale` | as authored | Regional map distance per grid unit: {distance, unit}. |
|
|
429
|
+
| `data.dimensions` | list | `[width, height]` in whole pixels — the art's own size. |
|
|
430
|
+
| `data.pxPerGrid` | number | Whole pixels per grid square; must match the art. |
|
|
431
|
+
| `data.navName` | string | Short name for the navigation bar. |
|
|
432
|
+
| `data.levelName` | string | Name of the embedded level. |
|
|
433
|
+
| `data.backgroundColor` | string | Colour shown where the art does not reach. |
|
|
434
|
+
| `data.overlay` | string | Path to the foreground art. |
|
|
435
|
+
| `data.walls` | as authored | Wall segments. |
|
|
436
|
+
| `data.doors` | as authored | Doors. |
|
|
437
|
+
| `data.lights` | as authored | Light sources. |
|
|
438
|
+
| `data.tiles` | as authored | Tiles. |
|
|
439
|
+
| `data.sounds` | as authored | Ambient sounds. |
|
|
440
|
+
| `data.regions` | as authored | Regions and their behaviours. |
|
|
441
|
+
| `data.notes` | as authored | Map pins, each a grid location and an anchor in this note's own body. |
|
|
442
|
+
| `data.place` | an Address | The place this map depicts. Named here and not on the place, because a place has several maps and a map depicts one place. |
|
|
443
|
+
|
|
444
|
+
### place
|
|
445
|
+
|
|
446
|
+
**Subtypes:** `world`, `region`, `settlement`, `site`, `structure`, `feature`, `celestial`.
|
|
447
|
+
|
|
448
|
+
| Field | Shape | Meaning |
|
|
449
|
+
| -------------------------------------- | ----------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
|
|
450
|
+
| `data.calendar` | an Address | Calendar used to display this place's dates. |
|
|
451
|
+
| `data.demonym` | string | What a person from this place is called — a Vylarian. |
|
|
452
|
+
| `data.purpose` | string | The reason this settlement, site, or structure exists, selected from its placeCharacter tags. |
|
|
453
|
+
| `data.lore` | list of Addresses | Lore concerning this place — its peoples, its law, its calendar, its history. |
|
|
454
|
+
| `data.parents` | list of Addresses | Enclosing places this one sits within. |
|
|
455
|
+
| `data.population` | number | Approximate population, to two significant digits. |
|
|
456
|
+
| `data.market` | number | What trade the settlement supports, on a scale of six: 1 hamlet, 2 village, 3 town, 4 market town, 5 city, 6 great city. |
|
|
457
|
+
| `data.borders` | list of `{ to, bearing }` entries | Places sharing a frontier with this one — each the other's shortcode and where it lies from here. |
|
|
458
|
+
| `data.routes` | list of `{ to, bearing, mode, days, terrain?, leagues? }` entries | Journeys from this place's centre — where the destination lies, how it is travelled, and about how many days it takes. |
|
|
459
|
+
| `data.world.equatorialCircumferenceKm` | number | The distance round the body at its equator, in kilometres. |
|
|
460
|
+
| `data.world.surfaceGravityG` | number | Surface gravity, as a multiple of Earth's. |
|
|
461
|
+
| `data.world.axialTiltDegrees` | number | The tilt of the axis, in degrees — what makes the body have seasons. |
|
|
462
|
+
| `data.year.days` | number | How many days the body's year holds. Every calendar's months sum to it. |
|
|
463
|
+
| `data.year.hoursPerDay` | number | How many hours the day divides into. |
|
|
464
|
+
| `data.year.minutesPerHour` | number | How many minutes the hour divides into. |
|
|
465
|
+
| `data.year.secondsPerMinute` | number | How many seconds the minute divides into. |
|
|
466
|
+
| `data.present` | a date | The day the setting stops and play begins — what an age is computed against. |
|
|
467
|
+
| `data.body.diameterKm` | number | The body's diameter, in kilometres. |
|
|
468
|
+
| `data.body.orbitalRadiusKm` | number | How far the body orbits from the one it circles, in kilometres. |
|
|
469
|
+
| `data.body.orbit` | string | The orbit's shape — `circular` means the cycle never varies. |
|
|
470
|
+
| `data.body.inclined` | boolean | Whether the orbit is inclined to the plane the world orbits in. |
|
|
471
|
+
| `data.moon.cycle` | number | How many days the body takes to return to the same phase. |
|
|
472
|
+
| `data.moon.newOn` | a date | A day the body was new, written in the reference calendar. |
|
|
473
|
+
| `data.moon.eclipses` | string | How often the body eclipses or is eclipsed — `never`, `rare`, `occasional` or `frequent`. |
|
|
474
|
+
|
|
475
|
+
### scenario
|
|
476
|
+
|
|
477
|
+
**Subtypes:** `campaign`, `adventure`, `encounter`.
|
|
478
|
+
|
|
479
|
+
| Field | Shape | Meaning |
|
|
480
|
+
| ----------------------- | ----------------- | ------------------------------------------------ |
|
|
481
|
+
| `data.parents` | list of Addresses | Scenarios this one sits within. |
|
|
482
|
+
| `data.locations` | list of Addresses | Places the scenario takes place in. |
|
|
483
|
+
| `data.cast` | list of Addresses | Beings who appear in it. |
|
|
484
|
+
| `data.factions` | list of Addresses | Affiliations with a stake in it. |
|
|
485
|
+
| `data.follows` | list of Addresses | Scenarios that should be played before this one. |
|
|
486
|
+
| `data.status` | string | `draft`, `playtested` or `published`. |
|
|
487
|
+
| `data.party.size` | string | `solo`, `small`, `standard`, `large` or `host`. |
|
|
488
|
+
| `data.party.archetypes` | list | Archetypes the scenario is written for. |
|
|
489
|
+
|
|
490
|
+
### doc
|
|
491
|
+
|
|
492
|
+
**Subtypes:** `rules`, `userguide`, `reference`, `howto`, `concept`, `settingguide`.
|
|
493
|
+
|
|
494
|
+
| Field | Shape | Meaning |
|
|
495
|
+
| ----- | ----- | ------------------------------- |
|
|
496
|
+
| — | — | No type-specific `data` fields. |
|
|
497
|
+
|
|
498
|
+
### macro
|
|
499
|
+
|
|
500
|
+
**Subtypes:** None.
|
|
501
|
+
|
|
502
|
+
| Field | Shape | Meaning |
|
|
503
|
+
| ----- | ----- | ------------------------------- |
|
|
504
|
+
| — | — | No type-specific `data` fields. |
|
|
505
|
+
|
|
506
|
+
### bundle
|
|
507
|
+
|
|
508
|
+
**Subtypes:** None.
|
|
509
|
+
|
|
510
|
+
| Field | Shape | Meaning |
|
|
511
|
+
| --------------- | ----------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
512
|
+
| `data.contents` | list of Addresses | The documents the Adventure holds, as addresses. Empty when unstated. A document of neither `none` nor the system being compiled is left out rather than failing. |
|
|
513
|
+
|
|
514
|
+
### folder
|
|
515
|
+
|
|
516
|
+
**Subtypes:** None.
|
|
517
|
+
|
|
518
|
+
| Field | Shape | Meaning |
|
|
519
|
+
| ------------- | ----------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
520
|
+
| `data.parent` | an Address, or a map of Addresses keyed by pack | The folder this one sits in, as an address — or one address per pack, keyed by pack name with `default` for the rest. Unset at the root. A dead address is a dead-address finding and a cycle is refused, per pack. |
|
|
521
|
+
| `data.color` | string | The folder's colour, as a CSS hex code. Unset for Foundry's default. |
|
|
522
|
+
|
|
523
|
+
## Shared system mappings
|
|
524
|
+
|
|
525
|
+
| Source | System | Target |
|
|
526
|
+
| ----------------------- | ------ | ------------------------- |
|
|
527
|
+
| `shortcode` | sohl | `system.shortcode` |
|
|
528
|
+
| `data.templatePriority` | sohl | `system.templatePriority` |
|
|
529
|
+
| `actionDefs` | sohl | `system.actionDefs` |
|
|
530
|
+
| `notes` | sohl | `system.notes` |
|
|
531
|
+
| `notes` | hm3 | `system.notes` |
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/* SPDX-License-Identifier: GPL-3.0-or-later */
|
|
2
|
+
|
|
3
|
+
import { assertSystemSegment } from "./systems.mjs";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Render the four segments of a complete Address in lowercase.
|
|
7
|
+
* @param {{package: string, system: string, type: string, shortcode: string}} tuple
|
|
8
|
+
* @returns {string} The canonical Address.
|
|
9
|
+
*/
|
|
10
|
+
export function renderAddress(tuple) {
|
|
11
|
+
const { package: pkg, system, type, shortcode } = tuple;
|
|
12
|
+
assertSystemSegment(system, `the address of ${type}-${shortcode}`);
|
|
13
|
+
return `${pkg}-${system}-${type}-${shortcode}`.toLowerCase();
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
/** Render every written suffix of one complete Address. */
|
|
17
|
+
export function addressSuffixes(tuple) {
|
|
18
|
+
const full = renderAddress(tuple);
|
|
19
|
+
const { system, type, shortcode } = tuple;
|
|
20
|
+
return [
|
|
21
|
+
String(shortcode).toLowerCase(),
|
|
22
|
+
[type, shortcode].join("-").toLowerCase(),
|
|
23
|
+
[system, type, shortcode].join("-").toLowerCase(),
|
|
24
|
+
full,
|
|
25
|
+
];
|
|
26
|
+
}
|
package/engine/address.mjs
CHANGED
|
@@ -116,7 +116,8 @@
|
|
|
116
116
|
// `engine/systems.mjs` imports nothing but `engine/address-charset.mjs`, so the
|
|
117
117
|
// direction is toward the leaf and cannot close a cycle.
|
|
118
118
|
import { isAddressSegment } from "./address-charset.mjs";
|
|
119
|
-
import { NO_SYSTEM, NOTE_SYSTEM,
|
|
119
|
+
import { NO_SYSTEM, NOTE_SYSTEM, isSystemSegment } from "./systems.mjs";
|
|
120
|
+
import { renderAddress } from "./address-render.mjs";
|
|
120
121
|
// Document subtype maps identify the system of a note's own Actor or Item.
|
|
121
122
|
import { systemOf } from "./document-subtypes.mjs";
|
|
122
123
|
import { KNOWN_DOCUMENT_SUBTYPE_MAPS } from "./subtype-registry.mjs";
|
|
@@ -128,6 +129,7 @@ import { HOMEPAGE_TYPE } from "./homepage.mjs";
|
|
|
128
129
|
import { loadPackConfig } from "./pack-config.mjs";
|
|
129
130
|
|
|
130
131
|
export { NO_SYSTEM };
|
|
132
|
+
export { renderAddress };
|
|
131
133
|
|
|
132
134
|
/**
|
|
133
135
|
* The one character that separates an Address's segments.
|
|
@@ -342,25 +344,6 @@ function addressTuple(value) {
|
|
|
342
344
|
return Object.freeze(value);
|
|
343
345
|
}
|
|
344
346
|
|
|
345
|
-
/**
|
|
346
|
-
* Render a complete Address as its canonical string.
|
|
347
|
-
*
|
|
348
|
-
* Lowercased, because an Address has one spelling: two names differing only in
|
|
349
|
-
* case are two names nobody can tell apart.
|
|
350
|
-
*
|
|
351
|
-
* @param {AddressTuple} tuple - The complete Address.
|
|
352
|
-
* @returns {string} `package-system-type-shortcode`.
|
|
353
|
-
*/
|
|
354
|
-
export function renderAddress(tuple) {
|
|
355
|
-
const { package: pkg, system, type, shortcode } = tuple;
|
|
356
|
-
// Checked where an address is *written*, not where one is read: a fetched
|
|
357
|
-
// index naming a system this build has never heard of is data to report,
|
|
358
|
-
// while emitting one is a defect in this build. The registry is closed, so
|
|
359
|
-
// an unknown value here can only be a typo or a system nobody declared.
|
|
360
|
-
assertSystemSegment(system, `the address of ${type}-${shortcode}`);
|
|
361
|
-
return `${pkg}-${system}-${type}-${shortcode}`.toLowerCase();
|
|
362
|
-
}
|
|
363
|
-
|
|
364
347
|
/**
|
|
365
348
|
* Whether the canonical type an Address names is accepted at this position.
|
|
366
349
|
*
|