Irk/83 homebrew currency (#193)

* add homebrew options to rename currency names

* add title. remove localization from settings file since it didn't work.

* use enabled toggle to use localized initial label values.

* cleanup
This commit is contained in:
IrkTheImp 2025-06-28 14:00:42 -05:00 committed by GitHub
parent 778e569037
commit b25e1cec78
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 121 additions and 23 deletions

View file

@ -16,6 +16,38 @@ export default class DhHomebrew extends foundry.abstract.DataModel {
traitArray: new fields.ArrayField(new fields.NumberField({ required: true, integer: true }), {
initial: () => [2, 1, 1, 0, 0, -1]
}),
currency: new fields.SchemaField({
enabled: new fields.BooleanField({
required: true,
initial: false,
label: 'DAGGERHEART.Settings.Homebrew.Currency.enabled'
}),
title: new fields.StringField({
required: true,
initial: 'Gold',
label: 'DAGGERHEART.Settings.Homebrew.Currency.currencyName'
}),
coins: new fields.StringField({
required: true,
initial: 'Coins',
label: 'DAGGERHEART.Settings.Homebrew.Currency.coinName'
}),
handfulls: new fields.StringField({
required: true,
initial: 'Handfulls',
label: 'DAGGERHEART.Settings.Homebrew.Currency.handfullName'
}),
bags: new fields.StringField({
required: true,
initial: 'Bags',
label: 'DAGGERHEART.Settings.Homebrew.Currency.bagName'
}),
chests: new fields.StringField({
required: true,
initial: 'Chests',
label: 'DAGGERHEART.Settings.Homebrew.Currency.chestName'
})
}),
restMoves: new fields.SchemaField({
longRest: new fields.SchemaField({
nrChoices: new fields.NumberField({ required: true, integer: true, min: 1, initial: 2 }),