optolith-database-schema 0.1.27 → 0.2.1

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.
@@ -0,0 +1,34 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema",
3
+ "$id": "/_Dice.schema.json",
4
+ "definitions": {
5
+ "Dice": {
6
+ "title": "Dice",
7
+ "type": "object",
8
+ "properties": {
9
+ "number": {
10
+ "description": "Number of dice of the same type. Example: 2 in 2D6.",
11
+ "type": "integer",
12
+ "minimum": 1
13
+ },
14
+ "sides": {
15
+ "description": "Number of sides on every die. Example: 6 in 2D6.",
16
+ "$ref": "#/definitions/DieType"
17
+ }
18
+ },
19
+ "required": [
20
+ "number",
21
+ "sides"
22
+ ],
23
+ "additionalProperties": false
24
+ },
25
+ "DieType": {
26
+ "description": "Number of sides on every dice. Example: 6 in 2D6.",
27
+ "enum": [
28
+ 3,
29
+ 6,
30
+ 20
31
+ ]
32
+ }
33
+ }
34
+ }
@@ -120,9 +120,19 @@
120
120
  "Ceremony"
121
121
  ]
122
122
  },
123
+ "SkillTag": {
124
+ "enum": [
125
+ "Skill",
126
+ "Spell",
127
+ "Ritual",
128
+ "LiturgicalChant",
129
+ "Ceremony"
130
+ ]
131
+ },
123
132
  "AdvancedSpecialAbilityRestrictedOptionTag": {
124
133
  "enum": [
125
134
  "General",
135
+ "Skill",
126
136
  "Element"
127
137
  ]
128
138
  },
@@ -277,6 +287,24 @@
277
287
  ],
278
288
  "additionalProperties": false
279
289
  },
290
+ "SkillIdentifier": {
291
+ "type": "object",
292
+ "properties": {
293
+ "tag": {
294
+ "$ref": "#/definitions/SkillTag"
295
+ },
296
+ "value": {
297
+ "description": "The referenced entry's numeric identifier.",
298
+ "type": "integer",
299
+ "minimum": 1
300
+ }
301
+ },
302
+ "required": [
303
+ "tag",
304
+ "value"
305
+ ],
306
+ "additionalProperties": false
307
+ },
280
308
  "AdvancedSpecialAbilityRestrictedOptionIdentifier": {
281
309
  "type": "object",
282
310
  "properties": {
@@ -0,0 +1,621 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema",
3
+ "$id": "/equipment/Item.schema.json",
4
+ "$ref": "#/definitions/Item",
5
+ "definitions": {
6
+ "Item": {
7
+ "title": "Item",
8
+ "type": "object",
9
+ "properties": {
10
+ "id": {
11
+ "description": "The item's identifier. An unique, increasing integer.",
12
+ "type": "integer",
13
+ "minimum": 1
14
+ },
15
+ "cost": {
16
+ "description": "The cost in silverthalers.",
17
+ "$ref": "#/definitions/Cost"
18
+ },
19
+ "weight": {
20
+ "description": "The weight in kg.",
21
+ "$ref": "#/definitions/Weight"
22
+ },
23
+ "complexity": {
24
+ "description": "The complexity of crafting the item.",
25
+ "$ref": "#/definitions/Complexity"
26
+ },
27
+ "type": {
28
+ "oneOf": [
29
+ {
30
+ "type": "object",
31
+ "properties": {
32
+ "tag": {
33
+ "const": "Weapon"
34
+ },
35
+ "uses": {
36
+ "type": "array",
37
+ "items": {
38
+ "oneOf": [
39
+ {
40
+ "$ref": "./_Weapon.schema.json#/definitions/MeleeWeapon"
41
+ },
42
+ {
43
+ "$ref": "./_Weapon.schema.json#/definitions/RangedWeapon"
44
+ }
45
+ ]
46
+ },
47
+ "minItems": 1
48
+ },
49
+ "sanctified_by": {
50
+ "$ref": "./_Weapon.schema.json#/definitions/SanctifiedBy"
51
+ },
52
+ "restricted_to_cultures": {
53
+ "$ref": "./_Weapon.schema.json#/definitions/RestrictedToCultures"
54
+ },
55
+ "secondary": {
56
+ "type": "object",
57
+ "properties": {
58
+ "type": {
59
+ "$ref": "#/definitions/Type"
60
+ },
61
+ "structure_points": {
62
+ "$ref": "./_Weapon.schema.json#/definitions/StructurePoints"
63
+ }
64
+ },
65
+ "required": [
66
+ "type",
67
+ "structure_points"
68
+ ],
69
+ "additionalProperties": false
70
+ },
71
+ "translations": {
72
+ "description": "All translations for the entry, identified by IETF language tag\n(BCP47).",
73
+ "type": "object",
74
+ "patternProperties": {
75
+ "^[a-z]{2}-[A-Z]{2}$": {
76
+ "type": "object",
77
+ "properties": {
78
+ "name": {
79
+ "$ref": "#/definitions/Name"
80
+ },
81
+ "secondary_name": {
82
+ "$ref": "#/definitions/SecondaryName"
83
+ },
84
+ "note": {
85
+ "$ref": "#/definitions/Note"
86
+ },
87
+ "rules": {
88
+ "$ref": "#/definitions/Rules"
89
+ },
90
+ "advantage": {
91
+ "$ref": "#/definitions/Advantage"
92
+ },
93
+ "disadvantage": {
94
+ "$ref": "#/definitions/Disadvantage"
95
+ },
96
+ "errata": {
97
+ "$ref": "../source/_Erratum.schema.json#/definitions/Errata"
98
+ }
99
+ },
100
+ "required": [
101
+ "name"
102
+ ],
103
+ "additionalProperties": false
104
+ }
105
+ },
106
+ "minProperties": 1,
107
+ "additionalProperties": false
108
+ }
109
+ },
110
+ "required": [
111
+ "tag",
112
+ "uses",
113
+ "translations"
114
+ ],
115
+ "additionalProperties": false
116
+ },
117
+ {
118
+ "type": "object",
119
+ "properties": {
120
+ "tag": {
121
+ "const": "Armor"
122
+ },
123
+ "protection": {
124
+ "$ref": "./_Armor.schema.json#/definitions/Protection"
125
+ },
126
+ "encumbrance": {
127
+ "$ref": "./_Armor.schema.json#/definitions/Encumbrance"
128
+ },
129
+ "has_additional_penalties": {
130
+ "$ref": "./_Armor.schema.json#/definitions/HasAdditionalPenalties"
131
+ },
132
+ "armor_type": {
133
+ "$ref": "./_Armor.schema.json#/definitions/ArmorType"
134
+ },
135
+ "hit_zone": {
136
+ "$ref": "./_Armor.schema.json#/definitions/HitZone"
137
+ },
138
+ "secondary": {
139
+ "type": "object",
140
+ "properties": {
141
+ "type": {
142
+ "$ref": "#/definitions/Type"
143
+ },
144
+ "structure_points": {
145
+ "$ref": "./_Weapon.schema.json#/definitions/StructurePoints"
146
+ }
147
+ },
148
+ "required": [
149
+ "type",
150
+ "structure_points"
151
+ ],
152
+ "additionalProperties": false
153
+ },
154
+ "translations": {
155
+ "description": "All translations for the entry, identified by IETF language tag\n(BCP47).",
156
+ "type": "object",
157
+ "patternProperties": {
158
+ "^[a-z]{2}-[A-Z]{2}$": {
159
+ "type": "object",
160
+ "properties": {
161
+ "name": {
162
+ "$ref": "#/definitions/Name"
163
+ },
164
+ "secondary_name": {
165
+ "$ref": "#/definitions/SecondaryName"
166
+ },
167
+ "note": {
168
+ "$ref": "#/definitions/Note"
169
+ },
170
+ "rules": {
171
+ "$ref": "#/definitions/Rules"
172
+ },
173
+ "advantage": {
174
+ "$ref": "#/definitions/Advantage"
175
+ },
176
+ "disadvantage": {
177
+ "$ref": "#/definitions/Disadvantage"
178
+ },
179
+ "errata": {
180
+ "$ref": "../source/_Erratum.schema.json#/definitions/Errata"
181
+ }
182
+ },
183
+ "required": [
184
+ "name"
185
+ ],
186
+ "additionalProperties": false
187
+ }
188
+ },
189
+ "minProperties": 1,
190
+ "additionalProperties": false
191
+ }
192
+ },
193
+ "required": [
194
+ "tag",
195
+ "protection",
196
+ "encumbrance",
197
+ "has_additional_penalties",
198
+ "armor_type",
199
+ "translations"
200
+ ],
201
+ "additionalProperties": false
202
+ },
203
+ {
204
+ "type": "object",
205
+ "properties": {
206
+ "tag": {
207
+ "const": "Default"
208
+ },
209
+ "type": {
210
+ "$ref": "#/definitions/Type"
211
+ },
212
+ "combat_uses": {
213
+ "oneOf": [
214
+ {
215
+ "type": "object",
216
+ "properties": {
217
+ "tag": {
218
+ "const": "ImprovisedWeapon"
219
+ },
220
+ "uses": {
221
+ "type": "array",
222
+ "items": {
223
+ "oneOf": [
224
+ {
225
+ "$ref": "./_Weapon.schema.json#/definitions/MeleeWeapon"
226
+ },
227
+ {
228
+ "$ref": "./_Weapon.schema.json#/definitions/RangedWeapon"
229
+ }
230
+ ]
231
+ },
232
+ "minItems": 1
233
+ },
234
+ "sanctified_by": {
235
+ "$ref": "./_Weapon.schema.json#/definitions/SanctifiedBy"
236
+ },
237
+ "restricted_to_cultures": {
238
+ "$ref": "./_Weapon.schema.json#/definitions/RestrictedToCultures"
239
+ },
240
+ "translations": {
241
+ "description": "All translations for the entry, identified by IETF language tag\n(BCP47).",
242
+ "type": "object",
243
+ "patternProperties": {
244
+ "^[a-z]{2}-[A-Z]{2}$": {
245
+ "type": "object",
246
+ "properties": {
247
+ "advantage": {
248
+ "$ref": "#/definitions/Advantage"
249
+ },
250
+ "disadvantage": {
251
+ "$ref": "#/definitions/Disadvantage"
252
+ }
253
+ },
254
+ "required": [
255
+ "advantage",
256
+ "disadvantage"
257
+ ],
258
+ "additionalProperties": false
259
+ }
260
+ },
261
+ "minProperties": 1,
262
+ "additionalProperties": false
263
+ }
264
+ },
265
+ "required": [
266
+ "tag",
267
+ "uses",
268
+ "translations"
269
+ ],
270
+ "additionalProperties": false
271
+ },
272
+ {
273
+ "type": "object",
274
+ "properties": {
275
+ "tag": {
276
+ "const": "Armor"
277
+ },
278
+ "protection": {
279
+ "$ref": "./_Armor.schema.json#/definitions/Protection"
280
+ },
281
+ "encumbrance": {
282
+ "$ref": "./_Armor.schema.json#/definitions/Encumbrance"
283
+ },
284
+ "has_additional_penalties": {
285
+ "$ref": "./_Armor.schema.json#/definitions/HasAdditionalPenalties"
286
+ },
287
+ "armor_type": {
288
+ "$ref": "./_Armor.schema.json#/definitions/ArmorType"
289
+ },
290
+ "hit_zone": {
291
+ "$ref": "./_Armor.schema.json#/definitions/HitZone"
292
+ },
293
+ "translations": {
294
+ "description": "All translations for the entry, identified by IETF language tag\n(BCP47).",
295
+ "type": "object",
296
+ "patternProperties": {
297
+ "^[a-z]{2}-[A-Z]{2}$": {
298
+ "type": "object",
299
+ "properties": {
300
+ "advantage": {
301
+ "$ref": "#/definitions/Advantage"
302
+ },
303
+ "disadvantage": {
304
+ "$ref": "#/definitions/Disadvantage"
305
+ }
306
+ },
307
+ "required": [
308
+ "advantage",
309
+ "disadvantage"
310
+ ],
311
+ "additionalProperties": false
312
+ }
313
+ },
314
+ "minProperties": 1,
315
+ "additionalProperties": false
316
+ }
317
+ },
318
+ "required": [
319
+ "tag",
320
+ "protection",
321
+ "encumbrance",
322
+ "has_additional_penalties",
323
+ "armor_type",
324
+ "translations"
325
+ ],
326
+ "additionalProperties": false
327
+ }
328
+ ]
329
+ },
330
+ "structure_points": {
331
+ "$ref": "./_Weapon.schema.json#/definitions/StructurePoints"
332
+ },
333
+ "translations": {
334
+ "description": "All translations for the entry, identified by IETF language tag\n(BCP47).",
335
+ "type": "object",
336
+ "patternProperties": {
337
+ "^[a-z]{2}-[A-Z]{2}$": {
338
+ "type": "object",
339
+ "properties": {
340
+ "name": {
341
+ "$ref": "#/definitions/Name"
342
+ },
343
+ "secondary_name": {
344
+ "$ref": "#/definitions/SecondaryName"
345
+ },
346
+ "note": {
347
+ "$ref": "#/definitions/Note"
348
+ },
349
+ "rules": {
350
+ "$ref": "#/definitions/Rules"
351
+ },
352
+ "errata": {
353
+ "$ref": "../source/_Erratum.schema.json#/definitions/Errata"
354
+ }
355
+ },
356
+ "required": [
357
+ "name"
358
+ ],
359
+ "additionalProperties": false
360
+ }
361
+ },
362
+ "minProperties": 1,
363
+ "additionalProperties": false
364
+ }
365
+ },
366
+ "required": [
367
+ "tag",
368
+ "type",
369
+ "combat_uses",
370
+ "structure_points",
371
+ "translations"
372
+ ],
373
+ "additionalProperties": false
374
+ }
375
+ ]
376
+ },
377
+ "src": {
378
+ "$ref": "../source/_PublicationRef.schema.json#/definitions/PublicationRefs"
379
+ }
380
+ },
381
+ "required": [
382
+ "id",
383
+ "cost",
384
+ "complexity",
385
+ "type",
386
+ "src"
387
+ ],
388
+ "additionalProperties": false
389
+ },
390
+ "Name": {
391
+ "description": "The name of the item.",
392
+ "type": "string",
393
+ "minLength": 1
394
+ },
395
+ "SecondaryName": {
396
+ "description": "An auxiliary name or label of the item, if available.",
397
+ "type": "string",
398
+ "minLength": 1
399
+ },
400
+ "Cost": {
401
+ "description": "The cost in silverthalers.",
402
+ "oneOf": [
403
+ {
404
+ "type": "object",
405
+ "properties": {
406
+ "tag": {
407
+ "const": "Free"
408
+ }
409
+ },
410
+ "required": [
411
+ "tag"
412
+ ],
413
+ "additionalProperties": false
414
+ },
415
+ {
416
+ "type": "object",
417
+ "properties": {
418
+ "tag": {
419
+ "const": "Various"
420
+ }
421
+ },
422
+ "required": [
423
+ "tag"
424
+ ],
425
+ "additionalProperties": false
426
+ },
427
+ {
428
+ "type": "object",
429
+ "properties": {
430
+ "tag": {
431
+ "const": "Fixed"
432
+ },
433
+ "value": {
434
+ "description": "The cost in silverthalers.",
435
+ "type": "number",
436
+ "exclusiveMinimum": 0
437
+ },
438
+ "translations": {
439
+ "description": "All translations for the entry, identified by IETF language tag\n(BCP47).",
440
+ "type": "object",
441
+ "patternProperties": {
442
+ "^[a-z]{2}-[A-Z]{2}$": {
443
+ "type": "object",
444
+ "properties": {
445
+ "wrap_in_text": {
446
+ "description": "The cost get wrapped by this text using a placeholder in the text.",
447
+ "type": "string",
448
+ "minLength": 1,
449
+ "pattern": "\\\\{0\\\\}"
450
+ }
451
+ },
452
+ "required": [
453
+ "wrap_in_text"
454
+ ],
455
+ "additionalProperties": false
456
+ }
457
+ },
458
+ "minProperties": 1,
459
+ "additionalProperties": false
460
+ }
461
+ },
462
+ "required": [
463
+ "tag",
464
+ "value"
465
+ ],
466
+ "additionalProperties": false
467
+ },
468
+ {
469
+ "type": "object",
470
+ "properties": {
471
+ "tag": {
472
+ "const": "Range"
473
+ },
474
+ "from": {
475
+ "description": "The lower bound of the cost in silverthalers.",
476
+ "type": "number",
477
+ "exclusiveMinimum": 0
478
+ },
479
+ "to": {
480
+ "description": "The upper bound of the cost in silverthalers.",
481
+ "type": "number",
482
+ "exclusiveMinimum": 0
483
+ },
484
+ "translations": {
485
+ "description": "All translations for the entry, identified by IETF language tag\n(BCP47).",
486
+ "type": "object",
487
+ "patternProperties": {
488
+ "^[a-z]{2}-[A-Z]{2}$": {
489
+ "type": "object",
490
+ "properties": {
491
+ "wrap_in_text": {
492
+ "description": "The cost range gets wrapped by this text using a placeholder in the\ntext.",
493
+ "type": "string",
494
+ "minLength": 1,
495
+ "pattern": "\\\\{0\\\\}"
496
+ }
497
+ },
498
+ "required": [
499
+ "wrap_in_text"
500
+ ],
501
+ "additionalProperties": false
502
+ }
503
+ },
504
+ "minProperties": 1,
505
+ "additionalProperties": false
506
+ }
507
+ },
508
+ "required": [
509
+ "tag",
510
+ "from",
511
+ "to"
512
+ ],
513
+ "additionalProperties": false
514
+ }
515
+ ]
516
+ },
517
+ "Weight": {
518
+ "description": "The weight in kg.",
519
+ "type": "number",
520
+ "exclusiveMinimum": 0
521
+ },
522
+ "Complexity": {
523
+ "description": "The complexity of crafting the item.",
524
+ "oneOf": [
525
+ {
526
+ "type": "object",
527
+ "properties": {
528
+ "tag": {
529
+ "const": "Primitive"
530
+ }
531
+ },
532
+ "required": [
533
+ "tag"
534
+ ],
535
+ "additionalProperties": false
536
+ },
537
+ {
538
+ "type": "object",
539
+ "properties": {
540
+ "tag": {
541
+ "const": "Simple"
542
+ }
543
+ },
544
+ "required": [
545
+ "tag"
546
+ ],
547
+ "additionalProperties": false
548
+ },
549
+ {
550
+ "type": "object",
551
+ "properties": {
552
+ "tag": {
553
+ "const": "Complex"
554
+ },
555
+ "ap_value": {
556
+ "description": "The AP value for the trade secret.",
557
+ "type": "integer",
558
+ "minimum": 1
559
+ }
560
+ },
561
+ "required": [
562
+ "tag",
563
+ "ap_value"
564
+ ],
565
+ "additionalProperties": false
566
+ }
567
+ ]
568
+ },
569
+ "Type": {
570
+ "enum": [
571
+ "Ammunition",
572
+ "WeaponAccessories",
573
+ "Clothes",
574
+ "TravelGearAndTools",
575
+ "Illumination",
576
+ "BandagesAndRemedies",
577
+ "Containers",
578
+ "RopesAndChains",
579
+ "ThievesTools",
580
+ "ToolsOfTheTrade",
581
+ "OrienteeringAids",
582
+ "Jewelry",
583
+ "GemsAndPreciousStones",
584
+ "Stationary",
585
+ "Books",
586
+ "MagicalArtifacts",
587
+ "Alchemicae",
588
+ "Poisons",
589
+ "HealingHerbs",
590
+ "MusicalInstruments",
591
+ "LuxuryGoods",
592
+ "Animals",
593
+ "AnimalCare",
594
+ "Vehicles",
595
+ "AusruestungDerGeweihtenschaft",
596
+ "CeremonialItems",
597
+ "Liebesspielzeug"
598
+ ]
599
+ },
600
+ "Note": {
601
+ "description": "Note text.",
602
+ "type": "string",
603
+ "minLength": 1
604
+ },
605
+ "Rules": {
606
+ "description": "Special rules text.",
607
+ "type": "string",
608
+ "minLength": 1
609
+ },
610
+ "Advantage": {
611
+ "description": "The weapon/armor advantage text.",
612
+ "type": "string",
613
+ "minLength": 1
614
+ },
615
+ "Disadvantage": {
616
+ "description": "The weapon/armor disadvantage text.",
617
+ "type": "string",
618
+ "minLength": 1
619
+ }
620
+ }
621
+ }