Make the generic Item subtype actually provide the speaker data to the macro
This commit is contained in:
parent
c6d3c094b8
commit
77413687e9
2 changed files with 3 additions and 3 deletions
|
|
@ -166,7 +166,7 @@ export class AttributeItemData extends foundry.abstract.TypeDataModel {
|
||||||
// the Actor's getData method, letting us augment the context dynamically for
|
// the Actor's getData method, letting us augment the context dynamically for
|
||||||
// the @active roll context
|
// the @active roll context
|
||||||
const speaker = foundry.documents.ChatMessage.implementation.getSpeaker({
|
const speaker = foundry.documents.ChatMessage.implementation.getSpeaker({
|
||||||
actor: this.parent.parent
|
actor: this.parent.parent,
|
||||||
});
|
});
|
||||||
|
|
||||||
await macro?.execute({ item: this.parent, speaker });
|
await macro?.execute({ item: this.parent, speaker });
|
||||||
|
|
|
||||||
|
|
@ -88,10 +88,10 @@ export class GenericItemData extends foundry.abstract.TypeDataModel {
|
||||||
// the Actor's getData method, letting us augment the context dynamically for
|
// the Actor's getData method, letting us augment the context dynamically for
|
||||||
// the @active roll context
|
// the @active roll context
|
||||||
const speaker = foundry.documents.ChatMessage.implementation.getSpeaker({
|
const speaker = foundry.documents.ChatMessage.implementation.getSpeaker({
|
||||||
actor: this.parent.parent
|
actor: this.parent.parent,
|
||||||
});
|
});
|
||||||
|
|
||||||
await macro?.execute({ item: this.parent });
|
await macro?.execute({ item: this.parent, speaker });
|
||||||
};
|
};
|
||||||
// #endregion Methods
|
// #endregion Methods
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue