Fixed Countdown Actions not actually setting their DefaultOwnership. Fixed GMs not always getting Ownership of a countdown

This commit is contained in:
WBHarry 2026-04-11 02:53:51 +02:00
parent e7be2a7d2b
commit 97636fa134
3 changed files with 6 additions and 120 deletions

View file

@ -57,6 +57,10 @@ export default class CountdownField extends fields.ArrayField {
data.countdowns[foundry.utils.randomID()] = {
...countdown,
ownership: game.users.reduce((acc, curr) => {
if (!curr.isGM) acc[curr.id] = countdown.defaultOwnership;
return acc;
}, {}),
progress: {
...countdown.progress,
current: countdownStart,