mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-06-06 04:44:16 +02:00
Introduced a adversary category split for BP calculation and CombatTracker display based on token disposition
This commit is contained in:
parent
abd7824c96
commit
3f9f4fac17
4 changed files with 24 additions and 4 deletions
|
|
@ -350,7 +350,9 @@ export default class DhTooltipManager extends foundry.helpers.interaction.Toolti
|
|||
async getBattlepointHTML(combatId) {
|
||||
const combat = game.combats.get(combatId);
|
||||
const adversaries =
|
||||
combat.turns?.filter(x => x.actor?.isNPC)?.map(x => ({ ...x.actor, type: x.actor.system.type })) ?? [];
|
||||
combat.turns
|
||||
?.filter(x => x.actor?.isNPC && x.token.disposition === CONST.TOKEN_DISPOSITIONS.HOSTILE)
|
||||
?.map(x => ({ ...x.actor, type: x.actor.system.type })) ?? [];
|
||||
const characters = combat.turns?.filter(x => !x.isNPC && x.actor) ?? [];
|
||||
|
||||
const nrCharacters = characters.length;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue