mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-12 03:31:07 +01:00
[Bugfix] Fix light theme to roll messages (#1066)
* fix light theme to roll messages * fix light theme issues * finally fix issues --------- Co-authored-by: WBHarry <williambjrklund@gmail.com>
This commit is contained in:
parent
661808b5f1
commit
2a0d748b5e
11 changed files with 523 additions and 423 deletions
|
|
@ -11,19 +11,19 @@ export default class DhMeasuredTemplate extends foundry.canvas.placeables.Measur
|
|||
if (splitRulerText.length > 0) {
|
||||
const rulerValue = Number(splitRulerText[0]);
|
||||
const result = DhMeasuredTemplate.getRangeLabels(rulerValue, rangeMeasurementSettings);
|
||||
this.ruler.text = result.distance + (result.units ? (' ' + result.units) : '');
|
||||
this.ruler.text = result.distance + (result.units ? ' ' + result.units : '');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static getRangeLabels(distanceValue, settings) {
|
||||
let result = { distance: distanceValue, units: '' }
|
||||
let result = { distance: distanceValue, units: '' };
|
||||
const rangeMeasurementOverride = canvas.scene.flags.daggerheart?.rangeMeasurementOverride;
|
||||
|
||||
if (rangeMeasurementOverride === true) {
|
||||
result.distance = distanceValue;
|
||||
result.units = canvas.scene?.grid?.units;
|
||||
return result
|
||||
return result;
|
||||
}
|
||||
if (distanceValue <= settings.melee) {
|
||||
result.distance = game.i18n.localize('DAGGERHEART.CONFIG.Range.melee.name');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue