Merge branch 'main' into feature/death-moves

This commit is contained in:
Chris Ryan 2026-01-15 21:20:26 +10:00
commit 7e4422dbf4
9 changed files with 30 additions and 15 deletions

View file

@ -2290,7 +2290,8 @@
"placeholder": "Using character dimensions",
"disabledPlaceholder": "Set by character size",
"height": { "label": "Height" },
"width": { "label": "Width" }
"width": { "label": "Width" },
"scale": { "label": "Token Scale" }
},
"evolved": {
"maximumTier": { "label": "Maximum Tier" },

View file

@ -19,6 +19,7 @@ export default class BeastformEffect extends BaseEffect {
base64: false
}),
tokenSize: new fields.SchemaField({
scale: new fields.NumberField({ nullable: false, initial: 1 }),
height: new fields.NumberField({ integer: false, nullable: true }),
width: new fields.NumberField({ integer: false, nullable: true })
})
@ -55,7 +56,9 @@ export default class BeastformEffect extends BaseEffect {
const update = {
...baseUpdate,
texture: {
src: this.characterTokenData.tokenImg
src: this.characterTokenData.tokenImg,
scaleX: this.characterTokenData.tokenSize.scale,
scaleY: this.characterTokenData.tokenSize.scale
},
ring: {
enabled: this.characterTokenData.usesDynamicToken,
@ -86,7 +89,9 @@ export default class BeastformEffect extends BaseEffect {
y,
'texture': {
enabled: this.characterTokenData.usesDynamicToken,
src: token.flags.daggerheart?.beastformTokenImg ?? this.characterTokenData.tokenImg
src: token.flags.daggerheart?.beastformTokenImg ?? this.characterTokenData.tokenImg,
scaleX: this.characterTokenData.tokenSize.scale,
scaleY: this.characterTokenData.tokenSize.scale
},
'ring': {
subject: {

View file

@ -49,6 +49,7 @@ export default class DHBeastform extends BaseDataItem {
choices: CONFIG.DH.ACTOR.tokenSize,
initial: CONFIG.DH.ACTOR.tokenSize.custom.id
}),
scale: new fields.NumberField({ nullable: false, min: 0.2, max: 3, step: 0.05, initial: 1 }),
height: new fields.NumberField({ integer: true, min: 1, initial: null, nullable: true }),
width: new fields.NumberField({ integer: true, min: 1, initial: null, nullable: true })
}),
@ -184,6 +185,7 @@ export default class DHBeastform extends BaseDataItem {
tokenImg: this.parent.parent.prototypeToken.texture.src,
tokenRingImg: this.parent.parent.prototypeToken.ring.subject.texture,
tokenSize: {
scale: this.parent.parent.prototypeToken.texture.scaleX,
height: this.parent.parent.prototypeToken.height,
width: this.parent.parent.prototypeToken.width
}
@ -209,7 +211,9 @@ export default class DHBeastform extends BaseDataItem {
height,
width,
texture: {
src: this.tokenImg
src: this.tokenImg,
scaleX: this.tokenSize.scale,
scaleY: this.tokenSize.scale
},
ring: {
subject: {

View file

@ -51,3 +51,14 @@
}
}
}
/* TODO: Remove me when this issue is resolved https://github.com/foundryvtt/foundryvtt/issues/13734 */
body.theme-dark,
.themed.theme-dark {
color-scheme: dark;
}
body.theme-light,
.themed.theme-light {
color-scheme: light;
}

View file

@ -10,7 +10,6 @@
@import './tab-description.less';
@import './tab-features.less';
@import './tab-effects.less';
@import './tab-settings.less';
@import './item-header.less';
@import './feature-section.less';
@import './inventory-item.less';

View file

@ -160,7 +160,7 @@
.item-description {
display: flex;
flex-direction: column;
gap: 10px;
gap: 7px;
}
h3 {

View file

@ -1,8 +0,0 @@
@import '../utils/colors.less';
@import '../utils/fonts.less';
.sheet.daggerheart.dh-style {
.tab.settings {
margin-bottom: 36px;
}
}

View file

@ -1,4 +1,4 @@
.theme-light #interface #ui-right #sidebar {
.theme-light#interface #ui-right #sidebar {
menu li button img {
filter: @grey-filter;
}

View file

@ -47,6 +47,9 @@
disabled=dimensionsDisabled
}}
</div>
<div class="full-width">
{{formGroup systemFields.tokenSize.fields.scale value=source.system.tokenSize.scale localize=true }}
</div>
{{else}}
<span class="hint">{{localize "DAGGERHEART.ITEMS.Beastform.evolvedTokenHint"}}</span>
{{/unless}}