mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-12 19:51:08 +01:00
Added localization for the fate type parsing error
This commit is contained in:
parent
3e366a4c44
commit
c11a4f617d
3 changed files with 6 additions and 5 deletions
|
|
@ -7,7 +7,7 @@ export default function DhFateRollEnricher(match, _options) {
|
|||
const fateTypeFromRoll = getFateType(roll?.type);
|
||||
|
||||
if (fateTypeFromRoll == "BAD") {
|
||||
ui.notifications.error(game.i18n.localize('DAGGERHEART.UI.Notifications.fateParsing') + ". Bad Fate Type. Valid Fate Types are 'Hope' and 'Fear'.");
|
||||
ui.notifications.error(game.i18n.localize('DAGGERHEART.UI.Notifications.fateTypeParsing'));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -27,10 +27,10 @@ function getFateMessage(roll, flavor) {
|
|||
const fateType = getFateType(roll?.type);
|
||||
|
||||
if (fateType == "BAD") {
|
||||
ui.notifications.error(game.i18n.localize('DAGGERHEART.UI.Notifications.fateParsing') + ". Bad Fate Type. Valid Fate Types are 'Hope' and 'Fear'.");
|
||||
ui.notifications.error(game.i18n.localize('DAGGERHEART.UI.Notifications.fateTypeParsing'));
|
||||
return '';
|
||||
}
|
||||
|
||||
|
||||
const fateTypeLocalized = fateType === "Hope" ? game.i18n.localize("DAGGERHEART.GENERAL.hope") : game.i18n.localize("DAGGERHEART.GENERAL.fear");
|
||||
|
||||
const title = flavor ?? fateTypeLocalized + ' ' +
|
||||
|
|
@ -61,7 +61,7 @@ export const renderFateButton = async event => {
|
|||
const fateTypeFromButton = getFateType(button.dataset?.fatetype);
|
||||
|
||||
if (fateTypeFromButton == "BAD") {
|
||||
ui.notifications.error(game.i18n.localize('DAGGERHEART.UI.Notifications.fateParsing') + ". Bad Fate Type. Valid Fate Types are 'Hope' and 'Fear'.");
|
||||
ui.notifications.error(game.i18n.localize('DAGGERHEART.UI.Notifications.fateTypeParsing'));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue