5etools-utils 0.10.2 → 0.10.4

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "5etools-utils",
3
- "version": "0.10.2",
3
+ "version": "0.10.4",
4
4
  "description": "Shared utilities for the 5etools ecosystem.",
5
5
  "type": "module",
6
6
  "main": "lib/Api.js",
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "$id": "feats.json",
4
- "version": "1.6.3",
4
+ "version": "1.6.4",
5
5
  "type": "object",
6
6
  "$defs": {
7
- "feat": {
7
+ "featData": {
8
8
  "type": "object",
9
9
  "properties": {
10
10
  "name": {
@@ -115,15 +115,254 @@
115
115
  "$ref": "util-foundry.json#/$defs/foundryImg"
116
116
  }
117
117
  },
118
- "required": [
119
- "name",
120
- "source",
121
- "entries"
122
- ],
123
118
  "additionalProperties": false
119
+ },
120
+ "feat": {
121
+ "anyOf": [
122
+ {
123
+ "type": "object",
124
+ "properties": {
125
+ "name": {
126
+ "type": "string"
127
+ },
128
+ "prerequisite": {
129
+ "$ref": "util.json#/$defs/prerequisite"
130
+ },
131
+ "source": {
132
+ "$ref": "util.json#/$defs/source"
133
+ },
134
+ "additionalSources": {
135
+ "$ref": "util.json#/$defs/additionalSources"
136
+ },
137
+ "page": {
138
+ "$ref": "util.json#/$defs/page"
139
+ },
140
+ "entries": {
141
+ "type": "array",
142
+ "items": {
143
+ "$ref": "entry.json"
144
+ }
145
+ },
146
+ "ability": {
147
+ "$ref": "util.json#/$defs/abilityScores"
148
+ },
149
+ "srd": {
150
+ "$ref": "util.json#/$defs/srd"
151
+ },
152
+ "otherSources": {
153
+ "$ref": "util.json#/$defs/otherSources"
154
+ },
155
+ "repeatable": {
156
+ "type": "boolean"
157
+ },
158
+ "repeatableNote": {
159
+ "type": "string"
160
+ },
161
+ "category": {
162
+ "type": "string",
163
+ "examples": [
164
+ "general",
165
+ "background"
166
+ ]
167
+ },
168
+ "additionalSpells": {
169
+ "$ref": "util.json#/$defs/additionalSpellsArray"
170
+ },
171
+ "languageProficiencies": {
172
+ "$ref": "util.json#/$defs/languageProficiencies"
173
+ },
174
+ "skillProficiencies": {
175
+ "$ref": "util.json#/$defs/skillProficiencies"
176
+ },
177
+ "weaponProficiencies": {
178
+ "$ref": "util.json#/$defs/weaponProficiencies"
179
+ },
180
+ "armorProficiencies": {
181
+ "$ref": "util.json#/$defs/armorProficiencies"
182
+ },
183
+ "toolProficiencies": {
184
+ "$ref": "util.json#/$defs/toolProficiencies"
185
+ },
186
+ "skillToolLanguageProficiencies": {
187
+ "$ref": "util.json#/$defs/skillToolLanguageProficiencies"
188
+ },
189
+ "savingThrowProficiencies": {
190
+ "$ref": "util.json#/$defs/savingThrowProficiencies"
191
+ },
192
+ "optionalfeatureProgression": {
193
+ "$ref": "util.json#/$defs/optionalfeatureProgression"
194
+ },
195
+ "expertise": {
196
+ "$ref": "util.json#/$defs/expertise"
197
+ },
198
+ "resist": {
199
+ "$ref": "util.json#/$defs/damageResistArrayPlayer"
200
+ },
201
+ "immune": {
202
+ "$ref": "util.json#/$defs/damageImmunityArrayPlayer"
203
+ },
204
+ "vulnerable": {
205
+ "$ref": "util.json#/$defs/damageVulnerabilityArrayPlayer"
206
+ },
207
+ "conditionImmune": {
208
+ "$ref": "util.json#/$defs/conditionImmunityArrayPlayer"
209
+ },
210
+ "hasFluff": {
211
+ "const": true
212
+ },
213
+ "hasFluffImages": {
214
+ "const": true
215
+ },
216
+ "fluff": {
217
+ "description": "This is intended to be used for Homebrew only - site data should include a fluff file per source",
218
+ "$ref": "util.json#/$defs/fluffObject"
219
+ },
220
+ "foundrySystem": {
221
+ "$ref": "util-foundry.json#/$defs/foundrySystemObject"
222
+ },
223
+ "foundryFlags": {
224
+ "$ref": "util-foundry.json#/$defs/foundryFlagsObject"
225
+ },
226
+ "foundryEffects": {
227
+ "$ref": "util-foundry.json#/$defs/foundryEffectsArray"
228
+ },
229
+ "foundryImg": {
230
+ "$ref": "util-foundry.json#/$defs/foundryImg"
231
+ }
232
+ },
233
+ "additionalProperties": false,
234
+ "required": [
235
+ "name",
236
+ "source",
237
+ "entries"
238
+ ]
239
+ },
240
+ {
241
+ "type": "object",
242
+ "properties": {
243
+ "name": {
244
+ "type": "string"
245
+ },
246
+ "prerequisite": {
247
+ "$ref": "util.json#/$defs/prerequisite"
248
+ },
249
+ "source": {
250
+ "$ref": "util.json#/$defs/source"
251
+ },
252
+ "additionalSources": {
253
+ "$ref": "util.json#/$defs/additionalSources"
254
+ },
255
+ "page": {
256
+ "$ref": "util.json#/$defs/page"
257
+ },
258
+ "entries": {
259
+ "type": "array",
260
+ "items": {
261
+ "$ref": "entry.json"
262
+ }
263
+ },
264
+ "ability": {
265
+ "$ref": "util.json#/$defs/abilityScores"
266
+ },
267
+ "srd": {
268
+ "$ref": "util.json#/$defs/srd"
269
+ },
270
+ "otherSources": {
271
+ "$ref": "util.json#/$defs/otherSources"
272
+ },
273
+ "repeatable": {
274
+ "type": "boolean"
275
+ },
276
+ "repeatableNote": {
277
+ "type": "string"
278
+ },
279
+ "category": {
280
+ "type": "string",
281
+ "examples": [
282
+ "general",
283
+ "background"
284
+ ]
285
+ },
286
+ "additionalSpells": {
287
+ "$ref": "util.json#/$defs/additionalSpellsArray"
288
+ },
289
+ "languageProficiencies": {
290
+ "$ref": "util.json#/$defs/languageProficiencies"
291
+ },
292
+ "skillProficiencies": {
293
+ "$ref": "util.json#/$defs/skillProficiencies"
294
+ },
295
+ "weaponProficiencies": {
296
+ "$ref": "util.json#/$defs/weaponProficiencies"
297
+ },
298
+ "armorProficiencies": {
299
+ "$ref": "util.json#/$defs/armorProficiencies"
300
+ },
301
+ "toolProficiencies": {
302
+ "$ref": "util.json#/$defs/toolProficiencies"
303
+ },
304
+ "skillToolLanguageProficiencies": {
305
+ "$ref": "util.json#/$defs/skillToolLanguageProficiencies"
306
+ },
307
+ "savingThrowProficiencies": {
308
+ "$ref": "util.json#/$defs/savingThrowProficiencies"
309
+ },
310
+ "optionalfeatureProgression": {
311
+ "$ref": "util.json#/$defs/optionalfeatureProgression"
312
+ },
313
+ "expertise": {
314
+ "$ref": "util.json#/$defs/expertise"
315
+ },
316
+ "resist": {
317
+ "$ref": "util.json#/$defs/damageResistArrayPlayer"
318
+ },
319
+ "immune": {
320
+ "$ref": "util.json#/$defs/damageImmunityArrayPlayer"
321
+ },
322
+ "vulnerable": {
323
+ "$ref": "util.json#/$defs/damageVulnerabilityArrayPlayer"
324
+ },
325
+ "conditionImmune": {
326
+ "$ref": "util.json#/$defs/conditionImmunityArrayPlayer"
327
+ },
328
+ "hasFluff": {
329
+ "const": true
330
+ },
331
+ "hasFluffImages": {
332
+ "const": true
333
+ },
334
+ "fluff": {
335
+ "description": "This is intended to be used for Homebrew only - site data should include a fluff file per source",
336
+ "$ref": "util.json#/$defs/fluffObject"
337
+ },
338
+ "foundrySystem": {
339
+ "$ref": "util-foundry.json#/$defs/foundrySystemObject"
340
+ },
341
+ "foundryFlags": {
342
+ "$ref": "util-foundry.json#/$defs/foundryFlagsObject"
343
+ },
344
+ "foundryEffects": {
345
+ "$ref": "util-foundry.json#/$defs/foundryEffectsArray"
346
+ },
347
+ "foundryImg": {
348
+ "$ref": "util-foundry.json#/$defs/foundryImg"
349
+ },
350
+ "_copy": {
351
+ "$ref": "util.json#/$defs/copyBlock_copy_generic"
352
+ }
353
+ },
354
+ "additionalProperties": false,
355
+ "required": [
356
+ "_copy"
357
+ ]
358
+ }
359
+ ]
124
360
  }
125
361
  },
126
362
  "properties": {
363
+ "_meta": {
364
+ "$ref": "util.json#/$defs/metaBlock"
365
+ },
127
366
  "feat": {
128
367
  "type": "array",
129
368
  "minItems": 1,
@@ -1130,20 +1130,26 @@
1130
1130
  "_mod": {
1131
1131
  "$ref": "util.json#/$defs/_modObject"
1132
1132
  },
1133
- "_trait": {
1134
- "type": "object",
1135
- "properties": {
1136
- "name": {
1137
- "type": "string"
1133
+ "_templates": {
1134
+ "type": "array",
1135
+ "items": {
1136
+ "type": "object",
1137
+ "properties": {
1138
+ "name": {
1139
+ "type": "string"
1140
+ },
1141
+ "source": {
1142
+ "$ref": "util.json#/$defs/source"
1143
+ }
1138
1144
  },
1139
- "source": {
1140
- "$ref": "util.json#/$defs/source"
1141
- }
1145
+ "required": [
1146
+ "name",
1147
+ "source"
1148
+ ],
1149
+ "additionalProperties": false
1142
1150
  },
1143
- "required": [
1144
- "name",
1145
- "source"
1146
- ]
1151
+ "minItems": 1,
1152
+ "uniqueItems": true
1147
1153
  },
1148
1154
  "_preserve": {
1149
1155
  "type": "object",
@@ -3,7 +3,7 @@
3
3
  "$id": "items-shared.json",
4
4
  "title": "Shared Item Schema",
5
5
  "description": "Shared item definitions to be used in item schemas.",
6
- "version": "1.0.6",
6
+ "version": "1.0.7",
7
7
  "$defs": {
8
8
  "_itemModifySpeedEqual": {
9
9
  "type": "string",
@@ -156,9 +156,12 @@
156
156
  "itemType": {
157
157
  "type": "string",
158
158
  "$comment": "Dumped from `Object(Parser.ITEM_TYPE_JSON_TO_ABV)`",
159
- "description": "$: Treasure\n A: Ammunition\n AF: Ammunition (futuristic)\n AIR: Vehicle (air)\n AT: Artisan Tool\n EM: Eldritch Machine\n EXP: Explosive\n FD: Food and Drink\n G: Adventuring Gear\n GS: Gaming Set\n GV: Generic Variant\n HA: Heavy Armor\n IDG: Illegal Drug\n INS: Instrument\n LA: Light Armor\n M: Melee Weapon\n MA: Medium Armor\n MNT: Mount\n MR: Master Rune \n OTH: Other\n P: Potion\n R: Ranged Weapon\n RD: Rod\n RG: Ring\n S: Shield\n SC: Scroll\n SCF: Spellcasting Focus\n SHP: Vehicle (water)\n SPC: Vehicle (space)\n T: Tool\n TAH: Tack and Harness\n TG: Trade Good\n VEH: Vehicle (land)\n WD: Wand",
159
+ "description": "$: Treasure\n $A: Treasure (Art Object)\n $A: Treasure (Coinage)\n $G: Treasure (Gemstone)\n A: Ammunition\n AF: Ammunition (futuristic)\n AIR: Vehicle (air)\n AT: Artisan Tool\n EM: Eldritch Machine\n EXP: Explosive\n FD: Food and Drink\n G: Adventuring Gear\n GS: Gaming Set\n GV: Generic Variant\n HA: Heavy Armor\n IDG: Illegal Drug\n INS: Instrument\n LA: Light Armor\n M: Melee Weapon\n MA: Medium Armor\n MNT: Mount\n MR: Master Rune \n OTH: Other\n P: Potion\n R: Ranged Weapon\n RD: Rod\n RG: Ring\n S: Shield\n SC: Scroll\n SCF: Spellcasting Focus\n SHP: Vehicle (water)\n SPC: Vehicle (space)\n T: Tool\n TAH: Tack and Harness\n TG: Trade Good\n VEH: Vehicle (land)\n WD: Wand",
160
160
  "examples": [
161
161
  "$",
162
+ "$A",
163
+ "$C",
164
+ "$G",
162
165
  "A",
163
166
  "AF",
164
167
  "AIR",
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "$id": "optionalfeatures.json",
4
- "version": "1.12.2",
4
+ "version": "1.12.3",
5
5
  "title": "Optional Features",
6
6
  "type": "object",
7
7
  "$defs": {
8
- "optionalfeature": {
8
+ "optionalfeatureData": {
9
9
  "type": "object",
10
10
  "properties": {
11
11
  "name": {
@@ -128,16 +128,279 @@
128
128
  "$ref": "util-foundry.json#/$defs/foundryImg"
129
129
  }
130
130
  },
131
- "required": [
132
- "name",
133
- "entries",
134
- "source",
135
- "featureType"
136
- ],
137
131
  "additionalProperties": false
132
+ },
133
+ "optionalfeature": {
134
+ "anyOf": [
135
+ {
136
+ "type": "object",
137
+ "properties": {
138
+ "name": {
139
+ "type": "string"
140
+ },
141
+ "prerequisite": {
142
+ "$ref": "util.json#/$defs/prerequisite"
143
+ },
144
+ "entries": {
145
+ "type": "array",
146
+ "items": {
147
+ "$ref": "entry.json"
148
+ }
149
+ },
150
+ "previousVersion": {
151
+ "type": "object",
152
+ "properties": {
153
+ "name": {
154
+ "type": "string"
155
+ },
156
+ "source": {
157
+ "$ref": "util.json#/$defs/source"
158
+ }
159
+ },
160
+ "required": [
161
+ "name",
162
+ "source"
163
+ ],
164
+ "additionalProperties": false
165
+ },
166
+ "source": {
167
+ "$ref": "util.json#/$defs/source"
168
+ },
169
+ "page": {
170
+ "$ref": "util.json#/$defs/page"
171
+ },
172
+ "featureType": {
173
+ "type": "array",
174
+ "items": {
175
+ "$ref": "util.json#/$defs/dataOptionalfeatureType"
176
+ },
177
+ "uniqueItems": true
178
+ },
179
+ "otherSources": {
180
+ "$ref": "util.json#/$defs/otherSources"
181
+ },
182
+ "srd": {
183
+ "$ref": "util.json#/$defs/srd"
184
+ },
185
+ "legacy": {
186
+ "$ref": "util.json#/$defs/legacy"
187
+ },
188
+ "isClassFeatureVariant": {
189
+ "type": "boolean"
190
+ },
191
+ "additionalSpells": {
192
+ "$ref": "util.json#/$defs/additionalSpellsArray"
193
+ },
194
+ "languageProficiencies": {
195
+ "$ref": "util.json#/$defs/languageProficiencies"
196
+ },
197
+ "skillProficiencies": {
198
+ "$ref": "util.json#/$defs/skillProficiencies"
199
+ },
200
+ "weaponProficiencies": {
201
+ "$ref": "util.json#/$defs/weaponProficiencies"
202
+ },
203
+ "armorProficiencies": {
204
+ "$ref": "util.json#/$defs/armorProficiencies"
205
+ },
206
+ "toolProficiencies": {
207
+ "$ref": "util.json#/$defs/toolProficiencies"
208
+ },
209
+ "skillToolLanguageProficiencies": {
210
+ "$ref": "util.json#/$defs/skillToolLanguageProficiencies"
211
+ },
212
+ "consumes": {
213
+ "$ref": "util.json#/$defs/consumesObject"
214
+ },
215
+ "senses": {
216
+ "$ref": "util.json#/$defs/sensesArray"
217
+ },
218
+ "optionalfeatureProgression": {
219
+ "$ref": "util.json#/$defs/optionalfeatureProgression"
220
+ },
221
+ "expertise": {
222
+ "$ref": "util.json#/$defs/expertise"
223
+ },
224
+ "resist": {
225
+ "$ref": "util.json#/$defs/damageResistArrayPlayer"
226
+ },
227
+ "immune": {
228
+ "$ref": "util.json#/$defs/damageImmunityArrayPlayer"
229
+ },
230
+ "vulnerable": {
231
+ "$ref": "util.json#/$defs/damageVulnerabilityArrayPlayer"
232
+ },
233
+ "conditionImmune": {
234
+ "$ref": "util.json#/$defs/conditionImmunityArrayPlayer"
235
+ },
236
+ "hasFluff": {
237
+ "const": true
238
+ },
239
+ "hasFluffImages": {
240
+ "const": true
241
+ },
242
+ "fluff": {
243
+ "$ref": "util.json#/$defs/fluffObject"
244
+ },
245
+ "foundrySystem": {
246
+ "$ref": "util-foundry.json#/$defs/foundrySystemObject"
247
+ },
248
+ "foundryFlags": {
249
+ "$ref": "util-foundry.json#/$defs/foundryFlagsObject"
250
+ },
251
+ "foundryEffects": {
252
+ "$ref": "util-foundry.json#/$defs/foundryEffectsArray"
253
+ },
254
+ "foundryImg": {
255
+ "$ref": "util-foundry.json#/$defs/foundryImg"
256
+ }
257
+ },
258
+ "additionalProperties": false,
259
+ "required": [
260
+ "name",
261
+ "entries",
262
+ "source",
263
+ "featureType"
264
+ ]
265
+ },
266
+ {
267
+ "type": "object",
268
+ "properties": {
269
+ "name": {
270
+ "type": "string"
271
+ },
272
+ "prerequisite": {
273
+ "$ref": "util.json#/$defs/prerequisite"
274
+ },
275
+ "entries": {
276
+ "type": "array",
277
+ "items": {
278
+ "$ref": "entry.json"
279
+ }
280
+ },
281
+ "previousVersion": {
282
+ "type": "object",
283
+ "properties": {
284
+ "name": {
285
+ "type": "string"
286
+ },
287
+ "source": {
288
+ "$ref": "util.json#/$defs/source"
289
+ }
290
+ },
291
+ "required": [
292
+ "name",
293
+ "source"
294
+ ],
295
+ "additionalProperties": false
296
+ },
297
+ "source": {
298
+ "$ref": "util.json#/$defs/source"
299
+ },
300
+ "page": {
301
+ "$ref": "util.json#/$defs/page"
302
+ },
303
+ "featureType": {
304
+ "type": "array",
305
+ "items": {
306
+ "$ref": "util.json#/$defs/dataOptionalfeatureType"
307
+ },
308
+ "uniqueItems": true
309
+ },
310
+ "otherSources": {
311
+ "$ref": "util.json#/$defs/otherSources"
312
+ },
313
+ "srd": {
314
+ "$ref": "util.json#/$defs/srd"
315
+ },
316
+ "legacy": {
317
+ "$ref": "util.json#/$defs/legacy"
318
+ },
319
+ "isClassFeatureVariant": {
320
+ "type": "boolean"
321
+ },
322
+ "additionalSpells": {
323
+ "$ref": "util.json#/$defs/additionalSpellsArray"
324
+ },
325
+ "languageProficiencies": {
326
+ "$ref": "util.json#/$defs/languageProficiencies"
327
+ },
328
+ "skillProficiencies": {
329
+ "$ref": "util.json#/$defs/skillProficiencies"
330
+ },
331
+ "weaponProficiencies": {
332
+ "$ref": "util.json#/$defs/weaponProficiencies"
333
+ },
334
+ "armorProficiencies": {
335
+ "$ref": "util.json#/$defs/armorProficiencies"
336
+ },
337
+ "toolProficiencies": {
338
+ "$ref": "util.json#/$defs/toolProficiencies"
339
+ },
340
+ "skillToolLanguageProficiencies": {
341
+ "$ref": "util.json#/$defs/skillToolLanguageProficiencies"
342
+ },
343
+ "consumes": {
344
+ "$ref": "util.json#/$defs/consumesObject"
345
+ },
346
+ "senses": {
347
+ "$ref": "util.json#/$defs/sensesArray"
348
+ },
349
+ "optionalfeatureProgression": {
350
+ "$ref": "util.json#/$defs/optionalfeatureProgression"
351
+ },
352
+ "expertise": {
353
+ "$ref": "util.json#/$defs/expertise"
354
+ },
355
+ "resist": {
356
+ "$ref": "util.json#/$defs/damageResistArrayPlayer"
357
+ },
358
+ "immune": {
359
+ "$ref": "util.json#/$defs/damageImmunityArrayPlayer"
360
+ },
361
+ "vulnerable": {
362
+ "$ref": "util.json#/$defs/damageVulnerabilityArrayPlayer"
363
+ },
364
+ "conditionImmune": {
365
+ "$ref": "util.json#/$defs/conditionImmunityArrayPlayer"
366
+ },
367
+ "hasFluff": {
368
+ "const": true
369
+ },
370
+ "hasFluffImages": {
371
+ "const": true
372
+ },
373
+ "fluff": {
374
+ "$ref": "util.json#/$defs/fluffObject"
375
+ },
376
+ "foundrySystem": {
377
+ "$ref": "util-foundry.json#/$defs/foundrySystemObject"
378
+ },
379
+ "foundryFlags": {
380
+ "$ref": "util-foundry.json#/$defs/foundryFlagsObject"
381
+ },
382
+ "foundryEffects": {
383
+ "$ref": "util-foundry.json#/$defs/foundryEffectsArray"
384
+ },
385
+ "foundryImg": {
386
+ "$ref": "util-foundry.json#/$defs/foundryImg"
387
+ },
388
+ "_copy": {
389
+ "$ref": "util.json#/$defs/copyBlock_copy_generic"
390
+ }
391
+ },
392
+ "additionalProperties": false,
393
+ "required": [
394
+ "_copy"
395
+ ]
396
+ }
397
+ ]
138
398
  }
139
399
  },
140
400
  "properties": {
401
+ "_meta": {
402
+ "$ref": "util.json#/$defs/metaBlock"
403
+ },
141
404
  "optionalfeature": {
142
405
  "type": "array",
143
406
  "uniqueItems": true,
@@ -147,5 +410,8 @@
147
410
  }
148
411
  }
149
412
  },
413
+ "required": [
414
+ "optionalfeature"
415
+ ],
150
416
  "additionalProperties": false
151
417
  }