Damages parts roll

This commit is contained in:
Dapoolp 2025-07-18 02:29:31 +02:00
parent a336220281
commit a7d2916e93
7 changed files with 145 additions and 38 deletions

View file

@ -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)
);