optolith-database-schema 0.36.1 → 0.38.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 +23 -0
- package/README.md +17 -0
- package/gen/types.d.ts +134 -1
- package/lib/types/Locale.d.ts +18 -0
- package/lib/types/Locale.js +19 -0
- package/lib/types/_ActivatableSkillApplicationsAndUses.js +2 -0
- package/lib/types/equipment/item/Book.d.ts +26 -1
- package/lib/types/equipment/item/Book.js +90 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,29 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
## [0.38.0](https://github.com/elyukai/optolith-database-schema/compare/v0.37.0...v0.38.0) (2026-03-14)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### ⚠ BREAKING CHANGES
|
|
9
|
+
|
|
10
|
+
* reconstruction and references can differ per edition
|
|
11
|
+
|
|
12
|
+
### Features
|
|
13
|
+
|
|
14
|
+
* display names for new skill applications and uses ([e3eaca0](https://github.com/elyukai/optolith-database-schema/commit/e3eaca0c25f6597bed456f6ae2edd0ff4afd2dae))
|
|
15
|
+
* reconstruction and references can differ per edition ([8774da6](https://github.com/elyukai/optolith-database-schema/commit/8774da6c72786333b09235ee712d0864778dbbfe))
|
|
16
|
+
|
|
17
|
+
## [0.37.0](https://github.com/elyukai/optolith-database-schema/compare/v0.36.1...v0.37.0) (2026-03-14)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### ⚠ BREAKING CHANGES
|
|
21
|
+
|
|
22
|
+
* more detailed book rules and meta data
|
|
23
|
+
|
|
24
|
+
### Features
|
|
25
|
+
|
|
26
|
+
* more detailed book rules and meta data ([04b3a74](https://github.com/elyukai/optolith-database-schema/commit/04b3a7451e8ccc629b670da95b178f115085363b))
|
|
27
|
+
|
|
5
28
|
## [0.36.1](https://github.com/elyukai/optolith-database-schema/compare/v0.36.0...v0.36.1) (2026-03-13)
|
|
6
29
|
|
|
7
30
|
|
package/README.md
CHANGED
|
@@ -15,3 +15,20 @@ If you want to contribute to the database schema itself, please open an issue or
|
|
|
15
15
|
## Usage
|
|
16
16
|
|
|
17
17
|
If you want to use the database (or parts of it) in your own project (most likely to support Optolith export formats in your own application), you can use the TypeScript sources as a simple database reader, at least if you have a project targeting JavaScript interpreters as well. This way, you already have proper typings. You can extract the database from the installation folder of Optolith and then configure the database reader to your needs.
|
|
18
|
+
|
|
19
|
+
## Semantic Versioning
|
|
20
|
+
|
|
21
|
+
The following situations are considered breaking changes:
|
|
22
|
+
|
|
23
|
+
- Underlying data must be changed in order to comply with the new schema. Examples:
|
|
24
|
+
- Existing optional properties are made required
|
|
25
|
+
- New required properties are added
|
|
26
|
+
- Properties or enumeration cases are removed
|
|
27
|
+
- Code that uses the data must be adjusted in order to use the new version. Examples:
|
|
28
|
+
- Existing required properties are made optional
|
|
29
|
+
- Enumeration cases are added
|
|
30
|
+
- Properties or enumeration cases are removed
|
|
31
|
+
|
|
32
|
+
This implies that breaking changes can occur quite frequently, even if the changes are very small.
|
|
33
|
+
|
|
34
|
+
A minor version bump can represent new optional properties, while patch version might represent adjustments in comments or display names for the editor.
|
package/gen/types.d.ts
CHANGED
|
@@ -237,8 +237,10 @@ export type EnumMap = {
|
|
|
237
237
|
BlessedTraditionType: BlessedTraditionType
|
|
238
238
|
BlessingDuration: BlessingDuration
|
|
239
239
|
BlessingRange: BlessingRange
|
|
240
|
+
BookContentQuality: BookContentQuality
|
|
240
241
|
BookCost: BookCost
|
|
241
242
|
BookCostVariant: BookCostVariant
|
|
243
|
+
BookRules: BookRules
|
|
242
244
|
BookType: BookType
|
|
243
245
|
BurningTime: BurningTime
|
|
244
246
|
CantripDuration: CantripDuration
|
|
@@ -484,6 +486,8 @@ export type TypeAliasMap = {
|
|
|
484
486
|
BlessedTraditionPrerequisite: BlessedTraditionPrerequisite
|
|
485
487
|
BlessedTraditionsSelectOptionCategory: BlessedTraditionsSelectOptionCategory
|
|
486
488
|
BlessingPerformanceParameters: BlessingPerformanceParameters
|
|
489
|
+
BookRulesByEdition: BookRulesByEdition
|
|
490
|
+
BookRulesOfEdition: BookRulesOfEdition
|
|
487
491
|
BySizeCategory: BySizeCategory<unknown>
|
|
488
492
|
CalculationTranslation: CalculationTranslation
|
|
489
493
|
CantripPerformanceParameters: CantripPerformanceParameters
|
|
@@ -703,6 +707,7 @@ export type TypeAliasMap = {
|
|
|
703
707
|
PersonalityTraitEffect: PersonalityTraitEffect
|
|
704
708
|
PersonalityTraitPrerequisite: PersonalityTraitPrerequisite
|
|
705
709
|
PersonalityTraitPrerequisites: PersonalityTraitPrerequisites
|
|
710
|
+
PlainBookRules: PlainBookRules
|
|
706
711
|
PlainCommonProfessions: PlainCommonProfessions
|
|
707
712
|
PlainGeneralPrerequisites: PlainGeneralPrerequisites
|
|
708
713
|
PlainPrerequisites: PlainPrerequisites<unknown>
|
|
@@ -2434,6 +2439,24 @@ export interface Locale {
|
|
|
2434
2439
|
".input {$count :number} {{check required every {$count}. application in the same month}}": string & { __params: { "count": number } }
|
|
2435
2440
|
"see {$link}": string & { __params: { "link": StringableTranslationParameter } }
|
|
2436
2441
|
"CoD": string
|
|
2442
|
+
"Romance Novel": string
|
|
2443
|
+
"Poetry": string
|
|
2444
|
+
"Political Pamphlet": string
|
|
2445
|
+
"Crime Story": string
|
|
2446
|
+
"Fairy Tale": string
|
|
2447
|
+
"Novel": string
|
|
2448
|
+
"Professional Publication": string
|
|
2449
|
+
"Magical Book": string
|
|
2450
|
+
"Religious Works": string
|
|
2451
|
+
"Content Quality": string
|
|
2452
|
+
"Modest": string
|
|
2453
|
+
"Average": string
|
|
2454
|
+
"Demanding": string
|
|
2455
|
+
"CL {$level}": string & { __params: { "level": StringableTranslationParameter } }
|
|
2456
|
+
"Availability": string
|
|
2457
|
+
"Reconstruction": string
|
|
2458
|
+
"References": string
|
|
2459
|
+
"Entertainment": string
|
|
2437
2460
|
"Failed": string
|
|
2438
2461
|
"Progress": string
|
|
2439
2462
|
"Incubation Time": string
|
|
@@ -20016,6 +20039,11 @@ export interface Book {
|
|
|
20016
20039
|
*/
|
|
20017
20040
|
structure_points?: StructurePoints
|
|
20018
20041
|
|
|
20042
|
+
/**
|
|
20043
|
+
* The quality of the book’s content.
|
|
20044
|
+
*/
|
|
20045
|
+
contentQuality?: BookContentQuality
|
|
20046
|
+
|
|
20019
20047
|
/**
|
|
20020
20048
|
* References to where in which publications this entry has been defined. Entries may also be added or removed in later printings.
|
|
20021
20049
|
*/
|
|
@@ -20063,7 +20091,22 @@ export interface BookTranslation {
|
|
|
20063
20091
|
/**
|
|
20064
20092
|
* Special rules text.
|
|
20065
20093
|
*/
|
|
20066
|
-
rules?:
|
|
20094
|
+
rules?: BookRules
|
|
20095
|
+
|
|
20096
|
+
/**
|
|
20097
|
+
* The legality of the item, if specified.
|
|
20098
|
+
*/
|
|
20099
|
+
legality?: string
|
|
20100
|
+
|
|
20101
|
+
/**
|
|
20102
|
+
* The availability of the item, if specified.
|
|
20103
|
+
*/
|
|
20104
|
+
availability?: string
|
|
20105
|
+
|
|
20106
|
+
/**
|
|
20107
|
+
* Special properties or features of the item.
|
|
20108
|
+
*/
|
|
20109
|
+
special?: string
|
|
20067
20110
|
|
|
20068
20111
|
errata?: Errata
|
|
20069
20112
|
}
|
|
@@ -20184,6 +20227,96 @@ export interface IndefiniteBookCostVariantTranslation {
|
|
|
20184
20227
|
description: string
|
|
20185
20228
|
}
|
|
20186
20229
|
|
|
20230
|
+
/**
|
|
20231
|
+
* The quality of the book’s content.
|
|
20232
|
+
*/
|
|
20233
|
+
export type BookContentQuality =
|
|
20234
|
+
| {
|
|
20235
|
+
kind: "Modest"
|
|
20236
|
+
}
|
|
20237
|
+
| {
|
|
20238
|
+
kind: "Average"
|
|
20239
|
+
}
|
|
20240
|
+
| {
|
|
20241
|
+
kind: "Demanding"
|
|
20242
|
+
Demanding: number
|
|
20243
|
+
}
|
|
20244
|
+
|
|
20245
|
+
/**
|
|
20246
|
+
* Skills and abilities you can learn by reading the book, as well as any other rules and effects concerning the book.
|
|
20247
|
+
*/
|
|
20248
|
+
export type BookRules =
|
|
20249
|
+
| {
|
|
20250
|
+
kind: "Plain"
|
|
20251
|
+
Plain: PlainBookRules
|
|
20252
|
+
}
|
|
20253
|
+
| {
|
|
20254
|
+
kind: "Entertainment"
|
|
20255
|
+
}
|
|
20256
|
+
| {
|
|
20257
|
+
kind: "ByEdition"
|
|
20258
|
+
ByEdition: BookRulesByEdition
|
|
20259
|
+
}
|
|
20260
|
+
|
|
20261
|
+
/**
|
|
20262
|
+
* The book’s rules without any special effects or conditions.
|
|
20263
|
+
*/
|
|
20264
|
+
export interface PlainBookRules {
|
|
20265
|
+
/**
|
|
20266
|
+
* The (main) rules text.
|
|
20267
|
+
*/
|
|
20268
|
+
text: string
|
|
20269
|
+
|
|
20270
|
+
/**
|
|
20271
|
+
* Rules for reconstructing certain skills or abilities from the book.
|
|
20272
|
+
*/
|
|
20273
|
+
reconstruction?: string
|
|
20274
|
+
|
|
20275
|
+
/**
|
|
20276
|
+
* References to skills and abilities that, while mentioned in the book, cannot be learned from this book alone.
|
|
20277
|
+
*/
|
|
20278
|
+
references?: string
|
|
20279
|
+
|
|
20280
|
+
/**
|
|
20281
|
+
* Additional rules text that comes after all other rules.
|
|
20282
|
+
*/
|
|
20283
|
+
textAfter?: string
|
|
20284
|
+
}
|
|
20285
|
+
|
|
20286
|
+
/**
|
|
20287
|
+
* The book’s rules with differences between each edition and more differentiation between types of rules.
|
|
20288
|
+
*/
|
|
20289
|
+
export interface BookRulesByEdition {
|
|
20290
|
+
editions: BookRulesOfEdition[]
|
|
20291
|
+
|
|
20292
|
+
/**
|
|
20293
|
+
* Additional rules text that comes after all other rules.
|
|
20294
|
+
*/
|
|
20295
|
+
textAfter?: string
|
|
20296
|
+
}
|
|
20297
|
+
|
|
20298
|
+
export interface BookRulesOfEdition {
|
|
20299
|
+
/**
|
|
20300
|
+
* The edition(s) the rules apply to.
|
|
20301
|
+
*/
|
|
20302
|
+
label: string
|
|
20303
|
+
|
|
20304
|
+
/**
|
|
20305
|
+
* The rules text.
|
|
20306
|
+
*/
|
|
20307
|
+
text: string
|
|
20308
|
+
|
|
20309
|
+
/**
|
|
20310
|
+
* Rules for reconstructing certain skills or abilities from the book.
|
|
20311
|
+
*/
|
|
20312
|
+
reconstruction?: string
|
|
20313
|
+
|
|
20314
|
+
/**
|
|
20315
|
+
* References to skills and abilities that, while mentioned in the book, cannot be learned from this book alone.
|
|
20316
|
+
*/
|
|
20317
|
+
references?: string
|
|
20318
|
+
}
|
|
20319
|
+
|
|
20187
20320
|
export interface CeremonialItem {
|
|
20188
20321
|
/**
|
|
20189
20322
|
* The cost in silverthalers.
|
package/lib/types/Locale.d.ts
CHANGED
|
@@ -1477,6 +1477,24 @@ export declare const Locale: DB.Entity<"Locale", {
|
|
|
1477
1477
|
".input {$count :number} {{check required every {$count}. application in the same month}}": null;
|
|
1478
1478
|
"see {$link}": null;
|
|
1479
1479
|
CoD: null;
|
|
1480
|
+
"Romance Novel": null;
|
|
1481
|
+
Poetry: null;
|
|
1482
|
+
"Political Pamphlet": null;
|
|
1483
|
+
"Crime Story": null;
|
|
1484
|
+
"Fairy Tale": null;
|
|
1485
|
+
Novel: null;
|
|
1486
|
+
"Professional Publication": null;
|
|
1487
|
+
"Magical Book": null;
|
|
1488
|
+
"Religious Works": null;
|
|
1489
|
+
"Content Quality": null;
|
|
1490
|
+
Modest: null;
|
|
1491
|
+
Average: null;
|
|
1492
|
+
Demanding: null;
|
|
1493
|
+
"CL {$level}": null;
|
|
1494
|
+
Availability: null;
|
|
1495
|
+
Reconstruction: null;
|
|
1496
|
+
References: null;
|
|
1497
|
+
Entertainment: null;
|
|
1480
1498
|
Failed: null;
|
|
1481
1499
|
Progress: null;
|
|
1482
1500
|
"Incubation Time": null;
|
package/lib/types/Locale.js
CHANGED
|
@@ -1518,6 +1518,25 @@ export const Locale = DB.Entity(import.meta.url, {
|
|
|
1518
1518
|
".input {$count :number} {{check required every {$count}. application in the same month}}": null,
|
|
1519
1519
|
"see {$link}": null,
|
|
1520
1520
|
"CoD": null,
|
|
1521
|
+
// books
|
|
1522
|
+
"Romance Novel": null,
|
|
1523
|
+
"Poetry": null,
|
|
1524
|
+
"Political Pamphlet": null,
|
|
1525
|
+
"Crime Story": null,
|
|
1526
|
+
"Fairy Tale": null,
|
|
1527
|
+
"Novel": null,
|
|
1528
|
+
"Professional Publication": null,
|
|
1529
|
+
"Magical Book": null,
|
|
1530
|
+
"Religious Works": null,
|
|
1531
|
+
"Content Quality": null,
|
|
1532
|
+
"Modest": null,
|
|
1533
|
+
"Average": null,
|
|
1534
|
+
"Demanding": null,
|
|
1535
|
+
"CL {$level}": null,
|
|
1536
|
+
"Availability": null,
|
|
1537
|
+
"Reconstruction": null,
|
|
1538
|
+
"References": null,
|
|
1539
|
+
"Entertainment": null,
|
|
1521
1540
|
// sex practices
|
|
1522
1541
|
"Failed": null,
|
|
1523
1542
|
// diseases
|
|
@@ -36,6 +36,7 @@ export const NewSkillApplication = DB.Entity(import.meta.url, {
|
|
|
36
36
|
}),
|
|
37
37
|
});
|
|
38
38
|
export const skill_applications = DB.Required({
|
|
39
|
+
displayName: "New Skill Applications",
|
|
39
40
|
comment: "Registers new skill applications, which get enabled once this entry is activated. It specifies an entry-unique identifier and the skill it belongs to. A translation can be left out if its name equals the name of the origin activatable entry.",
|
|
40
41
|
type: DB.ChildEntities(NewSkillApplication),
|
|
41
42
|
});
|
|
@@ -73,6 +74,7 @@ export const SkillUse = DB.Entity(import.meta.url, {
|
|
|
73
74
|
}),
|
|
74
75
|
});
|
|
75
76
|
export const skill_uses = DB.Required({
|
|
77
|
+
displayName: "Skill Uses",
|
|
76
78
|
comment: "Registers uses, which get enabled once this entry is activated. It specifies an entry-unique identifier and the skill it belongs to. A translation can be left out if its name equals the name of the origin activatable entry.",
|
|
77
79
|
type: DB.ChildEntities(SkillUse),
|
|
78
80
|
});
|
|
@@ -88,6 +88,11 @@ export declare const Book: DB.Entity<"Book", {
|
|
|
88
88
|
structure_points: DB.MemberDecl<DB.IncludeIdentifier<[], DB.TypeAlias<"StructurePoints", DB.Array<DB.IncludeIdentifier<[], DB.TypeAlias<"StructurePointsComponent", DB.Object<{
|
|
89
89
|
points: DB.MemberDecl<DB.Integer, true>;
|
|
90
90
|
}>, []>>>, []>>, false>;
|
|
91
|
+
contentQuality: DB.MemberDecl<DB.IncludeIdentifier<[], DB.Enum<"BookContentQuality", {
|
|
92
|
+
Modest: DB.EnumCase<null>;
|
|
93
|
+
Average: DB.EnumCase<null>;
|
|
94
|
+
Demanding: DB.EnumCase<DB.Integer>;
|
|
95
|
+
}, []>>, false>;
|
|
91
96
|
src: DB.MemberDecl<DB.IncludeIdentifier<[], DB.TypeAlias<"PublicationRefs", DB.Array<DB.IncludeIdentifier<[], DB.TypeAlias<"PublicationRef", DB.Object<{
|
|
92
97
|
id: DB.MemberDecl<DB.ReferenceIdentifier, true>;
|
|
93
98
|
occurrences: DB.MemberDecl<DB.NestedEntityMap<string, {
|
|
@@ -135,7 +140,27 @@ export declare const Book: DB.Entity<"Book", {
|
|
|
135
140
|
language: DB.MemberDecl<DB.String, false>;
|
|
136
141
|
script: DB.MemberDecl<DB.String, false>;
|
|
137
142
|
note: DB.MemberDecl<DB.String, false>;
|
|
138
|
-
rules: DB.MemberDecl<DB.
|
|
143
|
+
rules: DB.MemberDecl<DB.IncludeIdentifier<[], DB.Enum<"BookRules", {
|
|
144
|
+
Plain: DB.EnumCase<DB.IncludeIdentifier<[], DB.TypeAlias<"PlainBookRules", DB.Object<{
|
|
145
|
+
text: DB.MemberDecl<DB.String, true>;
|
|
146
|
+
reconstruction: DB.MemberDecl<DB.String, false>;
|
|
147
|
+
references: DB.MemberDecl<DB.String, false>;
|
|
148
|
+
textAfter: DB.MemberDecl<DB.String, false>;
|
|
149
|
+
}>, []>>>;
|
|
150
|
+
Entertainment: DB.EnumCase<null>;
|
|
151
|
+
ByEdition: DB.EnumCase<DB.IncludeIdentifier<[], DB.TypeAlias<"BookRulesByEdition", DB.Object<{
|
|
152
|
+
editions: DB.MemberDecl<DB.Array<DB.IncludeIdentifier<[], DB.TypeAlias<"BookRulesOfEdition", DB.Object<{
|
|
153
|
+
label: DB.MemberDecl<DB.String, true>;
|
|
154
|
+
text: DB.MemberDecl<DB.String, true>;
|
|
155
|
+
reconstruction: DB.MemberDecl<DB.String, false>;
|
|
156
|
+
references: DB.MemberDecl<DB.String, false>;
|
|
157
|
+
}>, []>>>, true>;
|
|
158
|
+
textAfter: DB.MemberDecl<DB.String, false>;
|
|
159
|
+
}>, []>>>;
|
|
160
|
+
}, []>>, false>;
|
|
161
|
+
legality: DB.MemberDecl<DB.String, false>;
|
|
162
|
+
availability: DB.MemberDecl<DB.String, false>;
|
|
163
|
+
special: DB.MemberDecl<DB.String, false>;
|
|
139
164
|
errata: DB.MemberDecl<DB.IncludeIdentifier<[], DB.TypeAlias<"Errata", DB.Array<DB.IncludeIdentifier<[], DB.TypeAlias<"Erratum", DB.Object<{
|
|
140
165
|
date: DB.MemberDecl<DB.Date, true>;
|
|
141
166
|
description: DB.MemberDecl<DB.String, true>;
|
|
@@ -28,6 +28,10 @@ export const Book = DB.Entity(import.meta.url, {
|
|
|
28
28
|
comment: "The structure points of the item. Use an array if the item consists of multiple components that have individual structure points.",
|
|
29
29
|
type: DB.IncludeIdentifier(StructurePoints),
|
|
30
30
|
}),
|
|
31
|
+
contentQuality: DB.Optional({
|
|
32
|
+
comment: "The quality of the book’s content.",
|
|
33
|
+
type: DB.IncludeIdentifier(BookContentQuality),
|
|
34
|
+
}),
|
|
31
35
|
src,
|
|
32
36
|
translations: NestedTranslationMap(DB.Required, "Book", DB.Object({
|
|
33
37
|
name: DB.Required({
|
|
@@ -52,6 +56,18 @@ export const Book = DB.Entity(import.meta.url, {
|
|
|
52
56
|
}),
|
|
53
57
|
rules: DB.Optional({
|
|
54
58
|
comment: "Special rules text.",
|
|
59
|
+
type: DB.IncludeIdentifier(BookRules),
|
|
60
|
+
}),
|
|
61
|
+
legality: DB.Optional({
|
|
62
|
+
comment: "The legality of the item, if specified.",
|
|
63
|
+
type: DB.String({ minLength: 1, markdown: "inline" }),
|
|
64
|
+
}),
|
|
65
|
+
availability: DB.Optional({
|
|
66
|
+
comment: "The availability of the item, if specified.",
|
|
67
|
+
type: DB.String({ minLength: 1, markdown: "inline" }),
|
|
68
|
+
}),
|
|
69
|
+
special: DB.Optional({
|
|
70
|
+
comment: "Special properties or features of the item.",
|
|
55
71
|
type: DB.String({ minLength: 1, markdown: "block" }),
|
|
56
72
|
}),
|
|
57
73
|
errata: DB.Optional({
|
|
@@ -179,3 +195,77 @@ const IndefiniteBookCostVariant = DB.TypeAlias(import.meta.url, {
|
|
|
179
195
|
})),
|
|
180
196
|
}),
|
|
181
197
|
});
|
|
198
|
+
const BookContentQuality = DB.Enum(import.meta.url, {
|
|
199
|
+
name: "BookContentQuality",
|
|
200
|
+
comment: "The quality of the book’s content.",
|
|
201
|
+
values: () => ({
|
|
202
|
+
Modest: DB.EnumCase({ type: null }),
|
|
203
|
+
Average: DB.EnumCase({ type: null }),
|
|
204
|
+
Demanding: DB.EnumCase({ type: DB.Integer({ minimum: 1, maximum: 3 }) }),
|
|
205
|
+
}),
|
|
206
|
+
});
|
|
207
|
+
const BookRules = DB.Enum(import.meta.url, {
|
|
208
|
+
name: "BookRules",
|
|
209
|
+
comment: "Skills and abilities you can learn by reading the book, as well as any other rules and effects concerning the book.",
|
|
210
|
+
values: () => ({
|
|
211
|
+
Plain: DB.EnumCase({ type: DB.IncludeIdentifier(PlainBookRules) }),
|
|
212
|
+
Entertainment: DB.EnumCase({ type: null }),
|
|
213
|
+
ByEdition: DB.EnumCase({ type: DB.IncludeIdentifier(BookRulesByEdition) }),
|
|
214
|
+
}),
|
|
215
|
+
});
|
|
216
|
+
const PlainBookRules = DB.TypeAlias(import.meta.url, {
|
|
217
|
+
name: "PlainBookRules",
|
|
218
|
+
comment: "The book’s rules without any special effects or conditions.",
|
|
219
|
+
type: () => DB.Object({
|
|
220
|
+
text: DB.Required({
|
|
221
|
+
comment: "The (main) rules text.",
|
|
222
|
+
type: DB.String({ minLength: 1, markdown: "block" }),
|
|
223
|
+
}),
|
|
224
|
+
reconstruction: DB.Optional({
|
|
225
|
+
comment: "Rules for reconstructing certain skills or abilities from the book.",
|
|
226
|
+
type: DB.String({ minLength: 1, markdown: "block" }),
|
|
227
|
+
}),
|
|
228
|
+
references: DB.Optional({
|
|
229
|
+
comment: "References to skills and abilities that, while mentioned in the book, cannot be learned from this book alone.",
|
|
230
|
+
type: DB.String({ minLength: 1, markdown: "block" }),
|
|
231
|
+
}),
|
|
232
|
+
textAfter: DB.Optional({
|
|
233
|
+
comment: "Additional rules text that comes after all other rules.",
|
|
234
|
+
type: DB.String({ minLength: 1, markdown: "block" }),
|
|
235
|
+
}),
|
|
236
|
+
}),
|
|
237
|
+
});
|
|
238
|
+
const BookRulesByEdition = DB.TypeAlias(import.meta.url, {
|
|
239
|
+
name: "BookRulesByEdition",
|
|
240
|
+
comment: "The book’s rules with differences between each edition and more differentiation between types of rules.",
|
|
241
|
+
type: () => DB.Object({
|
|
242
|
+
editions: DB.Required({
|
|
243
|
+
type: DB.Array(DB.IncludeIdentifier(BookRulesOfEdition), { minItems: 1 }),
|
|
244
|
+
}),
|
|
245
|
+
textAfter: DB.Optional({
|
|
246
|
+
comment: "Additional rules text that comes after all other rules.",
|
|
247
|
+
type: DB.String({ minLength: 1, markdown: "block" }),
|
|
248
|
+
}),
|
|
249
|
+
}),
|
|
250
|
+
});
|
|
251
|
+
const BookRulesOfEdition = DB.TypeAlias(import.meta.url, {
|
|
252
|
+
name: "BookRulesOfEdition",
|
|
253
|
+
type: () => DB.Object({
|
|
254
|
+
label: DB.Required({
|
|
255
|
+
comment: "The edition(s) the rules apply to.",
|
|
256
|
+
type: DB.String({ minLength: 1 }),
|
|
257
|
+
}),
|
|
258
|
+
text: DB.Required({
|
|
259
|
+
comment: "The rules text.",
|
|
260
|
+
type: DB.String({ minLength: 1, markdown: "block" }),
|
|
261
|
+
}),
|
|
262
|
+
reconstruction: DB.Optional({
|
|
263
|
+
comment: "Rules for reconstructing certain skills or abilities from the book.",
|
|
264
|
+
type: DB.String({ minLength: 1, markdown: "block" }),
|
|
265
|
+
}),
|
|
266
|
+
references: DB.Optional({
|
|
267
|
+
comment: "References to skills and abilities that, while mentioned in the book, cannot be learned from this book alone.",
|
|
268
|
+
type: DB.String({ minLength: 1, markdown: "block" }),
|
|
269
|
+
}),
|
|
270
|
+
}),
|
|
271
|
+
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "optolith-database-schema",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.38.0",
|
|
4
4
|
"description": "Definitions and utilities for the flat-file database of Optolith, a character creation tool for the Pen and Paper RPG “The Dark Eye 5”, and its external integrations into other software.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"tde",
|