diff --git a/module/documents/actor.mjs b/module/documents/actor.mjs index 3ac7c27e..3b294838 100644 --- a/module/documents/actor.mjs +++ b/module/documents/actor.mjs @@ -76,7 +76,7 @@ export default class DhpActor extends Actor { const update = {}; // Set default token size. Done here as we do not want to set a datamodel default, since that would apply the sizing to third party actor modules that aren't set up with the size system. - if (this.system.metadata.usesSize) { + if (this.system.metadata.usesSize && !data.system?.size) { Object.assign(update, { system: { size: CONFIG.DH.ACTOR.tokenSize.medium.id diff --git a/module/documents/token.mjs b/module/documents/token.mjs index 35a86671..c3babaa1 100644 --- a/module/documents/token.mjs +++ b/module/documents/token.mjs @@ -111,7 +111,7 @@ export default class DHToken extends CONFIG.Token.documentClass { const actor = document.actor; if (actor?.system.metadata.usesSize) { const tokenSize = tokenSizes[actor.system.size]; - if (tokenSize && tokenSize !== CONFIG.DH.ACTOR.tokenSize.custom.id) { + if (tokenSize && actor.system.size !== CONFIG.DH.ACTOR.tokenSize.custom.id) { document.updateSource({ width: tokenSize, height: tokenSize @@ -165,7 +165,7 @@ export default class DHToken extends CONFIG.Token.documentClass { if (this.actor?.system.metadata.usesSize) { const tokenSizes = game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.Homebrew).tokenSizes; const tokenSize = tokenSizes[this.actor.system.size]; - if (tokenSize && tokenSize !== CONFIG.DH.ACTOR.tokenSize.custom.id) { + if (tokenSize && this.actor.system.size !== CONFIG.DH.ACTOR.tokenSize.custom.id) { width = tokenSize ?? width; height = tokenSize ?? height; }