feat: flat spell frontmatter, full source-book titles, drop circle
Parser reads human-friendly flat keys (range, targets, castingTime, overcast list, threshold/successes, ...) and expands them to SpellData; fixes [object Object] range, empty targets/casting time and blank overcast rows. SOURCE_BOOKS ids now match vault slugs and show full book titles. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -49,7 +49,7 @@ export class NpcSheet extends HandlebarsApplicationMixin(ActorSheetV2) {
|
||||
const ctx = (await super._prepareContext(options)) as Record<string, unknown>;
|
||||
const actor = (this as unknown as { actor: { system: any; items: any[] } }).actor;
|
||||
const spells = actor.items.filter((it: any) => it.type === 'spell')
|
||||
.sort((a: any, b: any) => (a.system?.circle ?? 0) - (b.system?.circle ?? 0) || a.name.localeCompare(b.name, 'pl'));
|
||||
.sort((a: any, b: any) => a.name.localeCompare(b.name, 'pl'));
|
||||
const actorEffects = [...((actor as any).effects ?? [])].map((ef: any) => ({
|
||||
id: ef.id,
|
||||
name: ef.name,
|
||||
|
||||
Reference in New Issue
Block a user