mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-04-22 07:23:37 +02:00
Add game.actors.party and refine logic
This commit is contained in:
parent
b08b8b93b6
commit
031f497c33
5 changed files with 22 additions and 18 deletions
|
|
@ -117,7 +117,9 @@ export default class DhpActor extends Actor {
|
|||
}
|
||||
}
|
||||
|
||||
async _preDelete() {
|
||||
async _preDelete(options, user) {
|
||||
if ((await super._preDelete(options, user)) === false) return false;
|
||||
|
||||
if (this.prototypeToken.actorLink) {
|
||||
game.system.registeredTriggers.unregisterItemTriggers(this.items);
|
||||
} else {
|
||||
|
|
@ -125,8 +127,6 @@ export default class DhpActor extends Actor {
|
|||
game.system.registeredTriggers.unregisterItemTriggers(token.actor.items);
|
||||
}
|
||||
}
|
||||
|
||||
if(this.system._preDelete() === false) return false;
|
||||
}
|
||||
|
||||
_onDelete(options, userId) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue