diff --git a/css/fvtt-hellborn.css b/css/fvtt-hellborn.css index 3546c80..528725b 100644 --- a/css/fvtt-hellborn.css +++ b/css/fvtt-hellborn.css @@ -212,6 +212,10 @@ i.fvtt-hellborn { flex-direction: column; gap: 5px; } +.fvtt-hellborn .character-main .character-pc .character-right .character-definition .character-definition-pronouns input { + min-width: 21.2rem; + max-width: 21.2rem; +} .fvtt-hellborn .character-main .character-pc .character-right .character-definition .form-group { display: flex; align-items: center; diff --git a/lang/en.json b/lang/en.json index d18e2a0..782418a 100644 --- a/lang/en.json +++ b/lang/en.json @@ -76,6 +76,9 @@ "hair": { "label": "Hair" }, + "dod": { + "label": "Date of Death" + }, "height": { "label": "Height" }, diff --git a/module/documents/roll.mjs b/module/documents/roll.mjs index d6a6e3d..2a77da7 100644 --- a/module/documents/roll.mjs +++ b/module/documents/roll.mjs @@ -91,8 +91,8 @@ export default class HellbornRoll extends Roll { case "damage": { let formula = options.rollItem.system.damage - if (options.rollItem.system.damageStat !== "none") { - let statKey = options.rollItem.system.damageStat.toLowerCase() + if (options.rollItem?.system?.damageStat && options.rollItem.system.damageStat !== "none" && options.rollItem.system.damageStat !== "") { + let statKey = options.rollItem.system?.damageStat.toLowerCase() let statValue = actor.system.stats[statKey].value formula = `${formula} + ${statValue}` } diff --git a/module/models/character.mjs b/module/models/character.mjs index f3dfee4..6de6942 100644 --- a/module/models/character.mjs +++ b/module/models/character.mjs @@ -112,16 +112,16 @@ export default class HellbornActor extends foundry.abstract.TypeDataModel { }) schema.biodata = new fields.SchemaField({ - age: new fields.NumberField({ ...requiredInteger, initial: 15, min: 6 }), + age: new fields.StringField({ required: true, nullable: false, initial: "" }), gender: new fields.StringField({ required: true, nullable: false, initial: "" }), - height: new fields.NumberField({ ...requiredInteger, initial: 170, min: 50 }), + height: new fields.StringField({ required: true, nullable: false, initial: "" }), eyes: new fields.StringField({ required: true, nullable: false, initial: "" }), birthplace: new fields.StringField({ required: true, nullable: false, initial: "" }), hair: new fields.StringField({ required: true, nullable: false, initial: "" }), home: new fields.StringField({ required: true, nullable: false, initial: "" }), - weight: new fields.NumberField({ ...requiredInteger, initial: 70, min: 1 }), - apparentAge: new fields.NumberField({ ...requiredInteger, initial: 20, min: 1 }), - chronologicalAge: new fields.NumberField({ ...requiredInteger, initial: 20, min: 1 }), + weight: new fields.StringField({ required: true, nullable: false, initial: "" }), + apparentAge: new fields.StringField({ required: true, nullable: false, initial: "" }), + chronologicalAge: new fields.StringField({ required: true, nullable: false, initial: "" }), dod: new fields.StringField({ required: true, nullable: false, initial: "" }), soul: new fields.StringField({ required: true, nullable: false, initial: "" }), aliases: new fields.StringField({ required: true, nullable: false, initial: "" }) diff --git a/module/models/tarot.mjs b/module/models/tarot.mjs index a447b4c..a7559d6 100644 --- a/module/models/tarot.mjs +++ b/module/models/tarot.mjs @@ -9,7 +9,7 @@ export default class HellbornTarot extends foundry.abstract.TypeDataModel { schema.bonus = new fields.StringField({ required: true, nullable: false, initial: "" }); schema.penalty = new fields.StringField({ required: true, nullable: false, initial: "" }); - schema.orientation = new fields.StringField({ required: true, initial: "Upright", choices: {"Upright": {label: "Upright"}, "Downright": {label: "Downright"}} }); + schema.orientation = new fields.StringField({ required: true, initial: "Upright", choices: {"Upright": {label: "Upright"}, "Downright": {label: "Reversed"}} }); schema.description = new fields.HTMLField({ required: true, textSearch: true }) schema.positiveEffect = new fields.HTMLField({ required: true, textSearch: true }) schema.negativeEffect = new fields.HTMLField({ required: true, textSearch: true }) diff --git a/styles/character.less b/styles/character.less index 1b40393..8247d25 100644 --- a/styles/character.less +++ b/styles/character.less @@ -65,6 +65,12 @@ gap: 5px; .character-definition { + .character-definition-pronouns { + input { + min-width: 21.2rem; + max-width: 21.2rem; + } + } .form-group { display: flex; align-items: center; diff --git a/templates/character-biography.hbs b/templates/character-biography.hbs index 443abdd..b3409ac 100644 --- a/templates/character-biography.hbs +++ b/templates/character-biography.hbs @@ -44,6 +44,10 @@ {{formField systemFields.biodata.fields.birthplace value=system.biodata.birthplace rootId=partId disabled=isPlayMode}} +
+ {{formField systemFields.biodata.fields.dod value=system.biodata.dod rootId=partId + disabled=isPlayMode}} +
diff --git a/templates/character-main.hbs b/templates/character-main.hbs index 625d520..db87267 100644 --- a/templates/character-main.hbs +++ b/templates/character-main.hbs @@ -19,11 +19,11 @@
+
+ {{formField systemFields.pronouns value=system.pronouns rootId=partId disabled=isPlayMode}} +
-
- {{formField systemFields.pronouns value=system.pronouns rootId=partId disabled=isPlayMode}} -
{{formField systemFields.species value=system.species rootId=partId disabled=isPlayMode}}
@@ -56,7 +56,7 @@