mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-12 03:31:07 +01:00
Feature/336 damage targeted resources (#376)
* Unify healing & damage * create DHResourceData * Damages parts roll * h * ChatMessage & takeDamage updates * Adapt healing * No, there was not a console.log !
This commit is contained in:
parent
26376b49db
commit
7cbbb3168e
25 changed files with 415 additions and 232 deletions
|
|
@ -311,3 +311,15 @@ export const itemAbleRollParse = (value, actor, item) => {
|
|||
return '';
|
||||
}
|
||||
};
|
||||
|
||||
export const arraysEqual = (a, b) =>
|
||||
a.length === b.length &&
|
||||
[...new Set([...a, ...b])].every(
|
||||
v => a.filter(e => e === v).length === b.filter(e => e === v).length
|
||||
);
|
||||
|
||||
export const setsEqual = (a, b) =>
|
||||
a.size === b.size &&
|
||||
[...a].every(
|
||||
value => b.has(value)
|
||||
);
|
||||
Loading…
Add table
Add a link
Reference in a new issue