Working on the spells panel, which resulted in a lot of weird structural changes that aren't *really* functional yet
This commit is contained in:
parent
227029ffcd
commit
dfc51a5899
31 changed files with 499 additions and 84 deletions
|
|
@ -20,23 +20,23 @@ export class PlayerSheet extends GenericActorSheet {
|
|||
console.debug(`.dungeon | Adding event listeners for Actor: ${this.id}`);
|
||||
|
||||
html.find(`.add-spell`).on(`click`, this.actor.createCustomSpell.bind(this.actor));
|
||||
html.find(`[data-embedded-update]`)
|
||||
.on(`change`, this.actor.updateEmbeddedDocument.bind(this.actor));
|
||||
};
|
||||
|
||||
getData() {
|
||||
const ctx = super.getData();
|
||||
async getData() {
|
||||
const ctx = await super.getData();
|
||||
const actor = this.actor.toObject(false);
|
||||
|
||||
ctx.system = actor.system;
|
||||
ctx.flags = actor.flags;
|
||||
ctx.items = this.actor.itemTypes;
|
||||
|
||||
ctx.computed = {
|
||||
canChangeGroup: ctx.settings.playersCanChangeGroup || ctx.isGM,
|
||||
};
|
||||
|
||||
console.groupCollapsed(`PlayerSheet.getData`);
|
||||
console.log(`ctx`, ctx);
|
||||
console.log(`actor`, actor);
|
||||
console.groupEnd();
|
||||
console.log(ctx)
|
||||
return ctx;
|
||||
};
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue