diff --git a/lang/en.json b/lang/en.json
index d99c1c2..a2a5055 100644
--- a/lang/en.json
+++ b/lang/en.json
@@ -18,6 +18,12 @@
"Save": "Save",
"Cancel": "Cancel",
"Close": "Close",
+ "Dialog": {
+ "ConfirmDeleteTitle": "Confirm Deletion",
+ "ConfirmDeleteContent": "Are you sure you want to delete \"{name}\"?",
+ "Yes": "Yes",
+ "No": "No"
+ },
"Themes": {
"BlackAndRed": "Classic Traveller Cover",
"Mwamba": "Oppa Mwamba Style",
@@ -60,6 +66,7 @@
"Weeks": "Weeks",
"NewCareer": "New Career",
"AddCareer": "Add Career",
+ "ThisTrait": "this trait",
"EditCareer": "Edit Career",
"EditTrait": "Éditer Trait",
"DeleteTrait": "Supprimer Trait",
@@ -343,7 +350,10 @@
"EncumbranceDM": "Encumbrance (DM -2)",
"FatigueDM": "Fatigue (DM -2)",
"Boon": "Boon",
- "Bane": "Bane"
+ "Bane": "Bane",
+ "CreatureSkill": "Skill",
+ "NoSkill": "No skill",
+ "Days": "Days"
},
"Timeframes": {
"Normal": "Normal",
@@ -355,7 +365,11 @@
"ApplyDamages": "Apply Damages",
"Damages": "Roll damages",
"Success": "Success",
- "Failure": "Failure"
+ "Failure": "Failure",
+ "Effect": "Effect",
+ "Dice": "Dice",
+ "Result": "Result",
+ "DiceModifier": "Dice Modifier"
}
},
"Items": {
@@ -393,7 +407,7 @@
"Informations": "Informations",
"Improvement": "Improvement",
"Interval": "Interval",
- "IsMelee": "IsMelee",
+ "IsMelee": "Melee Weapon",
"Items": "Items",
"Level": "Level",
"Location": "Location",
@@ -410,6 +424,7 @@
"Occupation": "Occupation",
"OnHand": "On Hand",
"Options": "Options",
+ "PerDay": "per day",
"PSICost": "PSI Cost",
"Powered": "Powered",
"Processing": "Processing",
@@ -461,11 +476,13 @@
"TabAttacks": "Attacks",
"TabTraits": "Traits",
"TabInfo": "Information",
+ "TabCombat": "Combat",
"SkillName": "Skill",
"SkillLevel": "Level",
"SkillNote": "Note",
"AttackName": "Attack",
"AttackDamage": "Damage",
+ "AttackSkill": "Skill",
"TraitName": "Trait",
"TraitValue": "Value",
"AddSkill": "Add a skill",
@@ -480,6 +497,36 @@
"SkillLabel": "Skill",
"RollTitle": "Creature roll"
},
+ "SpeedBands": {
+ "Stoppped": "Stopped",
+ "Idle": "Idle",
+ "VerySlow": "Very Slow",
+ "Slow": "Slow",
+ "Medium": "Medium",
+ "High": "High",
+ "Fast": "Fast",
+ "VeryFast": "Very Fast",
+ "Subsonic": "Subsonic",
+ "Hypersonic": "Hypersonic"
+ },
+ "Vehicule": {
+ "Hull": "Hull",
+ "ArmorFront": "Front",
+ "ArmorSides": "Sides",
+ "ArmorRear": "Rear",
+ "Armor": "Armor",
+ "SpeedCruise": "Cruise Speed",
+ "SpeedMax": "Max Speed",
+ "Agility": "Agility",
+ "Crew": "Crew",
+ "Passengers": "Passengers",
+ "Cargo": "Cargo (t)",
+ "Shipping": "Shipping (t)",
+ "Cost": "Cost (Cr)",
+ "Autopilot": "Autopilot",
+ "TabStats": "Statistics",
+ "TabDescription": "Description"
+ },
"CreatureBehaviorType": {
"herbivore": "Herbivore",
"carnivore": "Carnivore",
@@ -500,6 +547,29 @@
"necrophage": "Carrion-eater",
"reducteur": "Reducer",
"opportuniste": "Opportunist"
+ },
+ "Healing": {
+ "Title": "Healing",
+ "FirstAid": "First Aid",
+ "Surgery": "Surgery",
+ "MedicalCare": "Medical Care",
+ "NaturalHealing": "Natural Healing",
+ "WillRestore": "Will restore",
+ "SurgeryFailed": "Surgery failed - patient takes damage",
+ "ApplyHealing": "Apply Healing",
+ "ApplySurgeryDamage": "Apply Surgery Damage",
+ "SurgeryDamage": "surgery damage",
+ "ApplyToTarget": "Apply healing to selected target",
+ "NoMedicineSkill": "No Medicine Skill",
+ "Heals": "heals"
+ },
+ "Notifications": {
+ "HealingApplied": "{name} has been healed for {amount} points.",
+ "DamageApplied": "{name} has taken {amount} damage."
+ },
+ "Errors": {
+ "NoTokenSelected": "No token selected. Select a token on the scene before applying.",
+ "InvalidRollFormula": "Invalid roll formula."
}
},
"TYPES.Actor.creature": "Creature"
diff --git a/lang/fr.json b/lang/fr.json
index 8efa29b..3680f32 100644
--- a/lang/fr.json
+++ b/lang/fr.json
@@ -18,6 +18,12 @@
"Save": "Sauvegarder",
"Cancel": "Annuler",
"Close": "Fermer",
+ "Dialog": {
+ "ConfirmDeleteTitle": "Confirmer la suppression",
+ "ConfirmDeleteContent": "Êtes-vous sûr de vouloir supprimer \"{name}\" ?",
+ "Yes": "Oui",
+ "No": "Non"
+ },
"Themes": {
"BlackAndRed": "Couverture Classique Traveller",
"Mwamba": "Oppa Mwamba Style",
@@ -60,6 +66,7 @@
"Weeks": "Semaines",
"NewCareer": "Nouvelle Carrière",
"AddCareer": "Ajouter Carrière",
+ "ThisTrait": "ce trait",
"EditCareer": "Éditer Carrière",
"EditTrait": "Éditer Trait",
"DeleteTrait": "Supprimer Trait",
@@ -343,7 +350,10 @@
"EncumbranceDM": "Encombrement (MD -2)",
"FatigueDM": "Fatigue (MD -2)",
"Boon": "Avantage",
- "Bane": "Désavantage"
+ "Bane": "Désavantage",
+ "CreatureSkill": "Compétence",
+ "NoSkill": "Aucune compétence",
+ "Days": "Jours"
},
"Timeframes": {
"Normal": "Normal",
@@ -355,7 +365,11 @@
"ApplyDamages": "Appliquer Dégâts",
"Damages": "Lancer les Dégâts",
"Success": "Succès",
- "Failure": "Échec"
+ "Failure": "Échec",
+ "Effect": "Effet",
+ "Dice": "Dés",
+ "Result": "Résultat",
+ "DiceModifier": "Modificateur de dés"
}
},
"Items": {
@@ -393,7 +407,7 @@
"Informations": "Informations",
"Improvement": "Améliorations",
"Interval": "Intervalle",
- "IsMelee": "Est Mêlée",
+ "IsMelee": "Arme de Mêlée",
"Items": "Objets",
"Level": "Niveau",
"Location": "Localisation",
@@ -410,6 +424,7 @@
"Occupation": "Profession",
"OnHand": "Sur Soi",
"Options": "Options",
+ "PerDay": "par jour",
"PSICost": "Coût PSI",
"Powered": "Alimenté",
"Processing": "Capacité de Traitement",
@@ -461,11 +476,13 @@
"TabAttacks": "Attaques",
"TabTraits": "Traits",
"TabInfo": "Informations",
+ "TabCombat": "Combat",
"SkillName": "Compétence",
"SkillLevel": "Niveau",
"SkillNote": "Note",
"AttackName": "Attaque",
"AttackDamage": "Dommages",
+ "AttackSkill": "Compétence",
"TraitName": "Trait",
"TraitValue": "Valeur",
"AddSkill": "Ajouter une compétence",
@@ -480,6 +497,36 @@
"SkillLabel": "Compétence",
"RollTitle": "Jet de créature"
},
+ "SpeedBands": {
+ "Stoppped": "Arrêté",
+ "Idle": "Au ralenti",
+ "VerySlow": "Très lent",
+ "Slow": "Lent",
+ "Medium": "Moyen",
+ "High": "Élevé",
+ "Fast": "Rapide",
+ "VeryFast": "Très rapide",
+ "Subsonic": "Subsonique",
+ "Hypersonic": "Hypersonique"
+ },
+ "Vehicule": {
+ "Hull": "Coque",
+ "ArmorFront": "Av.",
+ "ArmorSides": "Lat.",
+ "ArmorRear": "Arr.",
+ "Armor": "Armure",
+ "SpeedCruise": "Vitesse croisière",
+ "SpeedMax": "Vitesse max",
+ "Agility": "Agilité",
+ "Crew": "Équipage",
+ "Passengers": "Passagers",
+ "Cargo": "Cargo (t)",
+ "Shipping": "Expédition (t)",
+ "Cost": "Coût (Cr)",
+ "Autopilot": "Autopilote",
+ "TabStats": "Statistiques",
+ "TabDescription": "Description"
+ },
"CreatureBehaviorType": {
"herbivore": "Herbivore",
"carnivore": "Carnivore",
@@ -500,6 +547,29 @@
"necrophage": "Nécrophage",
"reducteur": "Réducteur",
"opportuniste": "Opportuniste"
+ },
+ "Healing": {
+ "Title": "Soins",
+ "FirstAid": "Premiers soins",
+ "Surgery": "Chirurgie",
+ "MedicalCare": "Soins médicaux",
+ "NaturalHealing": "Guérison naturelle",
+ "WillRestore": "Restaurera",
+ "SurgeryFailed": "Chirurgie échouée - patient subit des dégâts",
+ "ApplyHealing": "Appliquer les soins",
+ "ApplySurgeryDamage": "Appliquer les dégâts chirurgicaux",
+ "SurgeryDamage": "dégâts chirurgicaux",
+ "ApplyToTarget": "Appliquer les soins à la cible sélectionnée",
+ "NoMedicineSkill": "Pas de compétence Médecine",
+ "Heals": "soigne"
+ },
+ "Notifications": {
+ "HealingApplied": "{name} a été soigné(e) de {amount} points.",
+ "DamageApplied": "{name} a subi {amount} dégâts."
+ },
+ "Errors": {
+ "NoTokenSelected": "Aucun token sélectionné. Sélectionnez un token sur la scène avant d'appliquer.",
+ "InvalidRollFormula": "Formule de jet invalide."
}
},
"TYPES.Actor.creature": "Créature"
diff --git a/mgt2.bundle.js b/mgt2.bundle.js
index 0149c18..0ed7dd8 100644
--- a/mgt2.bundle.js
+++ b/mgt2.bundle.js
@@ -13,7 +13,7 @@ function createCharacteristicField(show = true, showMax = false) {
class ItemBaseData extends foundry.abstract.TypeDataModel {
static defineSchema() {
return {
- description: new fields$e.StringField({ required: false, blank: true, trim: true, nullable: true }),
+ description: new fields$e.HTMLField({ required: false, blank: true, trim: true }),
subType: new fields$e.StringField({ required: false, blank: false, nullable: true })
};
}
@@ -88,7 +88,9 @@ class CharacterData extends foundry.abstract.TypeDataModel {
}),
health: new fields$d.SchemaField({
- radiations: new fields$d.NumberField({ required: false, initial: 0, min: 0, integer: true })
+ radiations: new fields$d.NumberField({ required: false, initial: 0, min: 0, integer: true }),
+ lastFirstAidDate: new fields$d.StringField({ required: false, blank: true, trim: true }),
+ healingRecoveryMode: new fields$d.StringField({ required: false, blank: true, trim: true, initial: "" })
}),
study: new fields$d.SchemaField({
skill: new fields$d.StringField({ required: false, blank: true, trim: true, initial: "" }),
@@ -102,7 +104,7 @@ class CharacterData extends foundry.abstract.TypeDataModel {
debt: new fields$d.NumberField({ required: true, initial: 0, min: 0, integer: true }),
livingCost: new fields$d.NumberField({ required: true, initial: 0, min: 0, integer: true }),
monthlyShipPayments: new fields$d.NumberField({ required: true, initial: 0, min: 0, integer: true }),
- notes: new fields$d.StringField({ required: false, blank: true, trim: true, initial: "" })
+ notes: new fields$d.HTMLField({ required: false, blank: true, trim: true })
}),
containerView: new fields$d.StringField({ required: false, blank: true, trim: true, initial: "" }),
containerDropIn: new fields$d.StringField({ required: false, blank: true, trim: true, initial: "" }),
@@ -165,7 +167,9 @@ class VehiculeData extends foundry.abstract.TypeDataModel {
}),
skills: new fields$c.SchemaField({
autopilot: new fields$c.NumberField({ required: true, initial: 0, integer: true })
- })
+ }),
+ description: new fields$c.HTMLField({ required: false, blank: true, trim: true }),
+ notes: new fields$c.HTMLField({ required: false, blank: true, trim: true })
};
}
}
@@ -201,6 +205,7 @@ class CreatureData extends foundry.abstract.TypeDataModel {
new fields$b.SchemaField({
name: new fields$b.StringField({ required: true, blank: true, trim: true, initial: "" }),
damage: new fields$b.StringField({ required: true, blank: true, trim: true, initial: "1D" }),
+ skill: new fields$b.NumberField({ required: false, initial: -1, integer: true }),
description: new fields$b.StringField({ required: false, blank: true, trim: true, initial: "" })
})
),
@@ -466,7 +471,7 @@ class ItemContainerData extends ItemBaseData {
schema.weight = new fields$1.NumberField({ required: false, initial: 0, integer: false });
schema.weightless = new fields$1.BooleanField({ required: false, initial: false });
schema.locked = new fields$1.BooleanField({ required: false, initial: false }); // GM only
- schema.lockedDescription = new fields$1.StringField({ required: false, blank: true, trim: true, nullable: true });
+ schema.lockedDescription = new fields$1.HTMLField({ required: false, blank: true, trim: true });
return schema;
}
}
@@ -476,7 +481,7 @@ const fields = foundry.data.fields;
class SpeciesData extends foundry.abstract.TypeDataModel {
static defineSchema() {
return {
- description: new fields.StringField({ required: false, blank: true, trim: true, nullable: true }),
+ description: new fields.HTMLField({ required: false, blank: true, trim: true }),
descriptionLong: new fields.HTMLField({ required: false, blank: true, trim: true }),
traits: new fields.ArrayField(
new fields.SchemaField({
@@ -639,7 +644,7 @@ MGT2.SpeedBands = Object.freeze({
VerySlow: "MGT2.SpeedBands.VerySlow",
Slow: "MGT2.SpeedBands.Slow",
Medium: "MGT2.SpeedBands.Medium",
- High: "MGT2.SpeedBands.High.",
+ High: "MGT2.SpeedBands.High",
Fast: "MGT2.SpeedBands.Fast",
VeryFast: "MGT2.SpeedBands.VeryFast",
Subsonic: "MGT2.SpeedBands.Subsonic",
@@ -675,6 +680,13 @@ MGT2.CreatureBehaviorSubType = Object.freeze({
opportuniste: "MGT2.CreatureBehaviorSubType.opportuniste"
});
+MGT2.HealingType = Object.freeze({
+ FIRST_AID: "MGT2.Healing.FirstAid",
+ SURGERY: "MGT2.Healing.Surgery",
+ MEDICAL_CARE: "MGT2.Healing.MedicalCare",
+ NATURAL_HEALING: "MGT2.Healing.NaturalHealing"
+});
+
class ActorCharacter {
static preCreate($this, data, options, user) {
$this.updateSource({ prototypeToken: { actorLink: true } }); // QoL
@@ -1005,7 +1017,7 @@ class ActorCharacter {
// $this.update({ system: { characteristics: data } });
// }
- static applyDamage($this, amount) {
+ static applyDamage($this, amount, { ignoreArmor = false } = {}) {
if (isNaN(amount) || amount === 0) return;
const rank1 = $this.system.config.damages.rank1;
const rank2 = $this.system.config.damages.rank2;
@@ -1018,6 +1030,12 @@ class ActorCharacter {
if (amount < 0) amount = Math.abs(amount);
+ if (!ignoreArmor) {
+ const armorValue = $this.system.inventory?.armor ?? 0;
+ amount = Math.max(0, amount - armorValue);
+ if (amount === 0) return;
+ }
+
for (const [key, rank] of Object.entries(data)) {
if (rank.value > 0) {
if (rank.value >= amount) {
@@ -1035,6 +1053,48 @@ class ActorCharacter {
$this.update({ system: { characteristics: data } });
}
+ static applyHealing($this, amount, type) {
+ if (isNaN(amount) || amount === 0) return;
+
+ const rank1 = $this.system.config.damages.rank1;
+ const rank2 = $this.system.config.damages.rank2;
+ const rank3 = $this.system.config.damages.rank3;
+
+ // Data to restore (reverse cascade: END → DEX → STR)
+ const data = {};
+ const rankOrder = [rank3, rank2, rank1]; // Reverse order for healing
+ const maxValues = {
+ [rank1]: $this.system.characteristics[rank1].max,
+ [rank2]: $this.system.characteristics[rank2].max,
+ [rank3]: $this.system.characteristics[rank3].max
+ };
+
+ if (amount < 0) amount = Math.abs(amount);
+
+ // Distribute healing from lowest rank first (END → DEX → STR typically)
+ for (const rank of rankOrder) {
+ const current = $this.system.characteristics[rank].value;
+ const max = maxValues[rank];
+
+ if (current < max && amount > 0) {
+ const canRestore = max - current;
+ const restore = Math.min(amount, canRestore);
+
+ if (!data[rank]) {
+ data[rank] = { value: current };
+ }
+ data[rank].value += restore;
+ data[rank].dm = this.getModifier(data[rank].value);
+ amount -= restore;
+ }
+ }
+
+ // Only update if something was restored
+ if (Object.keys(data).length > 0) {
+ return $this.update({ system: { characteristics: data } });
+ }
+ }
+
static getContainers($this) {
const containers = [];
for (let item of $this.items) {
@@ -1177,9 +1237,32 @@ class TravellerActor extends Actor {
}
}
- applyDamage(amount) {
+ applyDamage(amount, { ignoreArmor = false } = {}) {
if (this.type === "character") {
- ActorCharacter.applyDamage(this, amount);
+ return ActorCharacter.applyDamage(this, amount, { ignoreArmor });
+ } else if (this.type === "creature") {
+ if (isNaN(amount) || amount === 0) return;
+ if (amount < 0) amount = Math.abs(amount);
+ const armorValue = ignoreArmor ? 0 : (this.system.armor ?? 0);
+ const effective = Math.max(0, amount - armorValue);
+ if (effective === 0) return;
+ const newValue = Math.max(0, (this.system.life.value ?? 0) - effective);
+ return this.update({ "system.life.value": newValue });
+ }
+ }
+
+ applyHealing(amount) {
+ if (this.type === "character") {
+ return ActorCharacter.applyHealing(this, amount);
+ } else if (this.type === "creature") {
+ if (isNaN(amount) || amount === 0) return;
+ if (amount < 0) amount = Math.abs(amount);
+ const maxValue = this.system.life.max ?? 0;
+ const current = this.system.life.value ?? 0;
+ const newValue = Math.min(current + amount, maxValue);
+ if (newValue !== current) {
+ return this.update({ "system.life.value": newValue });
+ }
}
}
@@ -1605,24 +1688,42 @@ class MGT2Helper {
}
const { DialogV2: DialogV2$1 } = foundry.applications.api;
-const { renderTemplate: renderTemplate$2 } = foundry.applications.handlebars;
+const { renderTemplate: renderTemplate$3 } = foundry.applications.handlebars;
const { FormDataExtended: FormDataExtended$1 } = foundry.applications.ux;
class RollPromptHelper {
static async roll(options) {
- const htmlContent = await renderTemplate$2('systems/mgt2/templates/roll-prompt.html', {
- config: CONFIG.MGT2,
- characteristics: options.characteristics,
- characteristic: options.characteristic,
- skills: options.skills,
- skill: options.skill,
- fatigue: options.fatigue,
- encumbrance: options.encumbrance,
- difficulty: options.difficulty
- });
+ // Backward compat: allow (actor, options) or just (options)
+ if (options.rollTypeName || options.characteristics || options.skill !== undefined) ; else {
+ // Called with (actor, options)
+ options = arguments[1] || options;
+ }
- game.settings.get("mgt2", "theme");
+ const htmlContent = await renderTemplate$3('systems/mgt2/templates/roll-prompt.html', {
+ config: CONFIG.MGT2,
+ // Character-mode fields
+ characteristics: options.characteristics ?? [],
+ characteristic: options.characteristic ?? "",
+ skills: options.skills ?? [],
+ skill: options.skill ?? "",
+ fatigue: options.fatigue ?? false,
+ encumbrance: options.encumbrance ?? false,
+ difficulty: options.difficulty ?? "Average",
+ timeframe: options.timeframe ?? "Normal",
+ customDM: options.customDM ?? "0",
+ rollMode: options.rollMode ?? "publicroll",
+ // Creature-mode flags
+ isCreature: options.isCreature ?? false,
+ creatureSkills: options.creatureSkills ?? [],
+ selectedSkillIndex: options.selectedSkillIndex ?? -1,
+ showSkillSelector: options.showSkillSelector ?? false,
+ skillName: options.skillName ?? "",
+ skillLevel: options.skillLevel ?? 0,
+ // Healing fields
+ showHeal: options.showHeal ?? false,
+ healType: options.healType ?? null
+ });
return await DialogV2$1.wait({
window: { title: options.title ?? options.rollTypeName ?? game.i18n.localize("MGT2.RollPrompt.Roll") },
@@ -1663,11 +1764,11 @@ class RollPromptHelper {
}
const { DialogV2 } = foundry.applications.api;
-const { renderTemplate: renderTemplate$1 } = foundry.applications.handlebars;
+const { renderTemplate: renderTemplate$2 } = foundry.applications.handlebars;
const { FormDataExtended } = foundry.applications.ux;
async function _dialogWithForm(title, templatePath, templateData) {
- const htmlContent = await renderTemplate$1(templatePath, templateData);
+ const htmlContent = await renderTemplate$2(templatePath, templateData);
game.settings.get("mgt2", "theme");
return await DialogV2.wait({
window: { title },
@@ -1715,7 +1816,7 @@ class CharacterPrompts {
}
static async openEditorFullView(title, html) {
- const htmlContent = await renderTemplate$1("systems/mgt2/templates/editor-fullview.html", {
+ const htmlContent = await renderTemplate$2("systems/mgt2/templates/editor-fullview.html", {
config: CONFIG.MGT2,
html
});
@@ -1734,6 +1835,37 @@ class CharacterPrompts {
]
});
}
+
+ static async openHealingDays() {
+ return await DialogV2.wait({
+ window: {
+ title: game.i18n.localize("MGT2.Healing.Title")
+ },
+ classes: ["mgt2-roll-dialog"],
+ content: `
+
+ `,
+ rejectClose: false,
+ buttons: [
+ {
+ action: "submit",
+ label: game.i18n.localize("MGT2.Save"),
+ icon: '',
+ default: true,
+ callback: (event, button, dialog) => {
+ return new FormDataExtended(dialog.element.querySelector('form')).object;
+ }
+ }
+ ]
+ });
+ }
}
class TravellerCharacterSheet extends MGT2ActorSheet {
@@ -1765,6 +1897,7 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
traitEdit: TravellerCharacterSheet.#onTraitEdit,
traitDelete: TravellerCharacterSheet.#onTraitDelete,
openEditor: TravellerCharacterSheet.#onOpenEditor,
+ heal: TravellerCharacterSheet.#onHeal,
},
}
@@ -1786,7 +1919,11 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
async _prepareContext() {
const context = await super._prepareContext();
const actor = this.document;
+ const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? "", { async: true });
+ context.enrichedBiography = await enrich(actor.system.biography);
+ context.enrichedNotes = await enrich(actor.system.notes);
+ context.enrichedFinanceNotes = await enrich(actor.system.finance?.notes);
context.settings = {
weightUnit: "kg",
usePronouns: game.settings.get("mgt2", "usePronouns"),
@@ -1884,9 +2021,10 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
if (item.hasOwnProperty("equipped")) {
i._canEquip = true;
- i._toggleClass = item.equipped ? "active" : "";
+ i.toggleClass = item.equipped ? "active" : "";
} else {
i._canEquip = false;
+ i.toggleClass = "";
}
switch (i.type) {
@@ -2020,7 +2158,6 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
this._bindClassEvent(html, ".item-create", "click", TravellerCharacterSheet.#onCreateItem);
this._bindClassEvent(html, ".item-edit", "click", TravellerCharacterSheet.#onEditItem);
this._bindClassEvent(html, ".item-delete", "click", TravellerCharacterSheet.#onDeleteItem);
- this._bindClassEvent(html, ".item-equip", "click", TravellerCharacterSheet.#onEquipItem);
this._bindClassEvent(html, ".item-storage-in", "click", TravellerCharacterSheet.#onItemStorageIn);
this._bindClassEvent(html, ".item-storage-out", "click", TravellerCharacterSheet.#onItemStorageOut);
this._bindClassEvent(html, ".software-eject", "click", TravellerCharacterSheet.#onSoftwareEject);
@@ -2184,17 +2321,34 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
if (item) item.sheet.render(true);
}
+ static async #confirmDelete(name) {
+ return foundry.applications.api.DialogV2.confirm({
+ window: { title: game.i18n.localize("MGT2.Dialog.ConfirmDeleteTitle") },
+ content: `${game.i18n.format("MGT2.Dialog.ConfirmDeleteContent", { name })}
`,
+ yes: { label: game.i18n.localize("MGT2.Dialog.Yes"), icon: "fas fa-trash" },
+ no: { label: game.i18n.localize("MGT2.Dialog.No"), icon: "fas fa-times" },
+ rejectClose: false,
+ modal: true
+ });
+ }
+
static async #onDeleteItem(event, target) {
event.preventDefault();
const li = target.closest("[data-item-id]");
if (!li?.dataset.itemId) return;
+ const item = this.actor.items.get(li.dataset.itemId);
+ if (!item) return;
+ const confirmed = await TravellerCharacterSheet.#confirmDelete(item.name);
+ if (!confirmed) return;
this.actor.deleteEmbeddedDocuments("Item", [li.dataset.itemId]);
}
static async #onEquipItem(event, target) {
event.preventDefault();
const li = target.closest("[data-item-id]");
- const item = this.actor.getEmbeddedDocument("Item", li?.dataset.itemId);
+ const itemId = li?.dataset.itemId;
+ if (!itemId) return;
+ const item = this.actor.items.get(itemId);
if (!item) return;
await item.update({ "system.equipped": !item.system.equipped });
}
@@ -2262,6 +2416,9 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
const container = containers.find(x => x._id === this.actor.system.containerView);
if (!container) return;
+ const confirmed = await TravellerCharacterSheet.#confirmDelete(container.name);
+ if (!confirmed) return;
+
const containerItems = this.actor.items.filter(
x => x.system.hasOwnProperty("container") && x.system.container.id === container._id
);
@@ -2296,6 +2453,7 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
encumbrance: this.actor.system.states.encumbrance,
difficulty: null,
damageFormula: null,
+ isMelee: false,
};
const cardButtons = [];
@@ -2363,6 +2521,9 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
if (itemObj?.system.hasOwnProperty("damage")) {
rollOptions.damageFormula = itemObj.system.damage;
+ if (itemObj.type === "weapon") {
+ rollOptions.isMelee = itemObj.system.range?.isMelee === true;
+ }
if (itemObj.type === "disease") {
if (itemObj.system.subType === "disease")
rollOptions.rollTypeName = game.i18n.localize("MGT2.DiseaseSubType.disease");
@@ -2427,13 +2588,13 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
rollModifiers.push(game.i18n.localize("MGT2.Actor.Fatigue") + " -2");
}
- if (userRollData.customDM) {
- const s = userRollData.customDM.trim();
- if (/^[0-9]/.test(s)) rollFormulaParts.push("+");
- rollFormulaParts.push(s);
+ const customDMVal = parseInt(userRollData.customDM ?? "0", 10);
+ if (!isNaN(customDMVal) && customDMVal !== 0) {
+ rollFormulaParts.push(customDMVal > 0 ? `+${customDMVal}` : `${customDMVal}`);
+ rollModifiers.push(game.i18n.localize("MGT2.RollPrompt.CustomDM") + " " + (customDMVal > 0 ? `+${customDMVal}` : `${customDMVal}`));
}
- if (MGT2Helper.hasValue(userRollData, "difficulty")) rollOptions.difficulty = userRollData.difficulty;
+ if (MGT2Helper.hasValue(userRollData, "difficulty") && userRollData.difficulty !== "") rollOptions.difficulty = userRollData.difficulty;
const rollFormula = rollFormulaParts.join("");
if (!Roll.validate(rollFormula)) {
@@ -2447,37 +2608,74 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
await this.token.combatant.update({ initiative: roll.total });
}
+ // ── Compute effect and effective damage formula ──────────────────────
+ let rollSuccess = false;
+ let rollFailure = false;
+ let rollEffect = undefined;
+ let rollEffectStr = undefined;
+ let difficultyValue = null;
+
+ if (MGT2Helper.hasValue(rollOptions, "difficulty")) {
+ difficultyValue = MGT2Helper.getDifficultyValue(rollOptions.difficulty);
+ rollEffect = roll.total - difficultyValue;
+ rollEffectStr = (rollEffect >= 0 ? "+" : "") + rollEffect;
+ rollSuccess = rollEffect >= 0;
+ rollFailure = !rollSuccess;
+ }
+
+ // Build effective damage formula: base + effect + STR DM (melee)
+ let effectiveDamageFormula = rollOptions.damageFormula || null;
+ if (effectiveDamageFormula) {
+ if (rollEffect !== undefined && rollEffect !== 0) {
+ effectiveDamageFormula += (rollEffect >= 0 ? "+" : "") + rollEffect;
+ }
+ if (rollOptions.isMelee) {
+ const strDm = this.actor.system.characteristics.strength?.dm ?? 0;
+ if (strDm !== 0) effectiveDamageFormula += (strDm >= 0 ? "+" : "") + strDm;
+ }
+ }
+
+ // ── Build roll breakdown tooltip ─────────────────────────────────────
+ const diceRawTotal = roll.dice.reduce((s, d) => s + d.total, 0);
+ const breakdownParts = [game.i18n.localize("MGT2.Chat.Roll.Dice") + " " + diceRawTotal];
+ for (const mod of rollModifiers) breakdownParts.push(mod);
+ if (rollEffectStr !== undefined)
+ breakdownParts.push(game.i18n.localize("MGT2.Chat.Roll.Effect") + " " + rollEffectStr);
+ const rollBreakdown = breakdownParts.join(" | ");
+
const chatData = {
user: game.user.id,
speaker: this.actor ? ChatMessage.getSpeaker({ actor: this.actor }) : null,
formula: roll._formula,
tooltip: await roll.getTooltip(),
total: Math.round(roll.total * 100) / 100,
+ rollBreakdown,
showButtons: true,
showLifeButtons: false,
showRollRequest: false,
rollTypeName: rollOptions.rollTypeName,
rollObjectName: rollOptions.rollObjectName,
rollModifiers: rollModifiers,
- showRollDamage: rollOptions.damageFormula !== null && rollOptions.damageFormula !== "",
+ // Show damage button only if there's a formula AND (no difficulty check OR roll succeeded)
+ showRollDamage: !!effectiveDamageFormula && (!difficultyValue || rollSuccess),
cardButtons: cardButtons,
};
if (MGT2Helper.hasValue(rollOptions, "difficulty")) {
chatData.rollDifficulty = rollOptions.difficulty;
chatData.rollDifficultyLabel = MGT2Helper.getDifficultyDisplay(rollOptions.difficulty);
- if (roll.total >= MGT2Helper.getDifficultyValue(rollOptions.difficulty))
- chatData.rollSuccess = true;
- else
- chatData.rollFailure = true;
+ chatData.rollEffect = rollEffect;
+ chatData.rollEffectStr = rollEffectStr;
+ chatData.rollSuccess = rollSuccess || undefined;
+ chatData.rollFailure = rollFailure || undefined;
}
const html = await foundry.applications.handlebars.renderTemplate("systems/mgt2/templates/chat/roll.html", chatData);
chatData.content = html;
let flags = null;
- if (rollOptions.damageFormula) {
- flags = { mgt2: { damage: { formula: rollOptions.damageFormula, rollObjectName: rollOptions.rollObjectName, rollTypeName: rollOptions.rollTypeName } } };
+ if (effectiveDamageFormula) {
+ flags = { mgt2: { damage: { formula: effectiveDamageFormula, rollObjectName: rollOptions.rollObjectName, rollTypeName: rollOptions.rollTypeName } } };
}
if (cardButtons.length > 0) {
if (!flags) flags = { mgt2: {} };
@@ -2548,6 +2746,8 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
static async #onTraitDelete(event, target) {
event.preventDefault();
+ const confirmed = await TravellerCharacterSheet.#confirmDelete(game.i18n.localize("MGT2.Actor.ThisTrait"));
+ if (!confirmed) return;
const element = target.closest("[data-traits-part]");
const index = Number(element.dataset.traitsPart);
const traits = foundry.utils.deepClone(this.actor.system.personal.traits);
@@ -2564,6 +2764,325 @@ class TravellerCharacterSheet extends MGT2ActorSheet {
this.actor.system.personal.speciesText.descriptionLong
);
}
+
+ static async #onHeal(event, target) {
+ event.preventDefault();
+ const healType = target.dataset.healType;
+
+ if (canvas.tokens.controlled.length === 0) {
+ ui.notifications.warn(game.i18n.localize("MGT2.Errors.NoTokenSelected"));
+ return;
+ }
+
+ if (healType === "firstaid") {
+ // Find Medicine skill to pre-select
+ // Use normalized string matching to handle accents
+ const medSkill = this.actor.items.find(i => {
+ if (i.type !== "talent" || i.system.subType !== "skill") return false;
+ const normalized = i.name.toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g, "");
+ return normalized.includes("medecin") || normalized.includes("medicine");
+ });
+
+ // Only EDU characteristic available for First Aid
+ const characteristics = [
+ { _id: "education", name: game.i18n.localize("MGT2.Characteristics.education.name") }
+ ];
+
+ const rollOptions = {
+ rollTypeName: game.i18n.localize("MGT2.Healing.FirstAid"),
+ rollObjectName: this.actor.name,
+ characteristics: characteristics, // Only EDU
+ characteristic: "education", // Pre-selected
+ skill: medSkill?.id ?? "", // Medicine skill ID for pre-selection (must match _id in array)
+ skillName: medSkill?.name ?? game.i18n.localize("MGT2.Healing.NoMedicineSkill"), // Display name
+ skillLevel: medSkill?.system.level ?? -3, // -3 if not found
+ skills: medSkill ? [{ _id: medSkill.id, name: medSkill.name, level: medSkill.system.level }] : [],
+ difficulty: "Average", // First Aid difficulty is 8 (Average)
+ showHeal: true,
+ healType: MGT2.HealingType.FIRST_AID,
+ };
+ const userRollData = await RollPromptHelper.roll(rollOptions);
+ if (userRollData) {
+ // Build formula with all DMs — same pattern as standard skill roll
+ const rollFormulaParts = [];
+ const rollModifiers = [];
+
+ if (userRollData.diceModifier) {
+ rollFormulaParts.push("3d6");
+ rollFormulaParts.push(userRollData.diceModifier);
+ } else {
+ rollFormulaParts.push("2d6");
+ }
+
+ if (userRollData.characteristic) {
+ const c = this.actor.system.characteristics[userRollData.characteristic];
+ rollFormulaParts.push(MGT2Helper.getFormulaDM(c.dm));
+ rollModifiers.push(game.i18n.localize(`MGT2.Characteristics.${userRollData.characteristic}.name`) + MGT2Helper.getDisplayDM(c.dm));
+ }
+
+ if (userRollData.skill && userRollData.skill !== "") {
+ if (userRollData.skill === "NP") {
+ rollFormulaParts.push("-3");
+ rollModifiers.push(game.i18n.localize("MGT2.Items.NotProficient"));
+ } else {
+ const skillObj = this.actor.getEmbeddedDocument("Item", userRollData.skill);
+ rollFormulaParts.push(MGT2Helper.getFormulaDM(skillObj.system.level));
+ rollModifiers.push(skillObj.getRollDisplay());
+ }
+ }
+
+ if (userRollData.customDM && userRollData.customDM !== "") {
+ let s = userRollData.customDM.trim();
+ if (/^[0-9]/.test(s)) rollFormulaParts.push("+");
+ rollFormulaParts.push(s);
+ rollModifiers.push("DM " + s);
+ }
+
+ const rollFormula = rollFormulaParts.join("");
+ const roll = await new Roll(rollFormula, this.actor.getRollData()).roll();
+
+ // Difficulty for First Aid is Average (8)
+ const difficulty = 8;
+ const effect = roll.total - difficulty;
+ const isSuccess = effect >= 0;
+ const healing = isSuccess ? Math.max(1, effect) : 0;
+
+ const cardButtons = isSuccess
+ ? [{ label: game.i18n.localize("MGT2.Healing.ApplyHealing"), action: "healing" }]
+ : [];
+
+ const chatData = {
+ user: game.user.id,
+ speaker: ChatMessage.getSpeaker({ actor: this.actor }),
+ formula: roll._formula,
+ tooltip: await roll.getTooltip(),
+ total: Math.round(roll.total * 100) / 100,
+ rollTypeName: game.i18n.localize("MGT2.Healing.FirstAid"),
+ rollObjectName: this.actor.name,
+ rollModifiers: rollModifiers,
+ rollDifficulty: difficulty,
+ rollDifficultyLabel: MGT2Helper.getDifficultyDisplay("Average"),
+ rollEffectStr: isSuccess ? effect.toString() : undefined,
+ healingAmount: isSuccess ? healing : undefined,
+ rollSuccess: isSuccess || undefined,
+ rollFailure: !isSuccess || undefined,
+ showButtons: isSuccess,
+ hasDamage: false,
+ showRollDamage: false,
+ cardButtons: cardButtons,
+ };
+
+ const html = await foundry.applications.handlebars.renderTemplate("systems/mgt2/templates/chat/roll.html", chatData);
+ chatData.content = html;
+ chatData.flags = { mgt2: { healing: { amount: healing } } };
+
+ return roll.toMessage(chatData);
+ }
+ } else if (healType === "surgery") {
+ // Find Medicine skill to pre-select (same as first aid)
+ const medSkill = this.actor.items.find(i => {
+ if (i.type !== "talent" || i.system.subType !== "skill") return false;
+ const normalized = i.name.toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g, "");
+ return normalized.includes("medecin") || normalized.includes("medicine");
+ });
+
+ const characteristics = [
+ { _id: "education", name: game.i18n.localize("MGT2.Characteristics.education.name") }
+ ];
+
+ const rollOptions = {
+ rollTypeName: game.i18n.localize("MGT2.Healing.Surgery"),
+ rollObjectName: this.actor.name,
+ characteristics: characteristics,
+ characteristic: "education",
+ skill: medSkill?.id ?? "",
+ skillName: medSkill?.name ?? game.i18n.localize("MGT2.Healing.NoMedicineSkill"),
+ skillLevel: medSkill?.system.level ?? -3,
+ skills: medSkill ? [{ _id: medSkill.id, name: medSkill.name, level: medSkill.system.level }] : [],
+ difficulty: "Average",
+ showHeal: true,
+ healType: MGT2.HealingType.SURGERY,
+ };
+ const userRollData = await RollPromptHelper.roll(rollOptions);
+ if (userRollData) {
+ // Build formula with all DMs — same pattern as standard skill roll
+ const rollFormulaParts = [];
+ const rollModifiers = [];
+
+ if (userRollData.diceModifier) {
+ rollFormulaParts.push("3d6");
+ rollFormulaParts.push(userRollData.diceModifier);
+ } else {
+ rollFormulaParts.push("2d6");
+ }
+
+ if (userRollData.characteristic) {
+ const c = this.actor.system.characteristics[userRollData.characteristic];
+ rollFormulaParts.push(MGT2Helper.getFormulaDM(c.dm));
+ rollModifiers.push(game.i18n.localize(`MGT2.Characteristics.${userRollData.characteristic}.name`) + MGT2Helper.getDisplayDM(c.dm));
+ }
+
+ if (userRollData.skill && userRollData.skill !== "") {
+ if (userRollData.skill === "NP") {
+ rollFormulaParts.push("-3");
+ rollModifiers.push(game.i18n.localize("MGT2.Items.NotProficient"));
+ } else {
+ const skillObj = this.actor.getEmbeddedDocument("Item", userRollData.skill);
+ rollFormulaParts.push(MGT2Helper.getFormulaDM(skillObj.system.level));
+ rollModifiers.push(skillObj.getRollDisplay());
+ }
+ }
+
+ if (userRollData.customDM && userRollData.customDM !== "") {
+ let s = userRollData.customDM.trim();
+ if (/^[0-9]/.test(s)) rollFormulaParts.push("+");
+ rollFormulaParts.push(s);
+ rollModifiers.push("DM " + s);
+ }
+
+ const rollFormula = rollFormulaParts.join("");
+ const roll = await new Roll(rollFormula, this.actor.getRollData()).roll();
+
+ // Difficulty for Surgery is Average (8)
+ const difficulty = 8;
+ const effect = roll.total - difficulty;
+ const isSuccess = effect >= 0;
+
+ // Success: heal Math.max(1, effect); Failure: patient takes 3 + |effect| damage
+ const healing = isSuccess ? Math.max(1, effect) : 0;
+ const surgeryDamage = isSuccess ? 0 : 3 + Math.abs(effect);
+
+ const cardButtons = [];
+ if (isSuccess) {
+ cardButtons.push({ label: game.i18n.localize("MGT2.Healing.ApplyHealing"), action: "healing" });
+ } else {
+ cardButtons.push({ label: game.i18n.localize("MGT2.Healing.ApplySurgeryDamage"), action: "surgeryDamage" });
+ }
+
+ const chatData = {
+ user: game.user.id,
+ speaker: ChatMessage.getSpeaker({ actor: this.actor }),
+ formula: roll._formula,
+ tooltip: await roll.getTooltip(),
+ total: Math.round(roll.total * 100) / 100,
+ rollTypeName: game.i18n.localize("MGT2.Healing.Surgery"),
+ rollObjectName: this.actor.name,
+ rollModifiers: rollModifiers,
+ rollDifficulty: difficulty,
+ rollDifficultyLabel: MGT2Helper.getDifficultyDisplay("Average"),
+ rollEffectStr: effect.toString(),
+ healingAmount: isSuccess ? healing : undefined,
+ surgeryDamageAmount: isSuccess ? undefined : surgeryDamage,
+ rollSuccess: isSuccess || undefined,
+ rollFailure: !isSuccess || undefined,
+ showButtons: true,
+ hasDamage: false,
+ showRollDamage: false,
+ cardButtons: cardButtons,
+ };
+
+ const html = await foundry.applications.handlebars.renderTemplate("systems/mgt2/templates/chat/roll.html", chatData);
+ chatData.content = html;
+ chatData.flags = { mgt2: { surgery: { healing, surgeryDamage } } };
+
+ return roll.toMessage(chatData);
+ }
+ } else if (healType === "medical") {
+ const result = await CharacterPrompts.openHealingDays();
+ if (result) {
+ const endMD = this.actor.system.characteristics.endurance.dm;
+ const medSkill = this.actor.items.find(i =>
+ i.type === "talent" &&
+ i.system.subType === "skill" &&
+ (i.name.toLowerCase().includes("medecin") || i.name.toLowerCase().includes("medicine"))
+ );
+ const skillValue = medSkill ? medSkill.system.level : 0;
+ const days = result.days;
+ const healingPerDay = Math.max(1, 3 + endMD + skillValue);
+ const totalHealing = healingPerDay * days;
+
+ const rollModifiers = [
+ `3 (base)`,
+ `${endMD >= 0 ? "+" : ""}${endMD} END`,
+ `+${skillValue} ${medSkill?.name ?? "Médecine"}`,
+ `× ${days} ${game.i18n.localize("MGT2.RollPrompt.Days").toLowerCase()}`
+ ];
+
+ const templateData = {
+ rollObjectName: this.actor.name,
+ rollTypeName: game.i18n.localize("MGT2.Healing.MedicalCare"),
+ rollModifiers,
+ formula: `${healingPerDay} ${game.i18n.localize("MGT2.Items.PerDay")}`,
+ tooltip: "",
+ total: totalHealing,
+ rollSuccess: true,
+ showButtons: true,
+ cardButtons: [
+ { action: "healing", label: game.i18n.localize("MGT2.Healing.ApplyHealing") }
+ ]
+ };
+
+ const content = await renderTemplate(
+ "systems/mgt2/templates/chat/roll.html",
+ templateData
+ );
+ await ChatMessage.create({
+ user: game.user.id,
+ speaker: ChatMessage.getSpeaker({ actor: this.actor }),
+ content,
+ flags: { mgt2: { healing: { amount: totalHealing } } }
+ });
+ }
+ } else if (healType === "natural") {
+ const result = await CharacterPrompts.openHealingDays();
+ if (result) {
+ const endMD = this.actor.system.characteristics.endurance.dm;
+ let totalAmount = 0;
+ const rolls = [];
+
+ for (let i = 0; i < result.days; i++) {
+ const roll = await new Roll("1d6").evaluate();
+ const dayHealing = Math.max(1, roll.total + endMD);
+ rolls.push({ roll, dayHealing });
+ totalAmount += dayHealing;
+ }
+
+ // Build roll details
+ const rollDisplay = rolls.map((r, idx) =>
+ `${game.i18n.localize("MGT2.RollPrompt.Days")} ${idx + 1}: 1d6 = ${r.roll.total} + ${endMD > 0 ? "+" : ""}${endMD} = ${r.dayHealing}
`
+ ).join("");
+
+ const chatData = {
+ user: game.user.id,
+ speaker: ChatMessage.getSpeaker({ actor: this.actor }),
+ content: `
+
+
${result.days} ${game.i18n.localize("MGT2.RollPrompt.Days")}
+
+ ${rollDisplay}
+
+
+ ${game.i18n.localize("MGT2.Chat.Roll.Effect")} ${totalAmount}
+
+
`,
+ flags: { mgt2: { healing: { amount: totalAmount } } }
+ };
+ await ChatMessage.create(chatData);
+
+ // Apply healing immediately
+ await this.actor.applyHealing(totalAmount);
+ ui.notifications.info(
+ game.i18n.format("MGT2.Notifications.HealingApplied",
+ { name: this.actor.name, amount: totalAmount })
+ );
+ }
+ }
+ }
}
class TravellerVehiculeSheet extends MGT2ActorSheet {
@@ -2587,8 +3106,21 @@ class TravellerVehiculeSheet extends MGT2ActorSheet {
/** @override */
tabGroups = { primary: "stats" }
+
+ /** @override */
+ async _prepareContext() {
+ const context = await super._prepareContext();
+ const actor = this.document;
+ const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? "", { async: true });
+
+ context.enrichedDescription = await enrich(actor.system.description);
+ context.enrichedNotes = await enrich(actor.system.notes);
+ return context;
+ }
}
+const { renderTemplate: renderTemplate$1 } = foundry.applications.handlebars;
+
/** Convert Traveller dice notation (e.g. "2D", "4D+2", "3D6") to FoundryVTT formula */
function normalizeDice(formula) {
if (!formula) return "1d6";
@@ -2635,13 +3167,16 @@ class TravellerCreatureSheet extends MGT2ActorSheet {
}
/** @override */
- tabGroups = { primary: "skills" }
+ tabGroups = { primary: "combat" }
/** @override */
async _prepareContext() {
const context = await super._prepareContext();
const actor = this.document;
+ const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? "", { async: true });
+ context.enrichedBiography = await enrich(actor.system.biography);
+ context.enrichedNotes = await enrich(actor.system.notes);
context.sizeLabel = this._getSizeLabel(actor.system.life.max);
context.sizeTraitLabel = this._getSizeTrait(actor.system.life.max);
context.config = CONFIG.MGT2;
@@ -2677,105 +3212,40 @@ class TravellerCreatureSheet extends MGT2ActorSheet {
return "Grand (+6)";
}
- // ───────────────────────────────────────────────────────── Roll Handlers
+ // ───────────────────────────────────────────────────────── Roll Helpers
- /** Roll an attack (damage) with optional difficulty dialog */
- static async #onRollAttack(event, target) {
- const index = parseInt(target.dataset.index ?? 0);
- const actor = this.document;
- const attack = actor.system.attacks[index];
- if (!attack) return;
+ static async #postCreatureRoll({ actor, roll, rollLabel, dm, difficulty, difficultyLabel, rollMode, extraTooltip }) {
+ const diffTarget = MGT2Helper.getDifficultyValue(difficulty ?? "Average");
+ const hasDifficulty = !!difficulty;
+ const success = hasDifficulty ? roll.total >= diffTarget : true;
+ const effect = roll.total - diffTarget;
+ const effectStr = (effect >= 0 ? "+" : "") + effect;
- const rollFormula = normalizeDice(attack.damage);
-
- const roll = await new Roll(rollFormula).evaluate();
- roll.total;
-
- await roll.toMessage({
- speaker: ChatMessage.getSpeaker({ actor }),
- flavor: `${actor.name} — ${attack.name}`,
- rollMode: game.settings.get("core", "rollMode"),
- });
- }
-
- /** Roll a skill check (2d6 + level vs difficulty) */
- static async #onRollSkill(event, target) {
- const index = parseInt(target.dataset.index ?? 0);
- const actor = this.document;
- const skill = actor.system.skills[index];
- if (!skill) return;
-
- const htmlContent = await renderTemplate(
- "systems/mgt2/templates/actors/creature-roll-prompt.html",
- {
- skillName: skill.name,
- skillLevel: skill.level,
- config: CONFIG.MGT2
- }
- );
-
- const result = await foundry.applications.api.DialogV2.wait({
- window: { title: game.i18n.localize("MGT2.Creature.RollSkill") + " — " + skill.name },
- content: htmlContent,
- rejectClose: false,
- buttons: [
- {
- action: "boon",
- label: game.i18n.localize("MGT2.RollPrompt.Boon"),
- callback: (event, button, dialog) => {
- const fd = new foundry.applications.ux.FormDataExtended(dialog.element.querySelector("form")).object;
- fd.diceModifier = "dl";
- return fd;
- }
- },
- {
- action: "roll",
- label: game.i18n.localize("MGT2.RollPrompt.Roll"),
- icon: '',
- default: true,
- callback: (event, button, dialog) =>
- new foundry.applications.ux.FormDataExtended(dialog.element.querySelector("form")).object
- },
- {
- action: "bane",
- label: game.i18n.localize("MGT2.RollPrompt.Bane"),
- callback: (event, button, dialog) => {
- const fd = new foundry.applications.ux.FormDataExtended(dialog.element.querySelector("form")).object;
- fd.diceModifier = "dh";
- return fd;
- }
- }
- ]
- });
-
- if (!result) return;
-
- const dm = parseInt(result.dm ?? 0) + (skill.level ?? 0);
- const modifier = result.diceModifier ?? "";
- const difficultyTarget = parseInt(result.difficulty ?? 8);
- const difficultyLabel = result.difficultyLabel ?? "";
-
- const diceFormula = modifier ? `3d6${modifier}` : "2d6";
- const fullFormula = dm !== 0 ? `${diceFormula} + ${dm}` : diceFormula;
-
- const roll = await new Roll(fullFormula).evaluate();
- const success = roll.total >= difficultyTarget;
+ const diceRawTotal = roll.dice.reduce((s, d) => s + d.total, 0);
+ const breakdownParts = [game.i18n.localize("MGT2.Chat.Roll.Dice") + " " + diceRawTotal];
+ if (dm !== 0) breakdownParts.push(`DM ${dm >= 0 ? "+" : ""}${dm}`);
+ if (hasDifficulty) breakdownParts.push(game.i18n.localize("MGT2.Chat.Roll.Effect") + " " + effectStr);
+ if (extraTooltip) breakdownParts.push(extraTooltip);
+ const rollBreakdown = breakdownParts.join(" | ");
const chatData = {
creatureName: actor.name,
creatureImg: actor.img,
- rollLabel: skill.name.toUpperCase(),
- formula: fullFormula,
+ rollLabel,
+ formula: roll.formula,
total: roll.total,
tooltip: await roll.getTooltip(),
- difficulty: difficultyTarget,
- difficultyLabel,
- success,
- failure: !success,
+ rollBreakdown,
+ difficulty: hasDifficulty ? diffTarget : null,
+ difficultyLabel: difficultyLabel ?? MGT2Helper.getDifficultyDisplay(difficulty),
+ success: hasDifficulty ? success : null,
+ failure: hasDifficulty ? !success : null,
+ effect: hasDifficulty ? effect : null,
+ effectStr: hasDifficulty ? effectStr : null,
modifiers: dm !== 0 ? [`DM ${dm >= 0 ? "+" : ""}${dm}`] : [],
};
- const chatContent = await renderTemplate(
+ const chatContent = await renderTemplate$1(
"systems/mgt2/templates/chat/creature-roll.html",
chatData
);
@@ -2784,8 +3254,125 @@ class TravellerCreatureSheet extends MGT2ActorSheet {
content: chatContent,
speaker: ChatMessage.getSpeaker({ actor }),
rolls: [roll],
- rollMode: game.settings.get("core", "rollMode"),
+ rollMode: rollMode ?? game.settings.get("core", "rollMode"),
});
+
+ return { success, effect, total: roll.total };
+ }
+
+ // ───────────────────────────────────────────────────────── Roll Handlers
+
+ /** Roll a skill check (2d6 + level vs difficulty) — uses unified dialog */
+ static async #onRollSkill(event, target) {
+ const index = parseInt(target.dataset.index ?? 0);
+ const actor = this.document;
+ const skill = actor.system.skills[index];
+ if (!skill) return;
+
+ const result = await RollPromptHelper.roll({
+ isCreature: true,
+ showSkillSelector: false,
+ skillName: skill.name,
+ skillLevel: skill.level,
+ difficulty: "Average",
+ title: game.i18n.localize("MGT2.Creature.RollSkill") + " — " + skill.name,
+ });
+ if (!result) return;
+
+ const customDM = parseInt(result.customDM ?? "0", 10) || 0;
+ const skillLevel = parseInt(skill.level ?? 0, 10) || 0;
+ const dm = skillLevel + customDM;
+ const diceModifier = result.diceModifier ?? "";
+
+ // Build formula exactly like character-sheet: parts joined without spaces
+ const parts = [];
+ if (diceModifier) {
+ parts.push("3d6", diceModifier);
+ } else {
+ parts.push("2d6");
+ }
+ if (dm !== 0) parts.push(MGT2Helper.getFormulaDM(dm));
+ const fullFormula = parts.join("");
+
+ const roll = await new Roll(fullFormula).evaluate();
+ const rollLabel = `${skill.name.toUpperCase()} (${skillLevel >= 0 ? "+" : ""}${skillLevel})`;
+
+ const tooltipParts = [`Dés: ${roll.dice.reduce((s, d) => s + d.total, 0)}`];
+ if (skillLevel !== 0) tooltipParts.push(`${skill.name} ${skillLevel >= 0 ? "+" : ""}${skillLevel}`);
+ if (customDM !== 0) tooltipParts.push(`MD perso ${customDM >= 0 ? "+" : ""}${customDM}`);
+
+ await TravellerCreatureSheet.#postCreatureRoll({
+ actor, roll, rollLabel,
+ dm,
+ difficulty: result.difficulty,
+ rollMode: result.rollMode,
+ extraTooltip: tooltipParts.join(" | "),
+ });
+ }
+
+ /** Roll an attack: dialog with skill selector, then roll 2d6+skill+DM vs difficulty; on success roll damage */
+ static async #onRollAttack(event, target) {
+ const index = parseInt(target.dataset.index ?? 0);
+ const actor = this.document;
+ const attack = actor.system.attacks[index];
+ if (!attack) return;
+
+ const skills = actor.system.skills ?? [];
+
+ const result = await RollPromptHelper.roll({
+ isCreature: true,
+ showSkillSelector: true,
+ creatureSkills: skills,
+ selectedSkillIndex: attack.skill ?? -1,
+ difficulty: "Average",
+ title: game.i18n.localize("MGT2.Creature.RollAttack") + " — " + attack.name,
+ });
+ if (!result) return;
+
+ const skillIndex = parseInt(result.creatureSkillIndex ?? "-1", 10);
+ const chosenSkill = (skillIndex >= 0 && skillIndex < skills.length) ? skills[skillIndex] : null;
+ const skillLevel = parseInt(chosenSkill?.level ?? 0, 10) || 0;
+ const customDM = parseInt(result.customDM ?? "0", 10) || 0;
+ const dm = skillLevel + customDM;
+ const diceModifier = result.diceModifier ?? "";
+
+ // Build formula exactly like character-sheet: parts joined without spaces
+ const parts = [];
+ if (diceModifier) {
+ parts.push("3d6", diceModifier);
+ } else {
+ parts.push("2d6");
+ }
+ if (dm !== 0) parts.push(MGT2Helper.getFormulaDM(dm));
+ const fullFormula = parts.join("");
+
+ const roll = await new Roll(fullFormula).evaluate();
+ const rollLabel = chosenSkill
+ ? `${attack.name} — ${chosenSkill.name} (${skillLevel >= 0 ? "+" : ""}${skillLevel})`
+ : attack.name;
+
+ const tooltipParts = [`Dés: ${roll.dice.reduce((s, d) => s + d.total, 0)}`];
+ if (chosenSkill) tooltipParts.push(`${chosenSkill.name} ${skillLevel >= 0 ? "+" : ""}${skillLevel}`);
+ if (customDM !== 0) tooltipParts.push(`MD perso ${customDM >= 0 ? "+" : ""}${customDM}`);
+
+ const { success } = await TravellerCreatureSheet.#postCreatureRoll({
+ actor, roll, rollLabel,
+ dm,
+ difficulty: result.difficulty,
+ rollMode: result.rollMode,
+ extraTooltip: tooltipParts.join(" | "),
+ });
+
+ // Roll damage only on success
+ if (success && attack.damage) {
+ const dmgFormula = normalizeDice(attack.damage);
+ const dmgRoll = await new Roll(dmgFormula).evaluate();
+ await dmgRoll.toMessage({
+ speaker: ChatMessage.getSpeaker({ actor }),
+ flavor: `${actor.name} — ${game.i18n.localize("MGT2.Chat.Weapon.Damage")}: ${attack.name} (${attack.damage})`,
+ rollMode: result.rollMode ?? game.settings.get("core", "rollMode"),
+ });
+ }
}
// ───────────────────────────────────────────────────────── CRUD Handlers
@@ -2812,7 +3399,7 @@ class TravellerCreatureSheet extends MGT2ActorSheet {
_getDefaultRow(prop) {
switch (prop) {
case "skills": return { name: "", level: 0, note: "" };
- case "attacks": return { name: "", damage: "1D", description: "" };
+ case "attacks": return { name: "", damage: "1D", skill: -1, description: "" };
case "traits": return { name: "", value: "", description: "" };
default: return {};
}
@@ -2893,6 +3480,8 @@ class TravellerItemSheet extends HandlebarsApplicationMixin(foundry.applications
skills.sort(MGT2Helper.compareByName);
skills = [{ _id: "NP", name: game.i18n.localize("MGT2.Items.NotProficient") }].concat(skills);
+ const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? "", { async: true });
+
return {
item: item,
document: item,
@@ -2911,6 +3500,10 @@ class TravellerItemSheet extends HandlebarsApplicationMixin(foundry.applications
weight: weight,
unitlabels: { weight: MGT2Helper.getWeightLabel() },
skills: skills,
+ enrichedDescription: await enrich(item.system.description),
+ enrichedDescriptionLong: await enrich(item.system.descriptionLong),
+ enrichedNotes: await enrich(item.system.notes),
+ enrichedLockedDescription: await enrich(item.system.lockedDescription),
};
}
@@ -2946,6 +3539,27 @@ class TravellerItemSheet extends HandlebarsApplicationMixin(foundry.applications
bind(".options-delete", TravellerItemSheet.#onOptionDelete);
bind(".modifiers-create", TravellerItemSheet.#onModifierCreate);
bind(".modifiers-delete", TravellerItemSheet.#onModifierDelete);
+
+ // Activate ProseMirror editors for HTMLField fields
+ for (const btn of html.querySelectorAll(".editor-edit")) {
+ btn.addEventListener("click", async (event) => {
+ event.preventDefault();
+ const editorWrapper = btn.closest(".editor");
+ if (!editorWrapper) return;
+ const editorContent = editorWrapper.querySelector(".editor-content");
+ if (!editorContent || editorContent.classList.contains("ProseMirror")) return;
+ const target = editorContent.dataset.edit;
+ const value = foundry.utils.getProperty(this.document, target) ?? "";
+ btn.remove();
+ editorWrapper.classList.add("prosemirror");
+ await ProseMirrorEditor.create(editorContent, value, {
+ document: this.document,
+ fieldName: target,
+ plugins: {},
+ collaborate: false,
+ });
+ });
+ }
}
_activateTabGroups() {
@@ -3098,6 +3712,7 @@ const preloadHandlebarsTemplates = async function() {
"systems/mgt2/templates/items/weapon-sheet.html",
"systems/mgt2/templates/items/parts/sheet-configuration.html",
"systems/mgt2/templates/items/parts/sheet-physical-item.html",
+ "systems/mgt2/templates/items/parts/sheet-physical-item-tab.html",
"systems/mgt2/templates/roll-prompt.html",
"systems/mgt2/templates/chat/roll.html",
//"systems/mgt2/templates/chat/roll-characteristic.html",
@@ -3105,12 +3720,12 @@ const preloadHandlebarsTemplates = async function() {
"systems/mgt2/templates/actors/actor-config-characteristic-sheet.html",
"systems/mgt2/templates/actors/trait-sheet.html",
"systems/mgt2/templates/actors/creature-sheet.html",
- "systems/mgt2/templates/actors/creature-roll-prompt.html",
"systems/mgt2/templates/chat/creature-roll.html",
"systems/mgt2/templates/editor-fullview.html"
];
- return loadTemplates(templatePaths);
+ const loader = foundry.applications?.handlebars?.loadTemplates ?? loadTemplates;
+ return loader(templatePaths);
};
class ChatHelper {
@@ -3133,11 +3748,17 @@ class ChatHelper {
element.querySelectorAll('button[data-action="healing"]').forEach(el => {
el.addEventListener('click', async event => {
- ui.notifications.warn("healing");
+ await this._applyChatCardHealing(message, event);
});
});
- element.querySelectorAll('button[data-index]').forEach(el => {
+ element.querySelectorAll('button[data-action="surgeryDamage"]').forEach(el => {
+ el.addEventListener('click', async event => {
+ await this._applyChatCardSurgeryDamage(message, event);
+ });
+ });
+
+ element.querySelectorAll('button[data-index]:not([data-action])').forEach(el => {
el.addEventListener('click', async event => {
await this._processRollButtonEvent(message, event);
});
@@ -3203,12 +3824,43 @@ class ChatHelper {
}
static _applyChatCardDamage(message, event) {
+ if (canvas.tokens.controlled.length === 0) {
+ ui.notifications.warn(game.i18n.localize("MGT2.Errors.NoTokenSelected"));
+ return;
+ }
const roll = message.rolls[0];
return Promise.all(canvas.tokens.controlled.map(t => {
const a = t.actor;
return a.applyDamage(roll.total);
}));
}
+
+ static _applyChatCardHealing(message, event) {
+ if (canvas.tokens.controlled.length === 0) {
+ ui.notifications.warn(game.i18n.localize("MGT2.Errors.NoTokenSelected"));
+ return;
+ }
+ // For First Aid/Surgery healing, use amount from flags; otherwise use roll total
+ const amount = message.flags?.mgt2?.healing?.amount
+ ?? message.flags?.mgt2?.surgery?.healing
+ ?? Math.max(1, message.rolls[0].total);
+ return Promise.all(canvas.tokens.controlled.map(t => {
+ const a = t.actor;
+ return a.applyHealing(amount);
+ }));
+ }
+
+ static _applyChatCardSurgeryDamage(message, event) {
+ if (canvas.tokens.controlled.length === 0) {
+ ui.notifications.warn(game.i18n.localize("MGT2.Errors.NoTokenSelected"));
+ return;
+ }
+ const amount = message.flags?.mgt2?.surgery?.surgeryDamage ?? 3;
+ return Promise.all(canvas.tokens.controlled.map(t => {
+ const a = t.actor;
+ return a.applyDamage(amount, { ignoreArmor: true });
+ }));
+ }
}
const registerSettings = function () {
diff --git a/mgt2.bundle.js.map b/mgt2.bundle.js.map
index 89d4b1a..a7d76aa 100644
--- a/mgt2.bundle.js.map
+++ b/mgt2.bundle.js.map
@@ -1 +1 @@
-{"version":3,"file":"mgt2.bundle.js","sources":["src/module/models/items/base-item.mjs","src/module/models/character.mjs","src/module/models/vehicule.mjs","src/module/models/creature.mjs","src/module/models/items/item.mjs","src/module/models/items/equipment.mjs","src/module/models/items/disease.mjs","src/module/models/items/career.mjs","src/module/models/items/talent.mjs","src/module/models/items/contact.mjs","src/module/models/items/weapon.mjs","src/module/models/items/armor.mjs","src/module/models/items/computer.mjs","src/module/models/items/container.mjs","src/module/models/items/species.mjs","src/module/config.js","src/module/actors/character.js","src/module/actors/actor.js","src/module/item.js","src/module/applications/sheets/base-actor-sheet.mjs","src/module/helper.js","src/module/roll-prompt.js","src/module/actors/character-prompts.js","src/module/applications/sheets/character-sheet.mjs","src/module/applications/sheets/vehicule-sheet.mjs","src/module/applications/sheets/creature-sheet.mjs","src/module/applications/sheets/item-sheet.mjs","src/module/templates.js","src/module/chatHelper.js","src/module/settings.js","src/module/core.js"],"sourcesContent":["const fields = foundry.data.fields;\n\nexport function createCharacteristicField(show = true, showMax = false) {\n return new fields.SchemaField({\n value: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n max: new fields.NumberField({ required: false, initial: 0, min: 0, integer: true }),\n dm: new fields.NumberField({ required: false, initial: 0, integer: true }),\n show: new fields.BooleanField({ required: false, initial: show }),\n showMax: new fields.BooleanField({ required: false, initial: showMax })\n });\n}\n\nexport class ItemBaseData extends foundry.abstract.TypeDataModel {\n static defineSchema() {\n return {\n description: new fields.StringField({ required: false, blank: true, trim: true, nullable: true }),\n subType: new fields.StringField({ required: false, blank: false, nullable: true })\n };\n }\n}\n\nexport class PhysicalItemData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.quantity = new fields.NumberField({ required: true, initial: 1, min: 0, integer: true });\n schema.weight = new fields.NumberField({ required: true, initial: 0, min: 0, integer: false });\n schema.weightless = new fields.BooleanField({ required: false, initial: false });\n schema.cost = new fields.NumberField({ required: true, initial: 0, min: 0, integer: true });\n schema.tl = new fields.StringField({ required: true, blank: false, initial: \"TL12\" });\n schema.container = new fields.SchemaField({\n id: new fields.StringField({ required: false, blank: true })\n });\n schema.roll = new fields.SchemaField({\n characteristic: new fields.StringField({ required: false, blank: true, trim: true }),\n skill: new fields.StringField({ required: false, blank: true, trim: true }),\n difficulty: new fields.StringField({ required: false, blank: true, trim: true })\n });\n schema.trash = new fields.BooleanField({ required: false, initial: false });\n return schema;\n }\n}\n","import { createCharacteristicField } from \"./items/base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class CharacterData extends foundry.abstract.TypeDataModel {\n\n static defineSchema() {\n return {\n name: new fields.StringField({ required: false, blank: false, trim: true }),\n life: new fields.SchemaField({\n value: new fields.NumberField({ required: false, initial: 0, integer: true }),\n max: new fields.NumberField({ required: true, initial: 0, integer: true })\n }),\n personal: new fields.SchemaField({\n title: new fields.StringField({ required: false, blank: true, trim: true }),\n species: new fields.StringField({ required: false, blank: true, trim: true }),\n speciesText: new fields.SchemaField({\n description: new fields.StringField({ required: false, blank: true, trim: true, nullable: true }),\n descriptionLong: new fields.HTMLField({ required: false, blank: true, trim: true })\n }),\n age: new fields.StringField({ required: false, blank: true, trim: true }),\n gender: new fields.StringField({ required: false, blank: true, trim: true }),\n pronouns: new fields.StringField({ required: false, blank: true, trim: true }),\n homeworld: new fields.StringField({ required: false, blank: true, trim: true }),\n ucp: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n traits: new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n )\n }),\n biography: new fields.HTMLField({ required: false, blank: true, trim: true }),\n\n characteristics: new fields.SchemaField({\n strength: createCharacteristicField(true, true),\n dexterity: createCharacteristicField(true, true),\n endurance: createCharacteristicField(true, true),\n intellect: createCharacteristicField(true, false),\n education: createCharacteristicField(true, false),\n social: createCharacteristicField(true, false),\n morale: createCharacteristicField(true, false),\n luck: createCharacteristicField(true, false),\n sanity: createCharacteristicField(true, false),\n charm: createCharacteristicField(true, false),\n psionic: createCharacteristicField(true, false),\n other: createCharacteristicField(true, false)\n }),\n\n health: new fields.SchemaField({\n radiations: new fields.NumberField({ required: false, initial: 0, min: 0, integer: true })\n }),\n study: new fields.SchemaField({\n skill: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n total: new fields.NumberField({ required: false, initial: 0, min: 0, integer: true }),\n completed: new fields.NumberField({ required: false, initial: 0, min: 0, integer: true })\n }),\n finance: new fields.SchemaField({\n pension: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n credits: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n cashOnHand: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n debt: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n livingCost: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n monthlyShipPayments: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n notes: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" })\n }),\n containerView: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n containerDropIn: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n notes: new fields.HTMLField({ required: false, blank: true, trim: true }),\n\n inventory: new fields.SchemaField({\n armor: new fields.NumberField({ required: true, initial: 0, integer: true }),\n weight: new fields.NumberField({ required: true, initial: 0, min: 0, integer: false }),\n encumbrance: new fields.SchemaField({\n normal: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n heavy: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true })\n })\n }),\n states: new fields.SchemaField({\n encumbrance: new fields.BooleanField({ required: false, initial: false }),\n fatigue: new fields.BooleanField({ required: false, initial: false }),\n unconscious: new fields.BooleanField({ required: false, initial: false }),\n surgeryRequired: new fields.BooleanField({ required: false, initial: false })\n }),\n\n config: new fields.SchemaField({\n psionic: new fields.BooleanField({ required: false, initial: true }),\n initiative: new fields.StringField({ required: false, blank: true, initial: \"dexterity\" }),\n damages: new fields.SchemaField({\n rank1: new fields.StringField({ required: false, blank: true, initial: \"strength\" }),\n rank2: new fields.StringField({ required: false, blank: true, initial: \"dexterity\" }),\n rank3: new fields.StringField({ required: false, blank: true, initial: \"endurance\" })\n })\n })\n };\n }\n}\n","const fields = foundry.data.fields;\n\nexport default class VehiculeData extends foundry.abstract.TypeDataModel {\n\n static defineSchema() {\n return {\n name: new fields.StringField({ required: false, blank: false, trim: true }),\n skillId: new fields.StringField({ required: false, initial: \"\", blank: true, trim: true }),\n speed: new fields.SchemaField({\n cruise: new fields.StringField({ required: false, initial: \"Slow\", blank: true }),\n maximum: new fields.StringField({ required: false, initial: \"Medium\", blank: true })\n }),\n agility: new fields.NumberField({ required: false, min: 0, integer: true }),\n crew: new fields.NumberField({ required: false, min: 0, integer: true }),\n passengers: new fields.NumberField({ required: false, min: 0, integer: true }),\n cargo: new fields.NumberField({ required: false, min: 0, integer: false }),\n life: new fields.SchemaField({\n value: new fields.NumberField({ required: true, initial: 0, integer: true }),\n max: new fields.NumberField({ required: true, initial: 0, integer: true })\n }),\n shipping: new fields.NumberField({ required: false, min: 0, integer: true }),\n cost: new fields.NumberField({ required: false, min: 0, integer: true }),\n armor: new fields.SchemaField({\n front: new fields.NumberField({ required: true, initial: 0, integer: true }),\n rear: new fields.NumberField({ required: true, initial: 0, integer: true }),\n sides: new fields.NumberField({ required: true, initial: 0, integer: true })\n }),\n skills: new fields.SchemaField({\n autopilot: new fields.NumberField({ required: true, initial: 0, integer: true })\n })\n };\n }\n}\n","const fields = foundry.data.fields;\n\nexport default class CreatureData extends foundry.abstract.TypeDataModel {\n\n static defineSchema() {\n return {\n life: new fields.SchemaField({\n value: new fields.NumberField({ required: true, initial: 10, min: 0, integer: true }),\n max: new fields.NumberField({ required: true, initial: 10, min: 0, integer: true })\n }),\n\n speed: new fields.NumberField({ required: true, initial: 6, min: 0, integer: true }),\n\n armor: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n\n psi: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n\n initiativeBonus: new fields.NumberField({ required: true, initial: 0, integer: true }),\n\n skills: new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true, initial: \"\" }),\n level: new fields.NumberField({ required: true, initial: 0, integer: true }),\n note: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" })\n })\n ),\n\n attacks: new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true, initial: \"\" }),\n damage: new fields.StringField({ required: true, blank: true, trim: true, initial: \"1D\" }),\n description: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" })\n })\n ),\n\n traits: new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true, initial: \"\" }),\n value: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n description: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" })\n })\n ),\n\n behavior: new fields.SchemaField({\n type: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n subtype: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" })\n }),\n\n biography: new fields.HTMLField({ required: false, blank: true, trim: true }),\n notes: new fields.HTMLField({ required: false, blank: true, trim: true }),\n };\n }\n\n /** @override */\n prepareDerivedData() {\n // Compute initiative bonus from Métabolisme traits\n let bonus = 0;\n for (const trait of this.traits) {\n const nameLower = trait.name.toLowerCase();\n if (nameLower.includes(\"métabolisme rapide\") || nameLower.includes(\"metabolisme rapide\")) {\n const val = parseInt(trait.value);\n if (!isNaN(val)) bonus += val;\n } else if (nameLower.includes(\"métabolisme lent\") || nameLower.includes(\"metabolisme lent\")) {\n const val = parseInt(trait.value);\n if (!isNaN(val)) bonus -= val;\n }\n }\n this.initiativeBonus = bonus;\n\n // Compute armor from Armure trait if not set manually\n if (this.armor === 0) {\n for (const trait of this.traits) {\n if (trait.name.toLowerCase().startsWith(\"armure\")) {\n const val = parseInt(trait.value);\n if (!isNaN(val)) {\n this.armor = val;\n break;\n }\n }\n }\n }\n\n // Compute PSI from Psionique trait\n if (this.psi === 0) {\n for (const trait of this.traits) {\n if (trait.name.toLowerCase().startsWith(\"psionique\")) {\n const val = parseInt(trait.value);\n if (!isNaN(val)) {\n this.psi = val;\n break;\n }\n }\n }\n }\n }\n}\n","import { PhysicalItemData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class ItemData extends PhysicalItemData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.subType.initial = \"loot\";\n schema.software = new fields.SchemaField({\n bandwidth: new fields.NumberField({ required: false, initial: 0, min: 0, max: 10, integer: true }),\n effect: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n computerId: new fields.StringField({ required: false, blank: true, initial: \"\" })\n });\n return schema;\n }\n}\n","import { PhysicalItemData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class EquipmentData extends PhysicalItemData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.equipped = new fields.BooleanField({ required: false, initial: false });\n schema.augment = new fields.SchemaField({\n improvement: new fields.StringField({ required: false, blank: true, trim: true })\n });\n schema.subType.initial = \"equipment\"; // augment, clothing, trinket, toolkit, equipment\n return schema;\n }\n}\n","import { ItemBaseData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class DiseaseData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.subType.initial = \"disease\"; // disease, poison\n schema.difficulty = new fields.StringField({ required: true, initial: \"Average\" });\n schema.damage = new fields.StringField({ required: false, blank: true });\n schema.interval = new fields.StringField({ required: false, blank: true });\n return schema;\n }\n}\n","import { ItemBaseData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class CareerData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.difficulty = new fields.NumberField({ required: true, initial: 0, min: 0, integer: true });\n schema.damage = new fields.StringField({ required: false, blank: true });\n schema.interval = new fields.StringField({ required: false, blank: true });\n schema.assignment = new fields.StringField({ required: false, blank: true });\n schema.terms = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.rank = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.events = new fields.ArrayField(\n new fields.SchemaField({\n age: new fields.NumberField({ required: false, integer: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n );\n return schema;\n }\n}\n","import { ItemBaseData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class TalentData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.subType.initial = \"skill\";\n schema.cost = new fields.NumberField({ required: true, initial: 0, min: 0, integer: true });\n schema.level = new fields.NumberField({ required: true, initial: 0, min: 0, integer: true });\n schema.skill = new fields.SchemaField({\n speciality: new fields.StringField({ required: false, blank: true, trim: true }),\n reduceEncumbrance: new fields.BooleanField({ required: false, initial: false })\n });\n schema.psionic = new fields.SchemaField({\n reach: new fields.StringField({ required: false, blank: true, trim: true }),\n cost: new fields.NumberField({ required: false, initial: 1, min: 0, integer: true }),\n duration: new fields.StringField({ required: false, blank: true, trim: true }),\n durationUnit: new fields.StringField({ required: false })\n });\n schema.roll = new fields.SchemaField({\n characteristic: new fields.StringField({ required: false, blank: true, trim: true }),\n skill: new fields.StringField({ required: false, blank: true, trim: true }),\n difficulty: new fields.StringField({ required: false, blank: true, trim: true })\n });\n return schema;\n }\n}\n","import { ItemBaseData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class ContactData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.subType.initial = \"skill\";\n schema.cost = new fields.NumberField({ required: true, initial: 1, min: 0, integer: true });\n schema.skill = new fields.SchemaField({\n speciality: new fields.StringField({ required: false, blank: true, trim: true }),\n characteristic: new fields.StringField({ required: false, blank: true, trim: true })\n });\n schema.status = new fields.StringField({ required: false, blank: true, trim: true, initial: \"Alive\" });\n schema.attitude = new fields.StringField({ required: false, blank: true, trim: true, initial: \"Unknow\" });\n schema.relation = new fields.StringField({ required: false, blank: true, trim: true, initial: \"Contact\" });\n schema.title = new fields.StringField({ required: false, blank: true, trim: true });\n schema.nickname = new fields.StringField({ required: false, blank: true, trim: true });\n schema.species = new fields.StringField({ required: false, blank: true, trim: true });\n schema.gender = new fields.StringField({ required: false, blank: true, trim: true });\n schema.pronouns = new fields.StringField({ required: false, blank: true, trim: true });\n schema.homeworld = new fields.StringField({ required: false, blank: true, trim: true });\n schema.location = new fields.StringField({ required: false, blank: true, trim: true });\n schema.occupation = new fields.StringField({ required: false, blank: true, trim: true });\n schema.notes = new fields.HTMLField({ required: false, blank: true, trim: true });\n return schema;\n }\n}\n","import { PhysicalItemData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class WeaponData extends PhysicalItemData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.equipped = new fields.BooleanField({ required: false, initial: false });\n schema.range = new fields.SchemaField({\n isMelee: new fields.BooleanField({ required: false, initial: false }),\n value: new fields.NumberField({ required: false, integer: true, nullable: true }),\n unit: new fields.StringField({ required: false, blank: true, nullable: true })\n });\n schema.damage = new fields.StringField({ required: false, blank: true, trim: true });\n schema.magazine = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.magazineCost = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.traits = new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n );\n schema.options = new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n );\n return schema;\n }\n}\n","import { PhysicalItemData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class ArmorData extends PhysicalItemData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.equipped = new fields.BooleanField({ required: false, initial: false });\n schema.radiations = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.protection = new fields.StringField({ required: false, blank: false, trim: true });\n // A Traveller suffers DM-1 to all checks per missing skill level in the required skill.\n schema.requireSkill = new fields.StringField({ required: false, blank: false });\n schema.requireSkillLevel = new fields.NumberField({ required: false, min: 0, integer: true });\n // Powered armour supports its own weight and is effectively weightless for encumbrance.\n schema.powered = new fields.BooleanField({ required: false, initial: false });\n schema.options = new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n );\n return schema;\n }\n}\n","import { PhysicalItemData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class ComputerData extends PhysicalItemData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.processing = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.processingUsed = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.overload = new fields.BooleanField({ required: false, initial: false });\n schema.options = new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n );\n return schema;\n }\n}\n","import { ItemBaseData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class ItemContainerData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.onHand = new fields.BooleanField({ required: false, initial: false });\n schema.location = new fields.StringField({ required: false, blank: true, trim: true });\n schema.count = new fields.NumberField({ required: false, initial: 0, integer: true });\n schema.weight = new fields.NumberField({ required: false, initial: 0, integer: false });\n schema.weightless = new fields.BooleanField({ required: false, initial: false });\n schema.locked = new fields.BooleanField({ required: false, initial: false }); // GM only\n schema.lockedDescription = new fields.StringField({ required: false, blank: true, trim: true, nullable: true });\n return schema;\n }\n}\n","const fields = foundry.data.fields;\n\nexport default class SpeciesData extends foundry.abstract.TypeDataModel {\n static defineSchema() {\n return {\n description: new fields.StringField({ required: false, blank: true, trim: true, nullable: true }),\n descriptionLong: new fields.HTMLField({ required: false, blank: true, trim: true }),\n traits: new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n ),\n modifiers: new fields.ArrayField(\n new fields.SchemaField({\n characteristic: new fields.StringField({ required: false, blank: true, trim: true }),\n value: new fields.NumberField({ required: false, integer: true, nullable: true })\n })\n )\n };\n }\n}\n","export const MGT2 = {};\n\nMGT2.MetricRange = Object.freeze({\n meter: \"MGT2.MetricRange.meter\",\n kilometer: \"MGT2.MetricRange.kilometer\"\n});\n\nMGT2.MetricWeight = Object.freeze({\n kilogram: \"MGT2.MetricWeight.kilogram\",\n ton: \"MGT2.MetricWeight.ton\"\n});\n\nMGT2.Difficulty = Object.freeze({\n NA: \"MGT2.Difficulty.NA\",\n Simple: \"MGT2.Difficulty.Simple\",\n Easy: \"MGT2.Difficulty.Easy\",\n Routine: \"MGT2.Difficulty.Routine\",\n Average: \"MGT2.Difficulty.Average\",\n Difficult: \"MGT2.Difficulty.Difficult\",\n VeryDifficult: \"MGT2.Difficulty.VeryDifficult\",\n Formidable: \"MGT2.Difficulty.Formidable\",\n Impossible: \"MGT2.Difficulty.Impossible\"\n});\n\nMGT2.ItemSubType = Object.freeze({\n loot: \"MGT2.ItemSubType.loot\",\n software: \"MGT2.ItemSubType.software\"\n});\n\nMGT2.EquipmentSubType = Object.freeze({\n augment: \"MGT2.EquipmentSubType.augment\",\n clothing: \"MGT2.EquipmentSubType.clothing\",\n equipment: \"MGT2.EquipmentSubType.equipment\",\n trinket: \"MGT2.EquipmentSubType.trinket\",\n toolkit: \"MGT2.EquipmentSubType.toolkit\"\n});\n\nMGT2.TalentSubType = Object.freeze({\n skill: \"MGT2.TalentSubType.skill\",\n psionic: \"MGT2.TalentSubType.psionic\"\n});\n\nMGT2.DiseaseSubType = Object.freeze({\n disease: \"MGT2.DiseaseSubType.disease\",\n poison: \"MGT2.DiseaseSubType.poison\",\n wound: \"MGT2.DiseaseSubType.wound\"\n});\n\nMGT2.PsionicReach = Object.freeze({\n NA: \"MGT2.PsionicReach.NA\",\n Personal: \"MGT2.PsionicReach.Personal\",\n Close: \"MGT2.PsionicReach.Close\",\n Short: \"MGT2.PsionicReach.Short\",\n Medium: \"MGT2.PsionicReach.Medium\",\n Long: \"MGT2.PsionicReach.Long\",\n VeryLong: \"MGT2.PsionicReach.VeryLong\",\n Distant: \"MGT2.PsionicReach.Distant\",\n VeryDistant: \"MGT2.PsionicReach.VeryDistant\",\n Continental: \"MGT2.PsionicReach.Continental\",\n Planetary: \"MGT2.PsionicReach.Planetary\"\n});\n\nMGT2.ContactRelations = Object.freeze({\n Allie: \"MGT2.Contact.Relation.Allie\",\n Contact: \"MGT2.Contact.Relation.Contact\",\n Rival: \"MGT2.Contact.Relation.Rival\",\n Enemy: \"MGT2.Contact.Relation.Enemy\"\n});\n\nMGT2.ContactStatus = Object.freeze({\n Alive: \"MGT2.Contact.Status.Alive\",\n Unknow: \"MGT2.Contact.Status.Unknow\",\n Dead: \"MGT2.Contact.Status.Dead\"\n});\n\nMGT2.Attitudes = Object.freeze({\n Unknow: \"MGT2.Contact.Attitude.Unknow\",\n Hostile: \"MGT2.Contact.Attitude.Hostile\",\n Unfriendly: \"MGT2.Contact.Attitude.Unfriendly\",\n Indifferent: \"MGT2.Contact.Attitude.Indifferent\",\n Friendly: \"MGT2.Contact.Attitude.Friendly\",\n Helpful: \"MGT2.Contact.Attitude.Helpful\",\n Complicated: \"MGT2.Contact.Attitude.Complicated\"\n});\n\nMGT2.Characteristics = Object.freeze({\n strength: \"MGT2.Characteristics.strength.name\",\n dexterity: \"MGT2.Characteristics.dexterity.name\",\n endurance: \"MGT2.Characteristics.endurance.name\",\n intellect: \"MGT2.Characteristics.intellect.name\",\n education: \"MGT2.Characteristics.education.name\",\n social: \"MGT2.Characteristics.social.name\",\n morale: \"MGT2.Characteristics.morale.name\",\n luck: \"MGT2.Characteristics.luck.name\",\n sanity: \"MGT2.Characteristics.sanity.name\",\n charm: \"MGT2.Characteristics.charm.name\",\n psionic: \"MGT2.Characteristics.psionic.name\",\n other: \"MGT2.Characteristics.other.name\"\n});\n\nMGT2.InitiativeCharacteristics = Object.freeze({\n dexterity: \"MGT2.Characteristics.dexterity.name\",\n intellect: \"MGT2.Characteristics.intellect.name\"\n});\n\nMGT2.DamageCharacteristics = Object.freeze({\n strength: \"MGT2.Characteristics.strength.name\",\n dexterity: \"MGT2.Characteristics.dexterity.name\",\n endurance: \"MGT2.Characteristics.endurance.name\"\n});\n\nMGT2.TL = Object.freeze({\n NA: \"MGT2.TL.NA\",\n Unknow: \"MGT2.TL.Unknow\",\n NotIdentified: \"MGT2.TL.NotIdentified\",\n TL00: \"MGT2.TL.L00\",\n TL01: \"MGT2.TL.L01\",\n TL02: \"MGT2.TL.L02\",\n TL03: \"MGT2.TL.L03\",\n TL04: \"MGT2.TL.L04\",\n TL05: \"MGT2.TL.L05\",\n TL06: \"MGT2.TL.L06\",\n TL07: \"MGT2.TL.L07\",\n TL08: \"MGT2.TL.L08\",\n TL09: \"MGT2.TL.L09\",\n TL10: \"MGT2.TL.L10\",\n TL11: \"MGT2.TL.L11\",\n TL12: \"MGT2.TL.L12\",\n TL13: \"MGT2.TL.L13\",\n TL14: \"MGT2.TL.L14\",\n TL15: \"MGT2.TL.L15\"\n});\n\nMGT2.Timeframes = Object.freeze({\n Normal: \"MGT2.Timeframes.Normal\",\n Slower: \"MGT2.Timeframes.Slower\",\n Faster: \"MGT2.Timeframes.Faster\"\n});\n\nMGT2.SpeedBands = Object.freeze({\n Stoppped: \"MGT2.SpeedBands.Stoppped\",\n Idle: \"MGT2.SpeedBands.Idle\",\n VerySlow: \"MGT2.SpeedBands.VerySlow\",\n Slow: \"MGT2.SpeedBands.Slow\",\n Medium: \"MGT2.SpeedBands.Medium\",\n High: \"MGT2.SpeedBands.High.\",\n Fast: \"MGT2.SpeedBands.Fast\",\n VeryFast: \"MGT2.SpeedBands.VeryFast\",\n Subsonic: \"MGT2.SpeedBands.Subsonic\",\n Hypersonic: \"MGT2.SpeedBands.Hypersonic\"\n});\n\nMGT2.Durations = Object.freeze({\n Seconds: \"MGT2.Durations.Seconds\",\n Minutes: \"MGT2.Durations.Minutes\",\n Heures: \"MGT2.Durations.Heures\"\n});\n\nMGT2.CreatureBehaviorType = Object.freeze({\n herbivore: \"MGT2.CreatureBehaviorType.herbivore\",\n carnivore: \"MGT2.CreatureBehaviorType.carnivore\",\n charognard: \"MGT2.CreatureBehaviorType.charognard\",\n omnivore: \"MGT2.CreatureBehaviorType.omnivore\"\n});\n\nMGT2.CreatureBehaviorSubType = Object.freeze({\n accumulateur: \"MGT2.CreatureBehaviorSubType.accumulateur\",\n brouteur: \"MGT2.CreatureBehaviorSubType.brouteur\",\n filtreur: \"MGT2.CreatureBehaviorSubType.filtreur\",\n intermittent: \"MGT2.CreatureBehaviorSubType.intermittent\",\n chasseur: \"MGT2.CreatureBehaviorSubType.chasseur\",\n detourneur: \"MGT2.CreatureBehaviorSubType.detourneux\",\n guetteur: \"MGT2.CreatureBehaviorSubType.guetteur\",\n mangeur: \"MGT2.CreatureBehaviorSubType.mangeur\",\n piegeur: \"MGT2.CreatureBehaviorSubType.piegeur\",\n intimidateur: \"MGT2.CreatureBehaviorSubType.intimidateur\",\n necrophage: \"MGT2.CreatureBehaviorSubType.necrophage\",\n reducteur: \"MGT2.CreatureBehaviorSubType.reducteur\",\n opportuniste: \"MGT2.CreatureBehaviorSubType.opportuniste\"\n});","export class ActorCharacter {\n static preCreate($this, data, options, user) {\n $this.updateSource({ prototypeToken: { actorLink: true } }) // QoL\n }\n\n static prepareData(actorData) {\n actorData.initiative = this.getInitiative(actorData);\n }\n\n static getInitiative($this) {\n let c = $this.system.config.initiative;\n return $this.system.characteristics[c].dm;\n }\n\n static async onDeleteDescendantDocuments($this, parent, collection, documents, ids, options, userId) {\n const toDeleteIds = [];\n const itemToUpdates = [];\n\n for (let d of documents) {\n if (d.type === \"container\") {\n // Delete content\n for (let item of $this.items) {\n if (item.system.hasOwnProperty(\"container\") && item.system.container.id === d._id)\n toDeleteIds.push(item._id);\n }\n } else if (d.type === \"computer\") {\n // Eject software\n for (let item of $this.items) {\n if (item.system.hasOwnProperty(\"software\") && item.system.computerId === d._id) {\n let clone = foundry.utils.deepClone(item);\n clone.system.software.computerId = \"\";\n itemToUpdates.push(clone);\n }\n }\n }\n }\n\n if (toDeleteIds.length > 0)\n await $this.deleteEmbeddedDocuments(\"Item\", toDeleteIds);\n\n if (itemToUpdates.length > 0)\n await $this.updateEmbeddedDocuments('Item', itemToUpdates);\n\n await this.recalculateWeight($this);\n }\n\n static async onUpdateDescendantDocuments($this, parent, collection, documents, changes, options, userId) {\n await this.calculEncumbranceAndWeight($this, parent, collection, documents, changes, options, userId);\n await this.calculComputers($this, parent, collection, documents, changes, options, userId);\n }\n\n static async calculComputers($this, parent, collection, documents, changes, options, userId) {\n let change;\n let i = 0;\n\n let recalculProcessing = false;\n for (let d of documents) {\n if (changes[i].hasOwnProperty(\"system\")) {\n change = changes[i];\n if (d.type === \"item\" && d.system.subType === \"software\") {\n if (change.system.software.hasOwnProperty(\"bandwidth\") || change.system.software.hasOwnProperty(\"computerId\")) {\n recalculProcessing = true;\n break;\n }\n }\n }\n }\n\n if (recalculProcessing) {\n let updatedComputers = [];\n let computerChanges = {};\n let computers = [];\n\n for (let item of $this.items) {\n if (item.system.trash === true) continue;\n if (item.type === \"computer\") {\n computers.push(item);\n computerChanges[item._id] = { processingUsed: 0 };\n }\n }\n\n for (let item of $this.items) {\n if (item.type !== \"item\" && item.system.subType !== \"software\") continue;\n\n if (item.system.software.hasOwnProperty(\"computerId\") && item.system.software.computerId !== \"\") {\n computerChanges[item.system.software.computerId].processingUsed += item.system.software.bandwidth;\n }\n }\n\n for (let computer of computers) {\n let newProcessingUsed = computerChanges[computer._id].processingUsed;\n if (computer.system.processingUsed !== newProcessingUsed) {\n const cloneComputer = foundry.utils.deepClone($this.getEmbeddedDocument(\"Item\", computer._id));\n cloneComputer.system.processingUsed = newProcessingUsed;\n cloneComputer.system.overload = cloneComputer.system.processingUsed > cloneComputer.system.processing;\n updatedComputers.push(cloneComputer);\n }\n }\n\n if (updatedComputers.length > 0) {\n await $this.updateEmbeddedDocuments('Item', updatedComputers);\n }\n }\n }\n\n static async calculEncumbranceAndWeight($this, parent, collection, documents, changes, options, userId) {\n let recalculEncumbrance = false;\n let recalculWeight = false;\n\n let change;\n let i = 0;\n for (let d of documents) {\n if (changes[i].hasOwnProperty(\"system\")) {\n change = changes[i];\n\n if (d.type === \"armor\" ||\n d.type === \"computer\" ||\n d.type === \"gear\" ||\n d.type === \"item\" ||\n d.type === \"weapon\") {\n if (change.system.hasOwnProperty(\"quantity\") ||\n change.system.hasOwnProperty(\"weight\") ||\n change.system.hasOwnProperty(\"weightless\") ||\n change.system.hasOwnProperty(\"container\") ||\n change.system.hasOwnProperty(\"equipped\") ||\n d.type === \"armor\") {\n recalculWeight = true;\n }\n } else if (d.type === \"talent\" && d.system.subType === \"skill\") {\n if (change.system.level || (change.system?.hasOwnProperty(\"skill\") && change.system?.skill.hasOwnProperty(\"reduceEncumbrance\"))) {\n recalculEncumbrance = true;\n }\n } else if (d.type === \"container\" && (change.system.hasOwnProperty(\"onHand\") || change.system.hasOwnProperty(\"weightless\"))) {\n recalculWeight = true;\n }\n }\n i++;\n }\n\n if (recalculEncumbrance || recalculWeight) {\n const updateData = {};\n\n this.recalculateArmor($this, updateData);\n\n if (recalculEncumbrance) {\n const str = $this.system.characteristics.strength.value;\n const end = $this.system.characteristics.endurance.value;\n let sumSkill = 0;\n $this.items.filter(x => x.type === \"talent\" && x.system.subType === \"skill\" && x.system.skill.reduceEncumbrance === true).forEach(x => sumSkill += x.system.level);\n let normal = str + end + sumSkill;\n let heavy = normal * 2;\n\n updateData[\"system.states.encumbrance\"] = $this.system.inventory.weight > normal;\n updateData[\"system.inventory.encumbrance.normal\"] = normal;\n updateData[\"system.inventory.encumbrance.heavy\"] = heavy;\n }\n\n if (recalculWeight)\n await this.recalculateWeight($this, updateData);\n else if (Object.keys(updateData).length > 0)\n await $this.update(updateData);\n }\n }\n\n static recalculateArmor($this, updateData) {\n if (updateData === null || updateData === undefined)\n updateData = {};\n\n let armor = 0;\n for (let item of $this.items) {\n if (item.type === \"armor\") {\n if (item.system.equipped === true && !isNaN(item.system.protection)) {\n armor += (+item.system.protection || 0);\n }\n }\n }\n\n updateData[\"system.inventory.armor\"] = armor;\n return updateData;\n }\n\n static async recalculateWeight($this, updateData) {\n\n if (updateData === null || updateData === undefined)\n updateData = {};\n\n let updatedContainers = [];\n let containerChanges = {};\n\n let containers = [];\n\n // List all containers\n for (let item of $this.items) {\n if (item.system.trash === true) continue;\n\n if (item.type === \"container\") {\n containers.push(item);\n containerChanges[item._id] = { count: 0, weight: 0 };\n }\n }\n\n let onHandWeight = 0;\n for (let item of $this.items) {\n if (item.type === \"container\") continue;\n if (item.system.hasOwnProperty(\"weightless\") && item.system.weightless === true) continue;\n\n let itemWeight = 0;\n if (item.system.hasOwnProperty(\"weight\")) {\n let itemQty = item.system.quantity;\n if (!isNaN(itemQty) && itemQty > 0) {\n itemWeight = item.system.weight;\n if (itemWeight > 0) {\n itemWeight *= itemQty;\n }\n }\n\n if (item.type === \"armor\") {\n if (item.system.equipped === true) {\n if (item.system.powered === true)\n itemWeight = 0;\n else\n itemWeight *= 0.25; // mass of armor that is being worn by 75% OPTIONAL\n }\n }\n\n if (item.system.container && item.system.container.id && item.system.container.id !== \"\") {\n // bad deleted container id\n if (containerChanges.hasOwnProperty(item.system.container.id)) {\n containerChanges[item.system.container.id].weight += Math.round(itemWeight * 10) / 10;\n containerChanges[item.system.container.id].count += item.system.quantity;\n }\n } else {\n onHandWeight += Math.round(itemWeight * 10) / 10;\n }\n }\n }\n\n // Check containers new weight\n for (let container of containers) {\n let newWeight = containerChanges[container._id].weight;\n let newCount = containerChanges[container._id].count;\n if (container.system.weight !== newWeight || container.system.count !== newCount) {\n updatedContainers.push({\n _id: container._id,\n \"system.weight\": newWeight,\n \"system.count\": newCount,\n });\n\n if (container.system.onHand === true &&\n (container.system.weight > 0 || container.system.weightless !== true)) {\n onHandWeight += container.system.weight;\n }\n }\n }\n\n updateData[\"system.inventory.weight\"] = onHandWeight;\n updateData[\"system.states.encumbrance\"] = onHandWeight > $this.system.inventory.encumbrance.normal;\n\n await $this.update(updateData);\n\n if (updatedContainers.length > 0) {\n await $this.updateEmbeddedDocuments('Item', updatedContainers);\n }\n }\n\n static async preUpdate($this, changed, options, user) {\n // Calc encumbrance\n\n const newStr = foundry.utils.getProperty(changed, \"system.characteristics.strength.value\") ?? $this.system.characteristics.strength.value;\n const newEnd = foundry.utils.getProperty(changed, \"system.characteristics.endurance.value\") ?? $this.system.characteristics.endurance.value;\n if ((newStr !== $this.system.characteristics.strength.value) || (newEnd !== $this.system.characteristics.endurance.value)) {\n let sumSkill = 0;\n $this.items.filter(x => x.type === \"talent\" && x.system.subType === \"skill\" && x.system.skill.reduceEncumbrance === true).forEach(x => sumSkill += x.system.level);\n let normal = newStr + newEnd + sumSkill;\n let heavy = normal * 2;\n foundry.utils.setProperty(changed, \"system.inventory.encumbrance.normal\", normal);\n foundry.utils.setProperty(changed, \"system.inventory.encumbrance.heavy\", heavy);\n }\n\n //console.log(foundry.utils.getProperty(changed, \"system.characteristics.strength.value\"));\n const characteristicModified = this.computeCharacteristics(changed);\n const strengthValue = foundry.utils.getProperty(changed, \"system.characteristics.strength.value\") ?? $this.system.characteristics.strength.value;\n const strengthMax = foundry.utils.getProperty(changed, \"system.characteristics.strength.max\") ?? $this.system.characteristics.strength.max;\n const dexterityValue = foundry.utils.getProperty(changed, \"system.characteristics.dexterity.value\") ?? $this.system.characteristics.dexterity.value;\n const dexterityMax = foundry.utils.getProperty(changed, \"system.characteristics.dexterity.max\") ?? $this.system.characteristics.dexterity.max;\n const enduranceValue = foundry.utils.getProperty(changed, \"system.characteristics.endurance.value\") ?? $this.system.characteristics.endurance.value;\n const enduranceMax = foundry.utils.getProperty(changed, \"system.characteristics.endurance.max\") ?? $this.system.characteristics.endurance.max;\n const lifeValue = strengthValue + dexterityValue + enduranceValue;\n const lifeMax = strengthMax + dexterityMax + enduranceMax;\n\n if ($this.system.life.value !== lifeValue)\n foundry.utils.setProperty(changed, \"system.life.value\", lifeValue);\n if ($this.system.life.max !== lifeMax)\n foundry.utils.setProperty(changed, \"system.life.max\", lifeMax);\n\n if (characteristicModified && $this.system.personal.ucp === undefined || $this.system.personal.ucp === \"\") {\n // calc\n\n }\n //}\n\n // Apply changes in Actor size to Token width/height\n // if ( \"size\" in (this.system.traits || {}) ) {\n // const newSize = foundry.utils.getProperty(changed, \"system.traits.size\");\n // if ( newSize && (newSize !== this.system.traits?.size) ) {\n // let size = CONFIG.DND5E.tokenSizes[newSize];\n // if ( !foundry.utils.hasProperty(changed, \"prototypeToken.width\") ) {\n // changed.prototypeToken ||= {};\n // changed.prototypeToken.height = size;\n // changed.prototypeToken.width = size;\n // }\n // }\n // }\n }\n\n // static applyHealing($this, amount) {\n // if (isNaN(amount) || amount === 0) return;\n\n // const strength = $this.system.characteristics.strength;\n // const dexterity = $this.system.characteristics.dexterity;\n // const endurance = $this.system.characteristics.endurance;\n\n // const data = {\n // strength: { value: strength.value },\n // dexterity: { value: dexterity.value },\n // endurance: { value: endurance.value }\n // };\n\n\n\n // $this.update({ system: { characteristics: data } });\n // }\n\n static applyDamage($this, amount) {\n if (isNaN(amount) || amount === 0) return;\n const rank1 = $this.system.config.damages.rank1;\n const rank2 = $this.system.config.damages.rank2;\n const rank3 = $this.system.config.damages.rank3;\n\n const data = {};\n data[rank1] = { value: $this.system.characteristics[rank1].value };\n data[rank2] = { value: $this.system.characteristics[rank2].value };\n data[rank3] = { value: $this.system.characteristics[rank3].value };\n\n if (amount < 0) amount = Math.abs(amount);\n\n for (const [key, rank] of Object.entries(data)) {\n if (rank.value > 0) {\n if (rank.value >= amount) {\n rank.value -= amount;\n amount = 0;\n } else {\n amount -= rank.value;\n rank.value = 0;\n }\n rank.dm = this.getModifier(rank.value);\n if (amount <= 0) break;\n }\n }\n\n $this.update({ system: { characteristics: data } });\n }\n\n static getContainers($this) {\n const containers = [];\n for (let item of $this.items) {\n if (item.type == \"container\") {\n containers.push(item);\n }\n }\n\n containers.sort(this.compareByName);\n\n return containers;\n }\n\n static getComputers($this) {\n const containers = [];\n for (let item of $this.items) {\n if (item.type == \"computer\") {\n containers.push(item);\n }\n }\n\n containers.sort(this.compareByName);\n\n return containers;\n }\n\n static getSkills($this) {\n const skills = [];\n for (let item of $this.items) {\n if (item.type === \"talent\" && item.system.subType === \"skill\") {\n skills.push(item);\n }\n }\n\n skills.sort(this.compareByName);\n\n return skills;\n }\n\n static computeCharacteristics(changed) {\n let modified = this.computeCharacteristic(changed, \"strength\");\n\n if (this.computeCharacteristic(changed, \"dexterity\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"endurance\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"intellect\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"education\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"social\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"morale\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"luck\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"sanity\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"charm\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"psionic\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"other\") && !modified) modified = true;\n\n return modified;\n }\n\n static computeCharacteristic(changed, name) {\n //if (isNaN(c.value) || c.value <= 0) c.value = 0;\n //c.dm = this._getModifier(c.value)\n const path = `system.characteristics.${name}`;\n const newValue = foundry.utils.getProperty(changed, path + \".value\");// || this.system.characteristics[name].value;\n if (newValue) {\n const dm = this.getModifier(newValue);\n foundry.utils.setProperty(changed, path + \".dm\", dm);\n return true;\n }\n\n return false;\n }\n\n static getModifier(value) {\n if (isNaN(value) || value <= 0) return -3;\n if (value >= 1 && value <= 2) return -2;\n if (value >= 3 && value <= 5) return -1;\n if (value >= 6 && value <= 8) return 0;\n if (value >= 9 && value <= 11) return 1;\n if (value >= 12 && value <= 14) return 2;\n\n return 3;\n }\n\n static compareByName(a, b) {\n if (!a.hasOwnProperty(\"name\") || !b.hasOwnProperty(\"name\")) {\n return 0;\n }\n return a.name.toLowerCase().localeCompare(b.name.toLowerCase());\n }\n}","import { ActorCharacter } from \"./character.js\";\n\nexport class MGT2Combatant extends Combatant {\n \n}\n\nexport class TravellerActor extends Actor {\n\n\n prepareDerivedData() {\n if (this.type === \"character\") {\n this.system.initiative = ActorCharacter.getInitiative(this);\n }\n }\n\n async _preCreate(data, options, user) {\n if ( (await super._preCreate(data, options, user)) === false ) return false;\n \n if (this.type === \"character\") {\n ActorCharacter.preCreate(this, data, options, user);\n }\n }\n\n async _onDeleteDescendantDocuments(parent, collection, documents, ids, options, userId) {\n await super._onDeleteDescendantDocuments(parent, collection, documents, ids, options, userId);\n\n if (this.type === \"character\") {\n await ActorCharacter.onDeleteDescendantDocuments(this, parent, collection, documents, ids, options, userId);\n }\n }\n\n async _onUpdateDescendantDocuments(parent, collection, documents, changes, options, userId) {\n super._onUpdateDescendantDocuments(parent, collection, documents, changes, options, userId);\n //console.log(\"_onUpdateDescendantDocuments\");\n\n if (this.type === \"character\") {\n await ActorCharacter.onUpdateDescendantDocuments(this, parent, collection, documents, changes, options, userId);\n }\n }\n\n async _preUpdate(changed, options, user) {\n if ((await super._preUpdate(changed, options, user)) === false) return false;\n\n if (this.type === \"character\") {\n await ActorCharacter.preUpdate(this, changed, options, user);\n }\n }\n\n getInitiative($this) {\n if (this.type === \"character\") {\n return ActorCharacter.getInitiative(this);\n }\n }\n\n applyDamage(amount) {\n if (this.type === \"character\") {\n ActorCharacter.applyDamage(this, amount);\n }\n }\n\n getContainers() {\n if (this.type === \"character\") {\n return ActorCharacter.getContainers(this);\n }\n\n return [];\n }\n\n getComputers() {\n if (this.type === \"character\") {\n return ActorCharacter.getComputers(this);\n }\n\n return [];\n }\n\n getSkills() {\n if (this.type === \"character\") {\n return ActorCharacter.getSkills(this);\n }\n\n return [];\n }\n\n async recalculateWeight() {\n if (this.type === \"character\") {\n return ActorCharacter.recalculateWeight(this);\n }\n }\n\n}\n","export class TravellerItem extends Item {\n\n /** @inheritdoc */\n prepareDerivedData() {\n super.prepareDerivedData();\n\n }\n\n async _preUpdate(changed, options, user) {\n if ((await super._preUpdate(changed, options, user)) === false) return false;\n\n if (this.type === \"computer\") {\n // Overload\n const newProcessing = foundry.utils.getProperty(changed, \"system.processing\") ?? this.system.processing;\n if (newProcessing !== this.system.processing) {\n let overload = this.system.processingUsed > newProcessing;\n foundry.utils.setProperty(changed, \"system.overload\", overload);\n }\n }\n\n // Qty max 1\n if (this.type === \"computer\" || this.type === \"container\" || (this.type === \"item\" && this.system.subType === \"software\")) {\n const newQty = foundry.utils.getProperty(changed, \"system.quantity\") ?? this.system.quantity;\n if (newQty !== this.system.quantity && newQty > 1) {\n foundry.utils.setProperty(changed, \"system.quantity\", 1);\n }\n }\n\n // No Weight\n if (this.type === \"item\" && this.system.subType === \"software\") {\n const newWeight = foundry.utils.getProperty(changed, \"system.weight\") ?? this.system.weight;\n if (newWeight !== this.system.weight && newWeight > 0) {\n foundry.utils.setProperty(changed, \"system.weight\", 0);\n }\n }\n }\n\n getRollDisplay() {\n if (this.type === \"talent\") {\n if (this.system.subType === \"skill\") {\n let label;\n if (this.system.skill.speciality !== \"\" && this.system.skill.speciality !== undefined) {\n label = `${this.name} (${this.system.skill.speciality})`;\n } else {\n label = this.name;\n }\n\n if (this.system.level > 0)\n label += ` (+${this.system.level})`;\n else if (this.system.level < 0)\n label += ` (${this.system.level})`;\n\n return label;\n } else if (this.system.subType === \"psionic\") {\n\n }\n }\n\n return name;\n }\n}\n","const { HandlebarsApplicationMixin } = foundry.applications.api;\n\nexport default class MGT2ActorSheet extends HandlebarsApplicationMixin(foundry.applications.sheets.ActorSheetV2) {\n\n static SHEET_MODES = { EDIT: 0, PLAY: 1 }\n\n constructor(options = {}) {\n super(options);\n this._sheetMode = this.constructor.SHEET_MODES.PLAY;\n }\n\n /** @override */\n static DEFAULT_OPTIONS = {\n classes: [\"mgt2\", \"sheet\", \"actor\"],\n position: {\n width: 780,\n },\n form: {\n submitOnChange: true,\n closeOnSubmit: false,\n },\n window: {\n resizable: true,\n },\n dragDrop: [{ dragSelector: \".drag-item-list\", dropSelector: \".drop-item-list\" }],\n actions: {\n toggleSheet: MGT2ActorSheet.#onToggleSheet,\n },\n }\n\n get isPlayMode() {\n if (this._sheetMode === undefined) this._sheetMode = this.constructor.SHEET_MODES.PLAY;\n return this._sheetMode === this.constructor.SHEET_MODES.PLAY;\n }\n\n get isEditMode() {\n if (this._sheetMode === undefined) this._sheetMode = this.constructor.SHEET_MODES.PLAY;\n return this._sheetMode === this.constructor.SHEET_MODES.EDIT;\n }\n\n tabGroups = { sidebar: \"health\" }\n\n /** @override */\n async _prepareContext() {\n const base = await super._prepareContext();\n const actor = this.document;\n return {\n ...base,\n actor: actor,\n // Flat shorthands for template backward-compat (AppV1 style)\n name: actor.name,\n img: actor.img,\n cssClass: this.isEditable ? \"editable\" : \"locked\",\n system: actor.system,\n source: actor.toObject(),\n fields: actor.schema.fields,\n systemFields: actor.system.schema.fields,\n isEditable: this.isEditable,\n isEditMode: this.isEditMode,\n isPlayMode: this.isPlayMode,\n isGM: game.user.isGM,\n config: CONFIG.MGT2,\n };\n }\n\n /** @override */\n _onRender(context, options) {\n super._onRender(context, options);\n // Inject theme class dynamically (can't use game.settings in static DEFAULT_OPTIONS)\n const theme = game.settings.get(\"mgt2\", \"theme\");\n if (theme) this.element.classList.add(theme);\n this._activateTabGroups();\n }\n\n _activateTabGroups() {\n for (const [group, activeTab] of Object.entries(this.tabGroups)) {\n const nav = this.element.querySelector(`nav[data-group=\"${group}\"]`);\n if (!nav) continue;\n\n nav.querySelectorAll('[data-tab]').forEach(link => {\n link.classList.toggle('active', link.dataset.tab === activeTab);\n link.addEventListener('click', event => {\n event.preventDefault();\n this.tabGroups[group] = link.dataset.tab;\n this.render();\n });\n });\n\n this.element.querySelectorAll(`[data-group=\"${group}\"][data-tab]`).forEach(content => {\n content.classList.toggle('active', content.dataset.tab === activeTab);\n });\n }\n }\n\n /** @override */\n _canDragDrop(selector) {\n return this.isEditable;\n }\n\n static async #onToggleSheet(event) {\n event.preventDefault();\n this._sheetMode = this.isPlayMode\n ? this.constructor.SHEET_MODES.EDIT\n : this.constructor.SHEET_MODES.PLAY;\n this.render();\n }\n}\n","export class MGT2Helper {\n static POUNDS_CONVERT = 2.20462262185;\n\n static decimalSeparator;\n static badDecimalSeparator;\n\n static {\n this.decimalSeparator = Number(1.1).toLocaleString().charAt(1);\n this.badDecimalSeparator = (this.decimalSeparator === \".\" ? \",\" : \".\");\n }\n\n static format = function() {\n var s = arguments[0];\n for (var i = 0; i < arguments.length - 1; i++) { \n var reg = new RegExp(\"\\\\{\" + i + \"\\\\}\", \"gm\"); \n s = s.replace(reg, arguments[i + 1]);\n }\n return s;\n }\n\n static hasValue(object, property) {\n return object !== undefined && object.hasOwnProperty(property) && object[property] !== null && object[property] !== undefined && object[property] !== \"\";\n }\n\n static getItemsWeight(items) {\n let weight = 0;\n for (let i of items) {\n let item = i.hasOwnProperty(\"system\") ? i.system : i;\n if (item.hasOwnProperty(\"weightless\") && item.weightless === true) {\n continue;\n }\n\n if (item.hasOwnProperty(\"weight\")) {\n let itemQty = item.quantity\n if (!isNaN(itemQty) && itemQty > 0) {\n let itemWeight = item.weight;\n if (itemWeight > 0) {\n weight += itemWeight * itemQty;\n }\n }\n }\n }\n return weight;\n }\n\n static generateUID() {\n let result = '';\n const characters = 'abcdefghijklmnopqrstuvwxyz0123456789';\n\n for (let i = 0; i < 36; i++) {\n const randomIndex = Math.floor(Math.random() * characters.length);\n result += characters.charAt(randomIndex);\n if (i === 8 || i === 12 || i === 16 || i === 20)\n result += \"-\";\n }\n\n return result;\n }\n\n static compareByName(a, b) {\n if (!a.hasOwnProperty(\"name\") || !b.hasOwnProperty(\"name\")) {\n return 0;\n }\n return a.name.toLowerCase().localeCompare(b.name.toLowerCase());\n }\n\n static getDisplayDM(dm) {\n if (dm === 0) return \" (0)\";\n if (dm > 0) return ` (+${dm})`;\n if (dm < 0) return ` (${dm})`;\n return \"\";\n }\n static getFormulaDM(dm) {\n if (dm === 0) return \"+0\";\n if (dm > 0) return `+${dm}`;\n if (dm < 0) return `${dm}`;\n return \"\";\n }\n\n static getDiceResults(roll) {\n const results = [];\n for (const die of roll.dice) {\n results.push(die.results);\n }\n return results.flat(2);\n }\n\n static getDiceTotal(roll) {\n let total = 0;\n for (const die of roll.dice) {\n total += die.total;\n }\n return total;\n }\n\n static getDifficultyValue(difficulty) {\n switch(difficulty) {\n case \"Simple\": return 2;\n case \"Easy\": return 4;\n case \"Routine\": return 6;\n case \"Average\": return 8;\n case \"Difficult\": return 10;\n case \"VeryDifficult\": return 12;\n case \"Formidable\": return 14;\n case \"Impossible\": return 16;\n default:\n return 0;\n }\n }\n\n static getDifficultyDisplay(difficulty) {\n const key = `MGT2.Difficulty.${difficulty}`;\n const label = game.i18n.localize(key);\n return label !== key ? label : null;\n }\n\n static getRangeDisplay(range) {\n let value = Number(range.value);\n\n if (isNaN(value)) return null;\n\n let label;\n //if (game.settings.get(\"mgt2\", \"useDistanceMetric\") === true) {\n if (range.unit !== null && range.unit !== undefined && range.unit !== \"\")\n label = game.i18n.localize(`MGT2.MetricRange.${range.unit}`).toLowerCase();\n else\n label = \"\";\n //} else {\n // TODO\n //}\n\n return `${value}${label}`;\n }\n\n static getWeightLabel() {\n //const label = game.settings.get(\"mgt2\", \"useWeightMetric\") === true ? \"MGT2.MetricSystem.Weight.kg\" : \"MGT2.ImperialSystem.Weight.lb\";\n //return game.i18n.localize(label);\n return game.i18n.localize(\"MGT2.MetricSystem.Weight.kg\");\n }\n\n static getDistanceLabel() {\n //const label = game.settings.get(\"mgt2\", \"useDistanceMetric\") === true ? \"MGT2.MetricSystem.Distance.km\" : \"MGT2.ImperialSystem.Distance.mi\";\n //return game.i18n.localize(label);\n return game.i18n.localize(\"MGT2.MetricSystem.Distance.km\");\n }\n\n static getIntegerFromInput(data) {\n return Math.trunc(this.getNumberFromInput(data));\n }\n\n static getNumberFromInput(data) {\n if (data === undefined || data === null) return 0;\n\n if (typeof data === \"string\") {\n let converted = Number(data.replace(/\\s+/g, '').replace(this.badDecimalSeparator, this.decimalSeparator).trim());\n if (isNaN(converted))\n return 0;\n\n return converted;\n }\n\n let converted = Number(data);\n\n if (isNaN(converted))\n return 0;\n\n return converted;\n }\n\n static convertWeightForDisplay(weight) {\n //if (game.settings.get(\"mgt2\", \"useWeightMetric\") === true || weight === 0)\n return weight;\n\n // Metric to Imperial\n //const pounds = weight * this.POUNDS_CONVERT;\n //return Math.round(pounds * 10) / 10;\n }\n\n static convertWeightFromInput(weight) {\n //if (game.settings.get(\"mgt2\", \"useWeightMetric\") === true || weight === 0)\n return Math.round(weight * 10) / 10;\n\n // Imperial to Metric\n //const kg = this.POUNDS_CONVERT / weight;\n //return Math.round(kg * 10) / 10;\n }\n\n static getDataFromDropEvent(event) {\n let data;\n try {\n return JSON.parse(event.dataTransfer?.getData(\"text/plain\"));\n } catch (err) {\n return false;\n }\n\n //if ( data.type !== \"Item\" ) return false;\n //const item = await Item.implementation.fromDropData(data);\n }\n\n static async getItemDataFromDropData(dropData) {\n //console.log(\"getItemDataFromDropData\");\n let item;\n if (game.modules.get(\"monks-enhanced-journal\")?.active && dropData.itemId && dropData.uuid.includes(\"JournalEntry\")) {\n const journalEntry = await fromUuid(dropData.uuid);\n } else if (dropData.hasOwnProperty(\"uuid\")) {\n item = await fromUuid(dropData.uuid);\n } else {\n let uuid = `${dropData.type}.${dropData.data._id}`;\n item = await fromUuid(uuid);\n }\n\n if (!item) {\n throw new Error(game.i18n.localize(\"Errors.CouldNotFindItem\").replace(\"_ITEM_ID_\", dropData.uuid));\n }\n if (item.pack) {\n const pack = game.packs.get(item.pack);\n item = await pack?.getDocument(item._id);\n }\n return deepClone(item);\n }\n}","const { DialogV2 } = foundry.applications.api;\nconst { renderTemplate } = foundry.applications.handlebars;\nconst { FormDataExtended } = foundry.applications.ux;\n\nexport class RollPromptHelper {\n\n static async roll(options) {\n const htmlContent = await renderTemplate('systems/mgt2/templates/roll-prompt.html', {\n config: CONFIG.MGT2,\n characteristics: options.characteristics,\n characteristic: options.characteristic,\n skills: options.skills,\n skill: options.skill,\n fatigue: options.fatigue,\n encumbrance: options.encumbrance,\n difficulty: options.difficulty\n });\n\n const theme = game.settings.get(\"mgt2\", \"theme\");\n\n return await DialogV2.wait({\n window: { title: options.title ?? options.rollTypeName ?? game.i18n.localize(\"MGT2.RollPrompt.Roll\") },\n classes: [\"mgt2-roll-dialog\"],\n content: htmlContent,\n rejectClose: false,\n buttons: [\n {\n action: \"boon\",\n label: game.i18n.localize(\"MGT2.RollPrompt.Boon\"),\n callback: (event, button, dialog) => {\n const formData = new FormDataExtended(dialog.element.querySelector('form')).object;\n formData.diceModifier = \"dl\";\n return formData;\n }\n },\n {\n action: \"submit\",\n label: game.i18n.localize(\"MGT2.RollPrompt.Roll\"),\n icon: '',\n default: true,\n callback: (event, button, dialog) => {\n return new FormDataExtended(dialog.element.querySelector('form')).object;\n }\n },\n {\n action: \"bane\",\n label: game.i18n.localize(\"MGT2.RollPrompt.Bane\"),\n callback: (event, button, dialog) => {\n const formData = new FormDataExtended(dialog.element.querySelector('form')).object;\n formData.diceModifier = \"dh\";\n return formData;\n }\n }\n ]\n });\n }\n}","const { DialogV2 } = foundry.applications.api;\nconst { renderTemplate } = foundry.applications.handlebars;\nconst { FormDataExtended } = foundry.applications.ux;\n\nasync function _dialogWithForm(title, templatePath, templateData) {\n const htmlContent = await renderTemplate(templatePath, templateData);\n const theme = game.settings.get(\"mgt2\", \"theme\");\n return await DialogV2.wait({\n window: { title },\n content: htmlContent,\n rejectClose: false,\n buttons: [\n {\n action: \"submit\",\n label: game.i18n.localize(\"MGT2.Save\"),\n icon: '',\n default: true,\n callback: (event, button, dialog) => {\n return new FormDataExtended(dialog.element.querySelector('form')).object;\n }\n }\n ]\n });\n}\n\nexport class CharacterPrompts {\n\n static async openConfig(system) {\n return _dialogWithForm(\n \"Configuration\",\n \"systems/mgt2/templates/actors/actor-config-sheet.html\",\n { config: CONFIG.MGT2, system }\n );\n }\n\n static async openCharacteristic(name, show, showMax, showAll = false) {\n return _dialogWithForm(\n \"Configuration: \" + name,\n \"systems/mgt2/templates/actors/actor-config-characteristic-sheet.html\",\n { name, show, showMax, showAll }\n );\n }\n\n static async openTraitEdit(data) {\n const title = data.name ?? game.i18n.localize(\"MGT2.Actor.EditTrait\");\n return _dialogWithForm(\n title,\n \"systems/mgt2/templates/actors/trait-sheet.html\",\n { config: CONFIG.MGT2, data }\n );\n }\n\n static async openEditorFullView(title, html) {\n const htmlContent = await renderTemplate(\"systems/mgt2/templates/editor-fullview.html\", {\n config: CONFIG.MGT2,\n html\n });\n const theme = game.settings.get(\"mgt2\", \"theme\");\n await DialogV2.wait({\n window: { title },\n content: htmlContent,\n rejectClose: false,\n buttons: [\n {\n action: \"close\",\n label: game.i18n.localize(\"MGT2.Close\") || \"Fermer\",\n default: true,\n callback: () => null\n }\n ]\n });\n }\n}","import MGT2ActorSheet from \"./base-actor-sheet.mjs\";\nimport { MGT2 } from \"../../config.js\";\nimport { MGT2Helper } from \"../../helper.js\";\nimport { RollPromptHelper } from \"../../roll-prompt.js\";\nimport { CharacterPrompts } from \"../../actors/character-prompts.js\";\n\nexport default class TravellerCharacterSheet extends MGT2ActorSheet {\n\n /** @override */\n static DEFAULT_OPTIONS = {\n ...super.DEFAULT_OPTIONS,\n classes: [...super.DEFAULT_OPTIONS.classes, \"character\", \"nopad\"],\n window: {\n ...super.DEFAULT_OPTIONS.window,\n title: \"TYPES.Actor.character\",\n },\n actions: {\n ...super.DEFAULT_OPTIONS.actions,\n createItem: TravellerCharacterSheet.#onCreateItem,\n editItem: TravellerCharacterSheet.#onEditItem,\n deleteItem: TravellerCharacterSheet.#onDeleteItem,\n equipItem: TravellerCharacterSheet.#onEquipItem,\n itemStorageIn: TravellerCharacterSheet.#onItemStorageIn,\n itemStorageOut: TravellerCharacterSheet.#onItemStorageOut,\n softwareEject: TravellerCharacterSheet.#onSoftwareEject,\n createContainer: TravellerCharacterSheet.#onContainerCreate,\n editContainer: TravellerCharacterSheet.#onContainerEdit,\n deleteContainer: TravellerCharacterSheet.#onContainerDelete,\n roll: TravellerCharacterSheet.#onRoll,\n openConfig: TravellerCharacterSheet.#onOpenConfig,\n openCharacteristic: TravellerCharacterSheet.#onOpenCharacteristic,\n traitCreate: TravellerCharacterSheet.#onTraitCreate,\n traitEdit: TravellerCharacterSheet.#onTraitEdit,\n traitDelete: TravellerCharacterSheet.#onTraitDelete,\n openEditor: TravellerCharacterSheet.#onOpenEditor,\n },\n }\n\n /** @override */\n static PARTS = {\n sheet: {\n template: \"systems/mgt2/templates/actors/actor-sheet.html\",\n },\n }\n\n /** @override */\n tabGroups = {\n sidebar: \"inventory\",\n characteristics: \"core\",\n inventory: \"onhand\",\n }\n\n /** @override */\n async _prepareContext() {\n const context = await super._prepareContext();\n const actor = this.document;\n\n context.settings = {\n weightUnit: \"kg\",\n usePronouns: game.settings.get(\"mgt2\", \"usePronouns\"),\n useGender: game.settings.get(\"mgt2\", \"useGender\"),\n showLife: game.settings.get(\"mgt2\", \"showLife\"),\n };\n context.isGM = game.user.isGM;\n context.showTrash = false;\n context.initiative = actor.getInitiative();\n\n this._prepareCharacterItems(context);\n\n return context;\n }\n\n _prepareCharacterItems(context) {\n const actor = this.document;\n const settings = context.settings;\n const items = actor.items;\n\n const weapons = [], armors = [], augments = [], computers = [], softwares = [];\n const miscItems = [], equipments = [], containerItems = [], careers = [];\n const skills = [], psionics = [], diseases = [], wounds = [], contacts = [];\n const actorContainers = [];\n\n for (let i of items) {\n if (i.type === \"container\") {\n actorContainers.push(i);\n } else if (i.type === \"computer\") {\n computers.push(i);\n i._subItems = [];\n if (i.system.overload === true)\n i._overloadClass = \"computer-overload\";\n }\n }\n\n actorContainers.sort(MGT2Helper.compareByName);\n\n const containers = [{ name: \"(tous)\", _id: \"\" }].concat(actorContainers);\n const containerIndex = new Map();\n\n for (let c of actorContainers) {\n containerIndex.set(c._id, c);\n\n if (c.system.weight > 0) {\n const w = MGT2Helper.convertWeightForDisplay(c.system.weight) + \" \" + settings.weightUnit;\n c._display = c.name.length > 12 ? `${c.name.substring(0, 12)}... (${w})` : `${c.name} (${w})`;\n } else {\n c._display = c.name.length > 12 ? c.name.substring(0, 12) + \"...\" : c.name;\n }\n\n if (c.system.onHand === true)\n c._subItems = [];\n }\n\n const containerView = actor.system.containerView;\n let currentContainerView = containerView !== \"\" ? containerIndex.get(containerView) : null;\n\n context.containerView = currentContainerView || null;\n context.containerWeight = currentContainerView\n ? MGT2Helper.convertWeightForDisplay(currentContainerView.system.weight)\n : MGT2Helper.convertWeightForDisplay(0);\n context.containerShowAll = containerView === \"\";\n\n for (let i of items) {\n const item = i.system;\n\n if (item.hasOwnProperty(\"weight\") && item.weight > 0) {\n i._weight = isNaN(item.quantity)\n ? MGT2Helper.convertWeightForDisplay(item.weight) + \" \" + settings.weightUnit\n : MGT2Helper.convertWeightForDisplay(item.weight * item.quantity) + \" \" + settings.weightUnit;\n }\n\n if (item.hasOwnProperty(\"container\") && item.container.id !== \"\" && item.container.id !== undefined) {\n const container = containerIndex.get(item.container.id);\n if (container === undefined) {\n if (context.containerShowAll) {\n i._containerName = \"#deleted#\";\n containerItems.push(i);\n }\n continue;\n }\n\n if (container.system.locked && !game.user.isGM) continue;\n\n if (container.system.onHand === true)\n container._subItems.push(i);\n\n if (context.containerShowAll || actor.system.containerView === item.container.id) {\n i._containerName = container.name;\n containerItems.push(i);\n }\n continue;\n }\n\n if (item.hasOwnProperty(\"equipped\")) {\n i._canEquip = true;\n i._toggleClass = item.equipped ? \"active\" : \"\";\n } else {\n i._canEquip = false;\n }\n\n switch (i.type) {\n case \"equipment\":\n (i.system.subType === \"augment\" ? augments : equipments).push(i);\n break;\n\n case \"armor\":\n if (i.system.options?.length > 0)\n i._subInfo = i.system.options.map(x => x.name).join(\", \");\n armors.push(i);\n break;\n\n case \"computer\":\n if (i.system.options?.length > 0)\n i._subInfo = i.system.options.map(x => x.name).join(\", \");\n break;\n\n case \"item\":\n if (i.system.subType === \"software\") {\n if (i.system.software.computerId && i.system.software.computerId !== \"\") {\n const computer = computers.find(x => x._id === i.system.software.computerId);\n if (computer !== undefined) computer._subItems.push(i);\n else softwares.push(i);\n } else {\n i._display = i.system.software.bandwidth > 0\n ? `${i.name} (${i.system.software.bandwidth})`\n : i.name;\n softwares.push(i);\n }\n } else {\n miscItems.push(i);\n }\n break;\n\n case \"weapon\":\n i._range = i.system.range.isMelee\n ? game.i18n.localize(\"MGT2.Melee\")\n : MGT2Helper.getRangeDisplay(i.system.range);\n if (i.system.traits?.length > 0)\n i._subInfo = i.system.traits.map(x => x.name).join(\", \");\n weapons.push(i);\n break;\n\n case \"career\":\n careers.push(i);\n break;\n\n case \"contact\":\n contacts.push(i);\n break;\n\n case \"disease\":\n (i.system.subType === \"wound\" ? wounds : diseases).push(i);\n break;\n\n case \"talent\":\n if (i.system.subType === \"skill\") {\n skills.push(i);\n } else {\n if (MGT2Helper.hasValue(i.system.psionic, \"reach\"))\n i._reach = game.i18n.localize(`MGT2.PsionicReach.${i.system.psionic.reach}`);\n if (MGT2Helper.hasValue(i.system.roll, \"difficulty\"))\n i._difficulty = game.i18n.localize(`MGT2.Difficulty.${i.system.roll.difficulty}`);\n psionics.push(i);\n }\n break;\n\n case \"container\":\n if (i.system.onHand === true)\n miscItems.push(i);\n break;\n }\n }\n\n const byName = MGT2Helper.compareByName;\n const byEquipName = (a, b) => a.name.toLowerCase().localeCompare(b.name.toLowerCase());\n\n context.encumbranceNormal = MGT2Helper.convertWeightForDisplay(actor.system.inventory.encumbrance.normal);\n context.encumbranceHeavy = MGT2Helper.convertWeightForDisplay(actor.system.inventory.encumbrance.heavy);\n\n const totalWeight = actor.system.inventory.weight;\n if (totalWeight > actor.system.inventory.encumbrance.heavy) {\n context.encumbranceClasses = \"encumbrance-heavy\";\n context.encumbrance = 2;\n } else if (totalWeight > actor.system.inventory.encumbrance.normal) {\n context.encumbranceClasses = \"encumbrance-normal\";\n context.encumbrance = 1;\n } else {\n context.encumbrance = 0;\n }\n\n if (softwares.length > 0) { softwares.sort(byName); context.softwares = softwares; }\n augments.sort(byEquipName); context.augments = augments;\n armors.sort(byEquipName); context.armors = armors;\n computers.sort(byEquipName); context.computers = computers;\n context.careers = careers;\n contacts.sort(byName); context.contacts = contacts;\n containers.sort(byName); context.containers = containers;\n diseases.sort(byName); context.diseases = diseases;\n context.wounds = wounds;\n equipments.sort(byEquipName); context.equipments = equipments;\n miscItems.sort(byEquipName); context.items = miscItems;\n actorContainers.sort(byName); context.actorContainers = actorContainers;\n skills.sort(byName); context.skills = skills;\n psionics.sort(byName); context.psionics = psionics;\n weapons.sort(byEquipName); context.weapons = weapons;\n\n if (containerItems.length > 0) {\n containerItems.sort((a, b) => {\n const r = a._containerName.localeCompare(b._containerName);\n return r !== 0 ? r : a.name.toLowerCase().localeCompare(b.name.toLowerCase());\n });\n }\n context.containerItems = containerItems;\n }\n\n // =========================================================\n // Event Binding (AppV2 _onRender — replaces jQuery activateListeners)\n // Templates still use CSS class selectors, so we bind manually here.\n // =========================================================\n\n /** @override */\n _onRender(context, options) {\n super._onRender(context, options);\n const html = this.element;\n if (!this.isEditable) return;\n\n this._bindClassEvent(html, \"a[data-roll]\", \"click\", TravellerCharacterSheet.#onRoll);\n this._bindClassEvent(html, \".cfg-characteristic\", \"click\", TravellerCharacterSheet.#onOpenCharacteristic);\n this._bindClassEvent(html, \".item-create\", \"click\", TravellerCharacterSheet.#onCreateItem);\n this._bindClassEvent(html, \".item-edit\", \"click\", TravellerCharacterSheet.#onEditItem);\n this._bindClassEvent(html, \".item-delete\", \"click\", TravellerCharacterSheet.#onDeleteItem);\n this._bindClassEvent(html, \".item-equip\", \"click\", TravellerCharacterSheet.#onEquipItem);\n this._bindClassEvent(html, \".item-storage-in\", \"click\", TravellerCharacterSheet.#onItemStorageIn);\n this._bindClassEvent(html, \".item-storage-out\", \"click\", TravellerCharacterSheet.#onItemStorageOut);\n this._bindClassEvent(html, \".software-eject\", \"click\", TravellerCharacterSheet.#onSoftwareEject);\n this._bindClassEvent(html, \".container-create\", \"click\", TravellerCharacterSheet.#onContainerCreate);\n this._bindClassEvent(html, \".container-edit\", \"click\", TravellerCharacterSheet.#onContainerEdit);\n this._bindClassEvent(html, \".container-delete\", \"click\", TravellerCharacterSheet.#onContainerDelete);\n this._bindClassEvent(html, \".traits-create\", \"click\", TravellerCharacterSheet.#onTraitCreate);\n this._bindClassEvent(html, \".traits-edit\", \"click\", TravellerCharacterSheet.#onTraitEdit);\n this._bindClassEvent(html, \".traits-delete\", \"click\", TravellerCharacterSheet.#onTraitDelete);\n this._bindClassEvent(html, \"[data-editor='open']\", \"click\", TravellerCharacterSheet.#onOpenEditor);\n html.querySelector(\"[name='config']\")?.addEventListener(\"click\", (ev) => TravellerCharacterSheet.#onOpenConfig.call(this, ev, ev.currentTarget));\n }\n\n /** Helper: bind a handler to all matching elements, with `this` set to the sheet instance */\n _bindClassEvent(html, selector, event, handler) {\n for (const el of html.querySelectorAll(selector)) {\n el.addEventListener(event, (ev) => handler.call(this, ev, ev.currentTarget));\n }\n }\n\n // =========================================================\n // Drag & Drop\n // =========================================================\n\n /** @override */\n async _onDrop(event) {\n event.preventDefault();\n event.stopImmediatePropagation();\n const dropData = MGT2Helper.getDataFromDropEvent(event);\n if (!dropData) return false;\n\n const sourceItemData = await MGT2Helper.getItemDataFromDropData(dropData);\n\n if (sourceItemData.type === \"species\") {\n const update = {\n system: {\n personal: {\n species: sourceItemData.name,\n speciesText: {\n description: sourceItemData.system.description,\n descriptionLong: sourceItemData.system.descriptionLong,\n },\n },\n },\n };\n update.system.personal.traits = this.actor.system.personal.traits.concat(sourceItemData.system.traits);\n\n if (sourceItemData.system.modifiers?.length > 0) {\n update.system.characteristics = {};\n for (let modifier of sourceItemData.system.modifiers) {\n if (MGT2Helper.hasValue(modifier, \"characteristic\") && MGT2Helper.hasValue(modifier, \"value\")) {\n const c = this.actor.system.characteristics[modifier.characteristic];\n const updateValue = { value: c.value + modifier.value };\n if (c.showMax) updateValue.max = c.max + modifier.value;\n update.system.characteristics[modifier.characteristic] = updateValue;\n }\n }\n }\n\n this.actor.update(update);\n return true;\n }\n\n if ([\"contact\", \"disease\", \"career\", \"talent\"].includes(sourceItemData.type)) {\n let transferData = {};\n try { transferData = sourceItemData.toJSON(); } catch (e) { transferData = sourceItemData; }\n delete transferData._id;\n delete transferData.id;\n await this.actor.createEmbeddedDocuments(\"Item\", [transferData]);\n return true;\n }\n\n if (![\"armor\", \"weapon\", \"computer\", \"container\", \"item\", \"equipment\"].includes(sourceItemData.type)) return false;\n\n const target = event.target.closest(\".table-row\");\n let targetId = null;\n let targetItem = null;\n if (target !== null) {\n targetId = target.dataset.itemId;\n targetItem = this.actor.getEmbeddedDocument(\"Item\", targetId);\n }\n\n let sourceItem = this.actor.getEmbeddedDocument(\"Item\", sourceItemData.id);\n if (sourceItem) {\n if (!targetItem) return false;\n if (sourceItem.id === targetId) return false;\n\n if (targetItem.type === \"item\" || targetItem.type === \"equipment\") {\n if (targetItem.system.subType === \"software\")\n await sourceItem.update({ \"system.software.computerId\": targetItem.system.software.computerId });\n else\n await sourceItem.update({ \"system.container.id\": targetItem.system.container.id });\n return true;\n } else if (targetItem.type === \"computer\") {\n await sourceItem.update({ \"system.software.computerId\": targetId });\n return true;\n } else if (targetItem.type === \"container\") {\n if (targetItem.system.locked && !game.user.isGM) {\n ui.notifications.error(\"Verrouillé\");\n } else {\n await sourceItem.update({ \"system.container.id\": targetId });\n return true;\n }\n }\n } else {\n let transferData = {};\n try { transferData = sourceItemData.toJSON(); } catch (e) { transferData = sourceItemData; }\n delete transferData._id;\n delete transferData.id;\n\n const recalcWeight = transferData.system.hasOwnProperty(\"weight\");\n\n if (transferData.system.hasOwnProperty(\"container\")) transferData.system.container.id = \"\";\n if (transferData.type === \"item\" && transferData.system.subType === \"software\") transferData.system.software.computerId = \"\";\n if (transferData.type === \"container\") transferData.system.onHand = true;\n if (transferData.system.hasOwnProperty(\"equipment\")) transferData.system.equipped = false;\n\n if (targetItem !== null) {\n if (transferData.type === \"item\" && transferData.system.subType === \"software\") {\n if (targetItem.type === \"item\" && targetItem.system.subType === \"software\")\n transferData.system.software.computerId = targetItem.system.software.computerId;\n else if (targetItem.type === \"computer\")\n transferData.system.software.computerId = targetItem._id;\n } else if ([\"armor\", \"computer\", \"equipment\", \"item\", \"weapon\"].includes(transferData.type)) {\n if (targetItem.type === \"container\") {\n if (!targetItem.system.locked || game.user.isGM)\n transferData.system.container.id = targetId;\n } else {\n transferData.system.container.id = targetItem.system.container.id;\n }\n }\n }\n\n await this.actor.createEmbeddedDocuments(\"Item\", [transferData]);\n if (recalcWeight) await this.actor.recalculateWeight();\n }\n return true;\n }\n\n // =========================================================\n // Actions (static private methods)\n // =========================================================\n\n static async #onCreateItem(event, target) {\n event.preventDefault();\n const data = {\n name: target.dataset.createName,\n type: target.dataset.typeItem,\n };\n if (target.dataset.subtype) {\n data.system = { subType: target.dataset.subtype };\n }\n const cls = getDocumentClass(\"Item\");\n return cls.create(data, { parent: this.actor });\n }\n\n static async #onEditItem(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n const item = this.actor.getEmbeddedDocument(\"Item\", li?.dataset.itemId);\n if (item) item.sheet.render(true);\n }\n\n static async #onDeleteItem(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n if (!li?.dataset.itemId) return;\n this.actor.deleteEmbeddedDocuments(\"Item\", [li.dataset.itemId]);\n }\n\n static async #onEquipItem(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n const item = this.actor.getEmbeddedDocument(\"Item\", li?.dataset.itemId);\n if (!item) return;\n await item.update({ \"system.equipped\": !item.system.equipped });\n }\n\n static async #onItemStorageIn(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n const item = this.actor.getEmbeddedDocument(\"Item\", li?.dataset.itemId);\n if (!item) return;\n\n if (item.type === \"container\") {\n await item.update({ \"system.onHand\": false });\n } else {\n const containers = this.actor.getContainers();\n let container;\n const dropInId = this.actor.system.containerDropIn;\n\n if (!dropInId) {\n container = containers.length === 0\n ? await getDocumentClass(\"Item\").create({ name: \"New container\", type: \"container\" }, { parent: this.actor })\n : containers[0];\n } else {\n container = containers.find(x => x._id === dropInId);\n }\n\n if (container?.system.locked && !game.user.isGM) {\n ui.notifications.error(\"Objet verrouillé\");\n return;\n }\n await item.update({ \"system.container.id\": container._id });\n }\n }\n\n static async #onItemStorageOut(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n const item = this.actor.getEmbeddedDocument(\"Item\", li?.dataset.itemId);\n if (!item) return;\n await item.update({ \"system.container.id\": \"\" });\n }\n\n static async #onSoftwareEject(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n const item = this.actor.getEmbeddedDocument(\"Item\", li?.dataset.itemId);\n if (!item) return;\n await item.update({ \"system.software.computerId\": \"\" });\n }\n\n static async #onContainerCreate(event) {\n event.preventDefault();\n const cls = getDocumentClass(\"Item\");\n return cls.create({ name: \"New container\", type: \"container\" }, { parent: this.actor });\n }\n\n static async #onContainerEdit(event) {\n event.preventDefault();\n const container = this.actor.getEmbeddedDocument(\"Item\", this.actor.system.containerView);\n if (container) container.sheet.render(true);\n }\n\n static async #onContainerDelete(event) {\n event.preventDefault();\n const containers = this.actor.getContainers();\n const container = containers.find(x => x._id === this.actor.system.containerView);\n if (!container) return;\n\n const containerItems = this.actor.items.filter(\n x => x.system.hasOwnProperty(\"container\") && x.system.container.id === container._id\n );\n\n if (containerItems.length > 0) {\n const updates = containerItems.map(item => ({ _id: item.id, \"system.container.id\": \"\" }));\n await this.actor.updateEmbeddedDocuments(\"Item\", updates);\n }\n\n const actorUpdate = { \"system.containerView\": \"\" };\n if (this.actor.system.containerDropIn === container._id) {\n actorUpdate[\"system.containerDropIn\"] = \"\";\n const remaining = containers.filter(x => x._id !== container._id);\n if (remaining.length > 0) actorUpdate[\"system.containerDropIn\"] = remaining[0]._id;\n }\n\n await this.actor.deleteEmbeddedDocuments(\"Item\", [container._id]);\n await this.actor.update(actorUpdate);\n }\n\n static async #onRoll(event, target) {\n event.preventDefault();\n\n const rollOptions = {\n rollTypeName: game.i18n.localize(\"MGT2.RollPrompt.Roll\"),\n rollObjectName: \"\",\n characteristics: [{ _id: \"\", name: \"\" }],\n characteristic: \"\",\n skills: [],\n skill: \"\",\n fatigue: this.actor.system.states.fatigue,\n encumbrance: this.actor.system.states.encumbrance,\n difficulty: null,\n damageFormula: null,\n };\n\n const cardButtons = [];\n for (const [key, label] of Object.entries(MGT2.Characteristics)) {\n const c = this.actor.system.characteristics[key];\n if (c.show) {\n rollOptions.characteristics.push({\n _id: key,\n name: game.i18n.localize(label) + MGT2Helper.getDisplayDM(c.dm),\n });\n }\n }\n\n for (let item of this.actor.items) {\n if (item.type === \"talent\" && item.system.subType === \"skill\")\n rollOptions.skills.push({ _id: item._id, name: item.getRollDisplay() });\n }\n\n rollOptions.skills.sort(MGT2Helper.compareByName);\n rollOptions.skills = [{ _id: \"NP\", name: game.i18n.localize(\"MGT2.Items.NotProficient\") }].concat(rollOptions.skills);\n\n let itemObj = null;\n let isInitiative = false;\n const rollType = target.dataset.roll;\n\n if (rollType === \"initiative\") {\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.RollPrompt.InitiativeRoll\");\n rollOptions.characteristic = this.actor.system.config.initiative;\n isInitiative = true;\n } else if (rollType === \"characteristic\") {\n rollOptions.characteristic = target.dataset.rollCharacteristic;\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.RollPrompt.CharacteristicRoll\");\n rollOptions.rollObjectName = game.i18n.localize(`MGT2.Characteristics.${rollOptions.characteristic}.name`);\n } else {\n if (rollType === \"skill\") {\n rollOptions.skill = target.dataset.rollSkill;\n itemObj = this.actor.getEmbeddedDocument(\"Item\", rollOptions.skill);\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.RollPrompt.SkillRoll\");\n rollOptions.rollObjectName = itemObj.name;\n } else if (rollType === \"psionic\") {\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.RollPrompt.PsionicRoll\");\n }\n\n if (itemObj === null && target.dataset.itemId) {\n itemObj = this.actor.getEmbeddedDocument(\"Item\", target.dataset.itemId);\n rollOptions.rollObjectName = itemObj.name;\n if (itemObj.type === \"weapon\") rollOptions.rollTypeName = game.i18n.localize(\"TYPES.Item.weapon\");\n else if (itemObj.type === \"armor\") rollOptions.rollTypeName = game.i18n.localize(\"TYPES.Item.armor\");\n else if (itemObj.type === \"computer\") rollOptions.rollTypeName = game.i18n.localize(\"TYPES.Item.computer\");\n }\n\n if (rollType === \"psionic\" && itemObj) {\n rollOptions.rollObjectName = itemObj.name;\n if (MGT2Helper.hasValue(itemObj.system.psionic, \"duration\")) {\n cardButtons.push({\n label: game.i18n.localize(\"MGT2.Items.Duration\"),\n formula: itemObj.system.psionic.duration,\n message: {\n objectName: itemObj.name,\n flavor: \"{0} \".concat(game.i18n.localize(`MGT2.Durations.${itemObj.system.psionic.durationUnit}`)),\n },\n });\n }\n }\n\n if (itemObj?.system.hasOwnProperty(\"damage\")) {\n rollOptions.damageFormula = itemObj.system.damage;\n if (itemObj.type === \"disease\") {\n if (itemObj.system.subType === \"disease\")\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.DiseaseSubType.disease\");\n else if (itemObj.system.subType === \"poison\")\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.DiseaseSubType.poison\");\n }\n }\n\n if (itemObj?.system.hasOwnProperty(\"roll\")) {\n if (MGT2Helper.hasValue(itemObj.system.roll, \"characteristic\")) rollOptions.characteristic = itemObj.system.roll.characteristic;\n if (MGT2Helper.hasValue(itemObj.system.roll, \"skill\")) rollOptions.skill = itemObj.system.roll.skill;\n if (MGT2Helper.hasValue(itemObj.system.roll, \"difficulty\")) rollOptions.difficulty = itemObj.system.roll.difficulty;\n }\n }\n\n const userRollData = await RollPromptHelper.roll(rollOptions);\n\n const rollModifiers = [];\n const rollFormulaParts = [];\n\n if (userRollData.diceModifier) {\n rollFormulaParts.push(\"3d6\", userRollData.diceModifier);\n } else {\n rollFormulaParts.push(\"2d6\");\n }\n\n if (userRollData.characteristic) {\n const c = this.actor.system.characteristics[userRollData.characteristic];\n rollFormulaParts.push(MGT2Helper.getFormulaDM(c.dm));\n rollModifiers.push(game.i18n.localize(`MGT2.Characteristics.${userRollData.characteristic}.name`) + MGT2Helper.getDisplayDM(c.dm));\n }\n\n if (userRollData.skill) {\n if (userRollData.skill === \"NP\") {\n rollFormulaParts.push(\"-3\");\n rollModifiers.push(game.i18n.localize(\"MGT2.Items.NotProficient\"));\n } else {\n const skillObj = this.actor.getEmbeddedDocument(\"Item\", userRollData.skill);\n rollFormulaParts.push(MGT2Helper.getFormulaDM(skillObj.system.level));\n rollModifiers.push(skillObj.getRollDisplay());\n }\n }\n\n if (userRollData.psionic) {\n const psionicObj = this.actor.getEmbeddedDocument(\"Item\", userRollData.psionic);\n rollFormulaParts.push(MGT2Helper.getFormulaDM(psionicObj.system.level));\n rollModifiers.push(psionicObj.getRollDisplay());\n }\n\n if (userRollData.timeframes && userRollData.timeframes !== \"\" && userRollData.timeframes !== \"Normal\") {\n rollModifiers.push(game.i18n.localize(`MGT2.Timeframes.${userRollData.timeframes}`));\n rollFormulaParts.push(userRollData.timeframes === \"Slower\" ? \"+2\" : \"-2\");\n }\n\n if (userRollData.encumbrance === true) {\n rollFormulaParts.push(\"-2\");\n rollModifiers.push(game.i18n.localize(\"MGT2.Actor.Encumbrance\") + \" -2\");\n }\n\n if (userRollData.fatigue === true) {\n rollFormulaParts.push(\"-2\");\n rollModifiers.push(game.i18n.localize(\"MGT2.Actor.Fatigue\") + \" -2\");\n }\n\n if (userRollData.customDM) {\n const s = userRollData.customDM.trim();\n if (/^[0-9]/.test(s)) rollFormulaParts.push(\"+\");\n rollFormulaParts.push(s);\n }\n\n if (MGT2Helper.hasValue(userRollData, \"difficulty\")) rollOptions.difficulty = userRollData.difficulty;\n\n const rollFormula = rollFormulaParts.join(\"\");\n if (!Roll.validate(rollFormula)) {\n ui.notifications.error(game.i18n.localize(\"MGT2.Errors.InvalidRollFormula\"));\n return;\n }\n\n let roll = await new Roll(rollFormula, this.actor.getRollData()).roll({ rollMode: userRollData.rollMode });\n\n if (isInitiative && this.token?.combatant) {\n await this.token.combatant.update({ initiative: roll.total });\n }\n\n const chatData = {\n user: game.user.id,\n speaker: this.actor ? ChatMessage.getSpeaker({ actor: this.actor }) : null,\n formula: roll._formula,\n tooltip: await roll.getTooltip(),\n total: Math.round(roll.total * 100) / 100,\n showButtons: true,\n showLifeButtons: false,\n showRollRequest: false,\n rollTypeName: rollOptions.rollTypeName,\n rollObjectName: rollOptions.rollObjectName,\n rollModifiers: rollModifiers,\n showRollDamage: rollOptions.damageFormula !== null && rollOptions.damageFormula !== \"\",\n cardButtons: cardButtons,\n };\n\n if (MGT2Helper.hasValue(rollOptions, \"difficulty\")) {\n chatData.rollDifficulty = rollOptions.difficulty;\n chatData.rollDifficultyLabel = MGT2Helper.getDifficultyDisplay(rollOptions.difficulty);\n if (roll.total >= MGT2Helper.getDifficultyValue(rollOptions.difficulty))\n chatData.rollSuccess = true;\n else\n chatData.rollFailure = true;\n }\n\n const html = await foundry.applications.handlebars.renderTemplate(\"systems/mgt2/templates/chat/roll.html\", chatData);\n chatData.content = html;\n\n let flags = null;\n if (rollOptions.damageFormula) {\n flags = { mgt2: { damage: { formula: rollOptions.damageFormula, rollObjectName: rollOptions.rollObjectName, rollTypeName: rollOptions.rollTypeName } } };\n }\n if (cardButtons.length > 0) {\n if (!flags) flags = { mgt2: {} };\n flags.mgt2.buttons = cardButtons;\n }\n if (flags) chatData.flags = flags;\n\n return roll.toMessage(chatData);\n }\n\n static async #onOpenConfig(event) {\n event.preventDefault();\n const userConfig = await CharacterPrompts.openConfig(this.actor.system);\n if (userConfig) this.actor.update({ \"system.config\": userConfig });\n }\n\n static async #onOpenCharacteristic(event, target) {\n event.preventDefault();\n const name = target.dataset.cfgCharacteristic;\n const c = this.actor.system.characteristics[name];\n\n let showAll = false;\n for (const value of Object.values(this.actor.system.characteristics)) {\n if (!value.show) { showAll = true; break; }\n }\n\n const userConfig = await CharacterPrompts.openCharacteristic(\n game.i18n.localize(`MGT2.Characteristics.${name}.name`),\n c.show, c.showMax, showAll\n );\n\n if (userConfig) {\n const data = { system: { characteristics: {} } };\n data.system.characteristics[name] = { show: userConfig.show, showMax: userConfig.showMax };\n\n if (userConfig.showAll === true) {\n for (const [key, value] of Object.entries(this.actor.system.characteristics)) {\n if (key !== name && !value.show)\n data.system.characteristics[key] = { show: true };\n }\n }\n this.actor.update(data);\n }\n }\n\n static async #onTraitCreate(event) {\n event.preventDefault();\n let traits = this.actor.system.personal.traits;\n let newTraits;\n if (traits.length === 0) {\n newTraits = [{ name: \"\", description: \"\" }];\n } else {\n newTraits = [...traits, { name: \"\", description: \"\" }];\n }\n return this.actor.update({ system: { personal: { traits: newTraits } } });\n }\n\n static async #onTraitEdit(event, target) {\n event.preventDefault();\n const element = target.closest(\"[data-traits-part]\");\n const index = Number(element.dataset.traitsPart);\n const trait = this.actor.system.personal.traits[index];\n const result = await CharacterPrompts.openTraitEdit(trait);\n const traits = [...this.actor.system.personal.traits];\n traits[index] = { ...traits[index], name: result.name, description: result.description };\n return this.actor.update({ system: { personal: { traits: traits } } });\n }\n\n static async #onTraitDelete(event, target) {\n event.preventDefault();\n const element = target.closest(\"[data-traits-part]\");\n const index = Number(element.dataset.traitsPart);\n const traits = foundry.utils.deepClone(this.actor.system.personal.traits);\n const newTraits = Object.entries(traits)\n .filter(([key]) => Number(key) !== index)\n .map(([, value]) => value);\n return this.actor.update({ system: { personal: { traits: newTraits } } });\n }\n\n static async #onOpenEditor(event) {\n event.preventDefault();\n await CharacterPrompts.openEditorFullView(\n this.actor.system.personal.species,\n this.actor.system.personal.speciesText.descriptionLong\n );\n }\n}\n","import MGT2ActorSheet from \"./base-actor-sheet.mjs\";\n\nexport default class TravellerVehiculeSheet extends MGT2ActorSheet {\n\n /** @override */\n static DEFAULT_OPTIONS = {\n ...super.DEFAULT_OPTIONS,\n classes: [...super.DEFAULT_OPTIONS.classes, \"vehicule\", \"nopad\"],\n window: {\n ...super.DEFAULT_OPTIONS.window,\n title: \"TYPES.Actor.vehicule\",\n },\n }\n\n /** @override */\n static PARTS = {\n sheet: {\n template: \"systems/mgt2/templates/actors/vehicule-sheet.html\",\n },\n }\n\n /** @override */\n tabGroups = { primary: \"stats\" }\n}\n","import MGT2ActorSheet from \"./base-actor-sheet.mjs\";\n\n/** Convert Traveller dice notation (e.g. \"2D\", \"4D+2\", \"3D6\") to FoundryVTT formula */\nfunction normalizeDice(formula) {\n if (!formula) return \"1d6\";\n return formula\n .replace(/(\\d*)D(\\d*)([+-]\\d+)?/gi, (_, count, sides, mod) => {\n const n = count || \"1\";\n const d = sides || \"6\";\n return mod ? `${n}d${d}${mod}` : `${n}d${d}`;\n });\n}\n\nexport default class TravellerCreatureSheet extends MGT2ActorSheet {\n\n /** @override */\n static DEFAULT_OPTIONS = {\n ...super.DEFAULT_OPTIONS,\n classes: [...super.DEFAULT_OPTIONS.classes, \"creature\", \"nopad\"],\n position: {\n width: 720,\n height: 600,\n },\n window: {\n ...super.DEFAULT_OPTIONS.window,\n title: \"TYPES.Actor.creature\",\n },\n actions: {\n ...super.DEFAULT_OPTIONS.actions,\n rollAttack: TravellerCreatureSheet.#onRollAttack,\n rollSkill: TravellerCreatureSheet.#onRollSkill,\n addSkill: TravellerCreatureSheet.#onAddRow,\n deleteSkill: TravellerCreatureSheet.#onDeleteRow,\n addAttack: TravellerCreatureSheet.#onAddRow,\n deleteAttack: TravellerCreatureSheet.#onDeleteRow,\n addTrait: TravellerCreatureSheet.#onAddRow,\n deleteTrait: TravellerCreatureSheet.#onDeleteRow,\n },\n }\n\n /** @override */\n static PARTS = {\n sheet: {\n template: \"systems/mgt2/templates/actors/creature-sheet.html\",\n },\n }\n\n /** @override */\n tabGroups = { primary: \"skills\" }\n\n /** @override */\n async _prepareContext() {\n const context = await super._prepareContext();\n const actor = this.document;\n\n context.sizeLabel = this._getSizeLabel(actor.system.life.max);\n context.sizeTraitLabel = this._getSizeTrait(actor.system.life.max);\n context.config = CONFIG.MGT2;\n\n return context;\n }\n\n _getSizeLabel(pdv) {\n if (pdv <= 2) return \"Souris / Rat\";\n if (pdv <= 5) return \"Chat\";\n if (pdv <= 7) return \"Blaireau / Chien\";\n if (pdv <= 13) return \"Chimpanzé / Chèvre\";\n if (pdv <= 28) return \"Humain\";\n if (pdv <= 35) return \"Vache / Cheval\";\n if (pdv <= 49) return \"Requin\";\n if (pdv <= 70) return \"Rhinocéros\";\n if (pdv <= 90) return \"Éléphant\";\n if (pdv <= 125) return \"Carnosaure\";\n return \"Sauropode / Baleine\";\n }\n\n _getSizeTrait(pdv) {\n if (pdv <= 2) return \"Petit (−4)\";\n if (pdv <= 5) return \"Petit (−3)\";\n if (pdv <= 7) return \"Petit (−2)\";\n if (pdv <= 13) return \"Petit (−1)\";\n if (pdv <= 28) return \"—\";\n if (pdv <= 35) return \"Grand (+1)\";\n if (pdv <= 49) return \"Grand (+2)\";\n if (pdv <= 70) return \"Grand (+3)\";\n if (pdv <= 90) return \"Grand (+4)\";\n if (pdv <= 125) return \"Grand (+5)\";\n return \"Grand (+6)\";\n }\n\n // ───────────────────────────────────────────────────────── Roll Handlers\n\n /** Roll an attack (damage) with optional difficulty dialog */\n static async #onRollAttack(event, target) {\n const index = parseInt(target.dataset.index ?? 0);\n const actor = this.document;\n const attack = actor.system.attacks[index];\n if (!attack) return;\n\n const rollFormula = normalizeDice(attack.damage);\n\n const roll = await new Roll(rollFormula).evaluate();\n const total = roll.total;\n\n await roll.toMessage({\n speaker: ChatMessage.getSpeaker({ actor }),\n flavor: `${actor.name} — ${attack.name}`,\n rollMode: game.settings.get(\"core\", \"rollMode\"),\n });\n }\n\n /** Roll a skill check (2d6 + level vs difficulty) */\n static async #onRollSkill(event, target) {\n const index = parseInt(target.dataset.index ?? 0);\n const actor = this.document;\n const skill = actor.system.skills[index];\n if (!skill) return;\n\n const htmlContent = await renderTemplate(\n \"systems/mgt2/templates/actors/creature-roll-prompt.html\",\n {\n skillName: skill.name,\n skillLevel: skill.level,\n config: CONFIG.MGT2\n }\n );\n\n const result = await foundry.applications.api.DialogV2.wait({\n window: { title: game.i18n.localize(\"MGT2.Creature.RollSkill\") + \" — \" + skill.name },\n content: htmlContent,\n rejectClose: false,\n buttons: [\n {\n action: \"boon\",\n label: game.i18n.localize(\"MGT2.RollPrompt.Boon\"),\n callback: (event, button, dialog) => {\n const fd = new foundry.applications.ux.FormDataExtended(dialog.element.querySelector(\"form\")).object;\n fd.diceModifier = \"dl\";\n return fd;\n }\n },\n {\n action: \"roll\",\n label: game.i18n.localize(\"MGT2.RollPrompt.Roll\"),\n icon: '',\n default: true,\n callback: (event, button, dialog) =>\n new foundry.applications.ux.FormDataExtended(dialog.element.querySelector(\"form\")).object\n },\n {\n action: \"bane\",\n label: game.i18n.localize(\"MGT2.RollPrompt.Bane\"),\n callback: (event, button, dialog) => {\n const fd = new foundry.applications.ux.FormDataExtended(dialog.element.querySelector(\"form\")).object;\n fd.diceModifier = \"dh\";\n return fd;\n }\n }\n ]\n });\n\n if (!result) return;\n\n const dm = parseInt(result.dm ?? 0) + (skill.level ?? 0);\n const modifier = result.diceModifier ?? \"\";\n const difficultyTarget = parseInt(result.difficulty ?? 8);\n const difficultyLabel = result.difficultyLabel ?? \"\";\n\n const diceFormula = modifier ? `3d6${modifier}` : \"2d6\";\n const fullFormula = dm !== 0 ? `${diceFormula} + ${dm}` : diceFormula;\n\n const roll = await new Roll(fullFormula).evaluate();\n const success = roll.total >= difficultyTarget;\n\n const chatData = {\n creatureName: actor.name,\n creatureImg: actor.img,\n rollLabel: skill.name.toUpperCase(),\n formula: fullFormula,\n total: roll.total,\n tooltip: await roll.getTooltip(),\n difficulty: difficultyTarget,\n difficultyLabel,\n success,\n failure: !success,\n modifiers: dm !== 0 ? [`DM ${dm >= 0 ? \"+\" : \"\"}${dm}`] : [],\n };\n\n const chatContent = await renderTemplate(\n \"systems/mgt2/templates/chat/creature-roll.html\",\n chatData\n );\n\n await ChatMessage.create({\n content: chatContent,\n speaker: ChatMessage.getSpeaker({ actor }),\n rolls: [roll],\n rollMode: game.settings.get(\"core\", \"rollMode\"),\n });\n }\n\n // ───────────────────────────────────────────────────────── CRUD Handlers\n\n static async #onAddRow(event, target) {\n const prop = target.dataset.prop;\n if (!prop) return;\n const actor = this.document;\n const arr = foundry.utils.deepClone(actor.system[prop] ?? []);\n arr.push(this._getDefaultRow(prop));\n await actor.update({ [`system.${prop}`]: arr });\n }\n\n static async #onDeleteRow(event, target) {\n const prop = target.dataset.prop;\n const index = parseInt(target.dataset.index);\n if (!prop || isNaN(index)) return;\n const actor = this.document;\n const arr = foundry.utils.deepClone(actor.system[prop] ?? []);\n arr.splice(index, 1);\n await actor.update({ [`system.${prop}`]: arr });\n }\n\n _getDefaultRow(prop) {\n switch (prop) {\n case \"skills\": return { name: \"\", level: 0, note: \"\" };\n case \"attacks\": return { name: \"\", damage: \"1D\", description: \"\" };\n case \"traits\": return { name: \"\", value: \"\", description: \"\" };\n default: return {};\n }\n }\n}\n","const { HandlebarsApplicationMixin } = foundry.applications.api;\nimport { MGT2Helper } from \"../../helper.js\";\n\nexport default class TravellerItemSheet extends HandlebarsApplicationMixin(foundry.applications.sheets.ItemSheetV2) {\n\n /** @override */\n static DEFAULT_OPTIONS = {\n classes: [\"mgt2\", \"sheet\", \"item\"],\n position: { width: 630 },\n form: {\n submitOnChange: true,\n closeOnSubmit: false,\n },\n window: { resizable: true },\n actions: {\n careerEventCreate: TravellerItemSheet.#onCareerEventCreate,\n careerEventDelete: TravellerItemSheet.#onCareerEventDelete,\n optionCreate: TravellerItemSheet.#onOptionCreate,\n optionDelete: TravellerItemSheet.#onOptionDelete,\n modifierCreate: TravellerItemSheet.#onModifierCreate,\n modifierDelete: TravellerItemSheet.#onModifierDelete,\n },\n }\n\n /** Dynamic PARTS: template resolved per item type */\n get PARTS() {\n const type = this.document?.type ?? \"item\";\n return {\n sheet: {\n template: `systems/mgt2/templates/items/${type}-sheet.html`,\n },\n };\n }\n\n /** Resolve template dynamically based on item type */\n get template() {\n return `systems/mgt2/templates/items/${this.document.type}-sheet.html`;\n }\n\n tabGroups = { primary: \"tab1\" }\n\n /** @override */\n async _prepareContext() {\n const item = this.document;\n const source = item.toObject();\n\n const settings = {\n usePronouns: game.settings.get(\"mgt2\", \"usePronouns\"),\n };\n\n let containers = null;\n let computers = null;\n let hadContainer = false;\n\n if (item.actor !== null) {\n hadContainer = true;\n containers = [{ name: \"\", _id: \"\" }].concat(item.actor.getContainers());\n computers = [{ name: \"\", _id: \"\" }].concat(item.actor.getComputers());\n }\n\n let weight = null;\n if (item.system.hasOwnProperty(\"weight\")) {\n weight = MGT2Helper.convertWeightForDisplay(item.system.weight);\n }\n\n let skills = [];\n if (this.actor !== null) {\n for (let actorItem of this.actor.items) {\n if (actorItem.type === \"talent\" && actorItem.system.subType === \"skill\")\n skills.push({ _id: actorItem._id, name: actorItem.getRollDisplay() });\n }\n }\n skills.sort(MGT2Helper.compareByName);\n skills = [{ _id: \"NP\", name: game.i18n.localize(\"MGT2.Items.NotProficient\") }].concat(skills);\n\n return {\n item: item,\n document: item,\n cssClass: this.isEditable ? \"editable\" : \"locked\",\n system: item.system,\n source: source.system,\n fields: item.schema.fields,\n systemFields: item.system.schema.fields,\n isEditable: this.isEditable,\n isGM: game.user.isGM,\n config: CONFIG.MGT2,\n settings: settings,\n containers: containers,\n computers: computers,\n hadContainer: hadContainer,\n weight: weight,\n unitlabels: { weight: MGT2Helper.getWeightLabel() },\n skills: skills,\n };\n }\n\n /** @override — resolve the per-type template before rendering */\n async _renderHTML(context, options) {\n const templatePath = `systems/mgt2/templates/items/${this.document.type}-sheet.html`;\n const html = await foundry.applications.handlebars.renderTemplate(templatePath, context);\n return { sheet: html };\n }\n\n /** @override — put rendered HTML into the window content */\n _replaceHTML(result, content, options) {\n content.innerHTML = result.sheet;\n // Inject theme class dynamically (can't use game.settings in static DEFAULT_OPTIONS)\n const theme = game.settings.get(\"mgt2\", \"theme\");\n if (theme) this.element.classList.add(theme);\n this._activateTabGroups();\n this._bindItemEvents();\n }\n\n /** Bind CSS class-based events (templates not yet migrated to data-action) */\n _bindItemEvents() {\n const html = this.element;\n if (!this.isEditable) return;\n const bind = (sel, handler) => {\n for (const el of html.querySelectorAll(sel)) {\n el.addEventListener(\"click\", (ev) => handler.call(this, ev, ev.currentTarget));\n }\n };\n bind(\".event-create\", TravellerItemSheet.#onCareerEventCreate);\n bind(\".event-delete\", TravellerItemSheet.#onCareerEventDelete);\n bind(\".options-create\", TravellerItemSheet.#onOptionCreate);\n bind(\".options-delete\", TravellerItemSheet.#onOptionDelete);\n bind(\".modifiers-create\", TravellerItemSheet.#onModifierCreate);\n bind(\".modifiers-delete\", TravellerItemSheet.#onModifierDelete);\n }\n\n _activateTabGroups() {\n for (const [group, activeTab] of Object.entries(this.tabGroups)) {\n const nav = this.element.querySelector(`nav[data-group=\"${group}\"], .horizontal-tabs`);\n if (!nav) continue;\n\n nav.querySelectorAll('[data-tab]').forEach(link => {\n link.classList.toggle('active', link.dataset.tab === activeTab);\n link.addEventListener('click', event => {\n event.preventDefault();\n this.tabGroups[group] = link.dataset.tab;\n this.render();\n });\n });\n\n this.element.querySelectorAll(`.itemsheet-panel [data-tab], [data-group=\"${group}\"][data-tab]`).forEach(content => {\n content.classList.toggle('active', content.dataset.tab === activeTab);\n });\n }\n }\n\n /** @override — process form data before submit (weight/qty/cost conversions + container logic) */\n _prepareSubmitData(event, form, formData) {\n const data = foundry.utils.expandObject(formData.object);\n\n if (data.hasOwnProperty(\"weight\")) {\n data.system = data.system || {};\n data.system.weight = MGT2Helper.convertWeightFromInput(data.weight);\n delete data.weight;\n }\n\n if (data.system?.hasOwnProperty(\"quantity\")) {\n data.system.quantity = MGT2Helper.getIntegerFromInput(data.system.quantity);\n }\n\n if (data.system?.hasOwnProperty(\"cost\")) {\n data.system.cost = MGT2Helper.getIntegerFromInput(data.system.cost);\n }\n\n // Container/equipped logic\n if (data.system?.hasOwnProperty(\"container\") && this.document.system.hasOwnProperty(\"equipped\")) {\n const equippedChange = this.document.system.equipped !== data.system.equipped;\n const containerChange = this.document.system.container?.id !== data.system.container?.id;\n\n if (equippedChange && data.system.equipped === true) {\n data.system.container = { id: \"\" };\n } else if (containerChange && data.system.container?.id !== \"\" && this.document.system.container?.id === \"\") {\n data.system.equipped = false;\n }\n }\n\n return foundry.utils.flattenObject(data);\n }\n\n // =========================================================\n // Actions\n // =========================================================\n\n static async #onCareerEventCreate(event) {\n event.preventDefault();\n const events = this.document.system.events;\n let newEvents;\n if (!events || events.length === 0) {\n newEvents = [{ age: \"\", description: \"\" }];\n } else {\n newEvents = [...events, { age: \"\", description: \"\" }];\n }\n return this.document.update({ system: { events: newEvents } });\n }\n\n static async #onCareerEventDelete(event, target) {\n event.preventDefault();\n const element = target.closest(\"[data-events-part]\");\n const index = Number(element.dataset.eventsPart);\n const events = foundry.utils.deepClone(this.document.system.events);\n const newEvents = Object.entries(events)\n .filter(([key]) => Number(key) !== index)\n .map(([, val]) => val);\n return this.document.update({ system: { events: newEvents } });\n }\n\n static async #onOptionCreate(event, target) {\n event.preventDefault();\n const property = target.dataset.property;\n const options = this.document.system[property];\n let newOptions;\n if (!options || options.length === 0) {\n newOptions = [{ name: \"\", description: \"\" }];\n } else {\n newOptions = [...options, { name: \"\", description: \"\" }];\n }\n return this.document.update({ [`system.${property}`]: newOptions });\n }\n\n static async #onOptionDelete(event, target) {\n event.preventDefault();\n const element = target.closest(\"[data-options-part]\");\n const property = element.dataset.property;\n const index = Number(element.dataset.optionsPart);\n const options = foundry.utils.deepClone(this.document.system[property]);\n const newOptions = Object.entries(options)\n .filter(([key]) => Number(key) !== index)\n .map(([, val]) => val);\n return this.document.update({ [`system.${property}`]: newOptions });\n }\n\n static async #onModifierCreate(event) {\n event.preventDefault();\n const modifiers = this.document.system.modifiers;\n let newModifiers;\n if (!modifiers || modifiers.length === 0) {\n newModifiers = [{ characteristic: \"Endurance\", value: null }];\n } else {\n newModifiers = [...modifiers, { characteristic: \"Endurance\", value: null }];\n }\n return this.document.update({ system: { modifiers: newModifiers } });\n }\n\n static async #onModifierDelete(event, target) {\n event.preventDefault();\n const element = target.closest(\"[data-modifiers-part]\");\n const index = Number(element.dataset.modifiersPart);\n const modifiers = foundry.utils.deepClone(this.document.system.modifiers);\n const newModifiers = Object.entries(modifiers)\n .filter(([key]) => Number(key) !== index)\n .map(([, val]) => val);\n return this.document.update({ system: { modifiers: newModifiers } });\n }\n}\n","/**\n * Define a set of template paths to pre-load\n * Pre-loaded templates are compiled and cached for fast access when rendering\n * @return {Promise}\n */\nexport const preloadHandlebarsTemplates = async function() {\n\n const templatePaths = [\n \"systems/mgt2/templates/items/armor-sheet.html\",\n \"systems/mgt2/templates/items/career-sheet.html\",\n \"systems/mgt2/templates/items/computer-sheet.html\",\n \"systems/mgt2/templates/items/contact-sheet.html\",\n \"systems/mgt2/templates/items/container-sheet.html\",\n \"systems/mgt2/templates/items/disease-sheet.html\",\n \"systems/mgt2/templates/items/equipment-sheet.html\",\n \"systems/mgt2/templates/items/item-sheet.html\",\n \"systems/mgt2/templates/items/species-sheet.html\",\n \"systems/mgt2/templates/items/talent-sheet.html\",\n \"systems/mgt2/templates/items/weapon-sheet.html\",\n \"systems/mgt2/templates/items/parts/sheet-configuration.html\",\n \"systems/mgt2/templates/items/parts/sheet-physical-item.html\",\n \"systems/mgt2/templates/roll-prompt.html\",\n \"systems/mgt2/templates/chat/roll.html\",\n //\"systems/mgt2/templates/chat/roll-characteristic.html\",\n \"systems/mgt2/templates/actors/actor-config-sheet.html\",\n \"systems/mgt2/templates/actors/actor-config-characteristic-sheet.html\",\n \"systems/mgt2/templates/actors/trait-sheet.html\",\n \"systems/mgt2/templates/actors/creature-sheet.html\",\n \"systems/mgt2/templates/actors/creature-roll-prompt.html\",\n \"systems/mgt2/templates/chat/creature-roll.html\",\n \"systems/mgt2/templates/editor-fullview.html\"\n ];\n \n return loadTemplates(templatePaths);\n };","import { MGT2Helper } from \"./helper.js\";\n\nexport class ChatHelper {\n\n static setupCardListeners(message, element, messageData) {\n if (!message || !element) {\n return;\n }\n element.querySelectorAll('button[data-action=\"rollDamage\"]').forEach(el => {\n el.addEventListener('click', async event => {\n await this._processRollDamageButtonEvent(message, event);\n });\n });\n\n element.querySelectorAll('button[data-action=\"damage\"]').forEach(el => {\n el.addEventListener('click', async event => {\n await this._applyChatCardDamage(message, event);\n });\n });\n\n element.querySelectorAll('button[data-action=\"healing\"]').forEach(el => {\n el.addEventListener('click', async event => {\n ui.notifications.warn(\"healing\");\n });\n });\n\n element.querySelectorAll('button[data-index]').forEach(el => {\n el.addEventListener('click', async event => {\n await this._processRollButtonEvent(message, event);\n });\n });\n }\n\n static async _processRollButtonEvent(message, event) {\n event.preventDefault();\n event.stopPropagation();\n let buttons = message.flags.mgt2.buttons;\n const index = event.target.dataset.index;\n const button = buttons[index];\n let roll = await new Roll(button.formula, {}).roll();\n\n const chatData = {\n user: game.user.id,\n speaker: message.speaker,\n formula: roll._formula,\n tooltip: await roll.getTooltip(),\n total: Math.round(roll.total * 100) / 100,\n rollObjectName: button.message.objectName,\n rollMessage: MGT2Helper.format(button.message.flavor, Math.round(roll.total * 100) / 100),\n };\n\n const html = await foundry.applications.handlebars.renderTemplate(\"systems/mgt2/templates/chat/roll.html\", chatData);\n chatData.content = html;\n return roll.toMessage(chatData);\n }\n\n static async _processRollDamageButtonEvent(message, event) {\n event.preventDefault();\n event.stopPropagation();\n let rollFormula = message.flags.mgt2.damage.formula;\n\n let roll = await new Roll(rollFormula, {}).roll();\n\n let speaker;\n let selectTokens = canvas.tokens.controlled;\n if (selectTokens.length > 0) {\n speaker = selectTokens[0].actor;\n } else {\n speaker = game.user.character;\n }\n\n let rollTypeName = message.flags.mgt2.damage.rollTypeName ? message.flags.mgt2.damage.rollTypeName + \" \" + game.i18n.localize(\"MGT2.Actor.Damage\") : null;\n\n const chatData = {\n user: game.user.id,\n speaker: ChatMessage.getSpeaker({ actor: speaker }),\n formula: roll._formula,\n tooltip: await roll.getTooltip(),\n total: Math.round(roll.total * 100) / 100,\n showButtons: true,\n hasDamage: true,\n rollTypeName: rollTypeName,\n rollObjectName: message.flags.mgt2.damage.rollObjectName\n };\n\n const html = await foundry.applications.handlebars.renderTemplate(\"systems/mgt2/templates/chat/roll.html\", chatData);\n chatData.content = html;\n\n return roll.toMessage(chatData);\n }\n\n static _applyChatCardDamage(message, event) {\n const roll = message.rolls[0];\n return Promise.all(canvas.tokens.controlled.map(t => {\n const a = t.actor;\n return a.applyDamage(roll.total);\n }));\n }\n}","export const registerSettings = function () {\n\n game.settings.register(\"mgt2\", \"theme\", {\n name: \"MGT2.Settings.theme.name\",\n hint: \"MGT2.Settings.theme.hint\",\n scope: \"client\",\n config: true,\n default: \"black-and-red\",\n type: String,\n choices: {\n \"black-and-red\": \"MGT2.Themes.BlackAndRed\",\n \"mwamba\": \"MGT2.Themes.Mwamba\",\n \"blue\": \"MGT2.Themes.Blue\"\n },\n requiresReload: true\n });\n\n game.settings.register('mgt2', 'usePronouns', {\n name: \"MGT2.Settings.usePronouns.name\",\n hint: \"MGT2.Settings.usePronouns.hint\",\n default: false,\n scope: 'world',\n type: Boolean,\n config: true,\n requiresReload: false\n });\n\n game.settings.register('mgt2', 'useGender', {\n name: \"MGT2.Settings.useGender.name\",\n hint: \"MGT2.Settings.useGender.hint\",\n default: false,\n scope: 'world',\n type: Boolean,\n config: true,\n requiresReload: false\n });\n\n game.settings.register('mgt2', 'showLife', {\n name: \"MGT2.Settings.showLife.name\",\n hint: \"MGT2.Settings.showLife.hint\",\n default: false,\n scope: 'world',\n type: Boolean,\n config: true,\n requiresReload: false\n });\n\n // game.settings.register('mgt2', 'useWeightMetric', {\n // name: \"MGT2.Settings.useWeightMetric.name\",\n // hint: \"MGT2.Settings.useWeightMetric.hint\",\n // default: true,\n // scope: 'world',\n // type: Boolean,\n // config: true,\n // requiresReload: true\n // });\n\n // game.settings.register('mgt2', 'useDistanceMetric', {\n // name: \"MGT2.Settings.useDistanceMetric.name\",\n // hint: \"MGT2.Settings.useDistanceMetric.hint\",\n // default: true,\n // scope: 'world',\n // type: Boolean,\n // config: true,\n // requiresReload: true\n // });\n\n // game.settings.register('mgt2', 'showTrash', {\n // name: \"Show Trash tab to Player\",\n // hint: \"Player can see the Trash tab and recover item\",\n // default: false,\n // scope: 'world',\n // type: Boolean,\n // config: true,\n // requiresReload: false\n // });\n\n /*game.settings.register('mgt2', 'containerDropIn', {\n name: \"Test\",\n hint: \"Mon hint\",\n default: true,\n scope: 'client',\n type: Boolean,\n config: true\n });*/\n};\n","import {\n CharacterData,\n VehiculeData,\n CreatureData,\n ItemData,\n EquipmentData,\n DiseaseData,\n CareerData,\n TalentData,\n ContactData,\n ArmorData,\n ComputerData,\n WeaponData,\n ItemContainerData,\n SpeciesData\n} from \"./models/index.mjs\";\n\nimport { MGT2 } from \"./config.js\";\nimport { TravellerActor, MGT2Combatant } from \"./actors/actor.js\";\nimport { TravellerItem } from \"./item.js\";\nimport { TravellerItemSheet, TravellerCharacterSheet, TravellerVehiculeSheet, TravellerCreatureSheet } from \"./applications/sheets/_module.mjs\";\nimport { preloadHandlebarsTemplates } from \"./templates.js\";\n//import { MGT2Helper } from \"./helper.js\";\nimport {ChatHelper} from \"./chatHelper.js\";\n\n/* -------------------------------------------- */\n/* Foundry VTT Initialization */\n/* -------------------------------------------- */\nimport { registerSettings } from \"./settings.js\";\n\nfunction registerHandlebarsHelpers() {\n Handlebars.registerHelper('showDM', function (dm) {\n if (dm === 0) return \"0\";\n if (dm > 0) return `+${dm}`;\n if (dm < 0) return `${dm}`;\n return \"\";\n });\n}\n\nHooks.once(\"init\", async function () {\n CONFIG.MGT2 = MGT2;\n CONFIG.Combat.initiative = {\n formula: \"2d6 + @initiative\",\n decimals: 2\n };\n\n CONFIG.Actor.trackableAttributes = {\n character: {\n bar: [\"life\",\n \"characteristics.strength\",\n \"characteristics.dexterity\",\n \"characteristics.endurance\",\n \"characteristics.intellect\",\n \"characteristics.education\",\n \"characteristics.social\",\n \"characteristics.morale\",\n \"characteristics.luck\",\n \"characteristics.sanity\",\n \"characteristics.charm\",\n \"characteristics.psionic\",\n \"characteristics.other\"\n ],\n value: [\"life.value\",\n \"health.radiations\",\n \"characteristics.strength.value\",\n \"characteristics.dexterity.value\",\n \"characteristics.endurance.value\",\n \"characteristics.intellect.value\",\n \"characteristics.education.value\",\n \"characteristics.social.value\",\n \"characteristics.morale.value\",\n \"characteristics.luck.value\",\n \"characteristics.sanity.value\",\n \"characteristics.charm.value\",\n \"characteristics.psionic.value\",\n \"characteristics.other.value\"]\n },\n creature: {\n bar: [\"life\"],\n value: [\"life.value\", \"life.max\", \"speed\", \"armor\", \"psi\"]\n }\n };\n\n game.mgt2 = {\n TravellerActor,\n TravellerItem\n };\n\n registerHandlebarsHelpers();\n registerSettings();\n\n CONFIG.Combatant.documentClass = MGT2Combatant;\n CONFIG.Actor.documentClass = TravellerActor;\n CONFIG.Item.documentClass = TravellerItem;\n\n foundry.documents.collections.Actors.unregisterSheet(\"core\", foundry.appv1.sheets.ActorSheet);\n foundry.documents.collections.Actors.registerSheet(\"mgt2\", TravellerCharacterSheet, { types: [\"character\"], makeDefault: true, label: \"Traveller Sheet\" });\n foundry.documents.collections.Actors.registerSheet(\"mgt2\", TravellerVehiculeSheet, { types: [\"vehicule\"], makeDefault: true, label: \"Vehicule Sheet\" });\n foundry.documents.collections.Actors.registerSheet(\"mgt2\", TravellerCreatureSheet, { types: [\"creature\"], makeDefault: true, label: \"Creature Sheet\" });\n\n foundry.documents.collections.Items.unregisterSheet(\"core\", foundry.appv1.sheets.ItemSheet);\n foundry.documents.collections.Items.registerSheet(\"mgt2\", TravellerItemSheet, { makeDefault: true });\n\n Object.assign(CONFIG.Actor.dataModels, {\n \"character\": CharacterData,\n \"vehicule\": VehiculeData,\n \"creature\": CreatureData\n });\n\n Object.assign(CONFIG.Item.dataModels, {\n \"item\": ItemData,\n \"equipment\": EquipmentData,\n \"disease\": DiseaseData,\n \"career\": CareerData,\n \"talent\": TalentData,\n \"contact\": ContactData,\n \"weapon\": WeaponData,\n \"computer\": ComputerData,\n \"armor\": ArmorData,\n \"container\": ItemContainerData,\n \"species\": SpeciesData\n });\n\n\n Hooks.on(\"renderChatMessageHTML\", (message, element, messageData) => {\n ChatHelper.setupCardListeners(message, element, messageData);\n });\n\n // Preload template partials\n await preloadHandlebarsTemplates();\n});\n\nexport { MGT2 };"],"names":["fields","HandlebarsApplicationMixin","DialogV2","renderTemplate","FormDataExtended"],"mappings":"AAAA,MAAMA,QAAM,GAAG,OAAO,CAAC,IAAI,CAAC,MAAM;;AAE3B,SAAS,yBAAyB,CAAC,IAAI,GAAG,IAAI,EAAE,OAAO,GAAG,KAAK,EAAE;AACxE,IAAI,OAAO,IAAIA,QAAM,CAAC,WAAW,CAAC;AAClC,QAAQ,KAAK,EAAE,IAAIA,QAAM,CAAC,WAAW,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;AAC5F,QAAQ,GAAG,EAAE,IAAIA,QAAM,CAAC,WAAW,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;AAC3F,QAAQ,EAAE,EAAE,IAAIA,QAAM,CAAC,WAAW,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;AAClF,QAAQ,IAAI,EAAE,IAAIA,QAAM,CAAC,YAAY,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,CAA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CAAC,UAAU,EAAE;AACzC,IAAI,WAAW,EAAE,aAAa;AAC9B,IAAI,UAAU,EAAE,YAAY;AAC5B,IAAI,UAAU,EAAE;AAChB,GAAG,CAAC;;AAEJ,EAAE,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU,EAAE;AACxC,IAAI,MAAM,EAAE,QAAQ;AACpB,IAAI,WAAW,EAAE,aAAa;AAC9B,IAAI,SAAS,EAAE,WAAW;AAC1B,IAAI,QAAQ,EAAE,UAAU;AACxB,IAAI,QAAQ,EAAE,UAAU;AACxB,IAAI,SAAS,EAAE,WAAW;AAC1B,IAAI,QAAQ,EAAE,UAAU;AACxB,IAAI,UAAU,EAAE,YAAY;AAC5B,IAAI,OAAO,EAAE,SAAS;AACtB,IAAI,WAAW,EAAE,iBAAiB;AAClC,IAAI,SAAS,EAAE;AACf,GAAG,CAAC;;;AAGJ,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,EAAE,CAAC,OAAO,EAAE,OAAO,EAAE,WAAW,KAAK;AACvE,IAAI,UAAU,CAAC,kBAAkB,CAAC,OAAO,EAAE,OAAO,EAAE,WAAW,CAAC;AAChE,EAAE,CAAC,CAAC;;AAEJ;AACA,EAAE,MAAM,0BAA0B,EAAE;AACpC,CAAC,CAAC;;;;"}
\ No newline at end of file
+{"version":3,"file":"mgt2.bundle.js","sources":["src/module/models/items/base-item.mjs","src/module/models/character.mjs","src/module/models/vehicule.mjs","src/module/models/creature.mjs","src/module/models/items/item.mjs","src/module/models/items/equipment.mjs","src/module/models/items/disease.mjs","src/module/models/items/career.mjs","src/module/models/items/talent.mjs","src/module/models/items/contact.mjs","src/module/models/items/weapon.mjs","src/module/models/items/armor.mjs","src/module/models/items/computer.mjs","src/module/models/items/container.mjs","src/module/models/items/species.mjs","src/module/config.js","src/module/actors/character.js","src/module/actors/actor.js","src/module/item.js","src/module/applications/sheets/base-actor-sheet.mjs","src/module/helper.js","src/module/roll-prompt.js","src/module/actors/character-prompts.js","src/module/applications/sheets/character-sheet.mjs","src/module/applications/sheets/vehicule-sheet.mjs","src/module/applications/sheets/creature-sheet.mjs","src/module/applications/sheets/item-sheet.mjs","src/module/templates.js","src/module/chatHelper.js","src/module/settings.js","src/module/core.js"],"sourcesContent":["const fields = foundry.data.fields;\n\nexport function createCharacteristicField(show = true, showMax = false) {\n return new fields.SchemaField({\n value: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n max: new fields.NumberField({ required: false, initial: 0, min: 0, integer: true }),\n dm: new fields.NumberField({ required: false, initial: 0, integer: true }),\n show: new fields.BooleanField({ required: false, initial: show }),\n showMax: new fields.BooleanField({ required: false, initial: showMax })\n });\n}\n\nexport class ItemBaseData extends foundry.abstract.TypeDataModel {\n static defineSchema() {\n return {\n description: new fields.HTMLField({ required: false, blank: true, trim: true }),\n subType: new fields.StringField({ required: false, blank: false, nullable: true })\n };\n }\n}\n\nexport class PhysicalItemData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.quantity = new fields.NumberField({ required: true, initial: 1, min: 0, integer: true });\n schema.weight = new fields.NumberField({ required: true, initial: 0, min: 0, integer: false });\n schema.weightless = new fields.BooleanField({ required: false, initial: false });\n schema.cost = new fields.NumberField({ required: true, initial: 0, min: 0, integer: true });\n schema.tl = new fields.StringField({ required: true, blank: false, initial: \"TL12\" });\n schema.container = new fields.SchemaField({\n id: new fields.StringField({ required: false, blank: true })\n });\n schema.roll = new fields.SchemaField({\n characteristic: new fields.StringField({ required: false, blank: true, trim: true }),\n skill: new fields.StringField({ required: false, blank: true, trim: true }),\n difficulty: new fields.StringField({ required: false, blank: true, trim: true })\n });\n schema.trash = new fields.BooleanField({ required: false, initial: false });\n return schema;\n }\n}\n","import { createCharacteristicField } from \"./items/base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class CharacterData extends foundry.abstract.TypeDataModel {\n\n static defineSchema() {\n return {\n name: new fields.StringField({ required: false, blank: false, trim: true }),\n life: new fields.SchemaField({\n value: new fields.NumberField({ required: false, initial: 0, integer: true }),\n max: new fields.NumberField({ required: true, initial: 0, integer: true })\n }),\n personal: new fields.SchemaField({\n title: new fields.StringField({ required: false, blank: true, trim: true }),\n species: new fields.StringField({ required: false, blank: true, trim: true }),\n speciesText: new fields.SchemaField({\n description: new fields.StringField({ required: false, blank: true, trim: true, nullable: true }),\n descriptionLong: new fields.HTMLField({ required: false, blank: true, trim: true })\n }),\n age: new fields.StringField({ required: false, blank: true, trim: true }),\n gender: new fields.StringField({ required: false, blank: true, trim: true }),\n pronouns: new fields.StringField({ required: false, blank: true, trim: true }),\n homeworld: new fields.StringField({ required: false, blank: true, trim: true }),\n ucp: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n traits: new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n )\n }),\n biography: new fields.HTMLField({ required: false, blank: true, trim: true }),\n\n characteristics: new fields.SchemaField({\n strength: createCharacteristicField(true, true),\n dexterity: createCharacteristicField(true, true),\n endurance: createCharacteristicField(true, true),\n intellect: createCharacteristicField(true, false),\n education: createCharacteristicField(true, false),\n social: createCharacteristicField(true, false),\n morale: createCharacteristicField(true, false),\n luck: createCharacteristicField(true, false),\n sanity: createCharacteristicField(true, false),\n charm: createCharacteristicField(true, false),\n psionic: createCharacteristicField(true, false),\n other: createCharacteristicField(true, false)\n }),\n\n health: new fields.SchemaField({\n radiations: new fields.NumberField({ required: false, initial: 0, min: 0, integer: true }),\n lastFirstAidDate: new fields.StringField({ required: false, blank: true, trim: true }),\n healingRecoveryMode: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" })\n }),\n study: new fields.SchemaField({\n skill: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n total: new fields.NumberField({ required: false, initial: 0, min: 0, integer: true }),\n completed: new fields.NumberField({ required: false, initial: 0, min: 0, integer: true })\n }),\n finance: new fields.SchemaField({\n pension: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n credits: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n cashOnHand: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n debt: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n livingCost: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n monthlyShipPayments: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n notes: new fields.HTMLField({ required: false, blank: true, trim: true })\n }),\n containerView: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n containerDropIn: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n notes: new fields.HTMLField({ required: false, blank: true, trim: true }),\n\n inventory: new fields.SchemaField({\n armor: new fields.NumberField({ required: true, initial: 0, integer: true }),\n weight: new fields.NumberField({ required: true, initial: 0, min: 0, integer: false }),\n encumbrance: new fields.SchemaField({\n normal: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n heavy: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true })\n })\n }),\n states: new fields.SchemaField({\n encumbrance: new fields.BooleanField({ required: false, initial: false }),\n fatigue: new fields.BooleanField({ required: false, initial: false }),\n unconscious: new fields.BooleanField({ required: false, initial: false }),\n surgeryRequired: new fields.BooleanField({ required: false, initial: false })\n }),\n\n config: new fields.SchemaField({\n psionic: new fields.BooleanField({ required: false, initial: true }),\n initiative: new fields.StringField({ required: false, blank: true, initial: \"dexterity\" }),\n damages: new fields.SchemaField({\n rank1: new fields.StringField({ required: false, blank: true, initial: \"strength\" }),\n rank2: new fields.StringField({ required: false, blank: true, initial: \"dexterity\" }),\n rank3: new fields.StringField({ required: false, blank: true, initial: \"endurance\" })\n })\n })\n };\n }\n}\n","const fields = foundry.data.fields;\n\nexport default class VehiculeData extends foundry.abstract.TypeDataModel {\n\n static defineSchema() {\n return {\n name: new fields.StringField({ required: false, blank: false, trim: true }),\n skillId: new fields.StringField({ required: false, initial: \"\", blank: true, trim: true }),\n speed: new fields.SchemaField({\n cruise: new fields.StringField({ required: false, initial: \"Slow\", blank: true }),\n maximum: new fields.StringField({ required: false, initial: \"Medium\", blank: true })\n }),\n agility: new fields.NumberField({ required: false, min: 0, integer: true }),\n crew: new fields.NumberField({ required: false, min: 0, integer: true }),\n passengers: new fields.NumberField({ required: false, min: 0, integer: true }),\n cargo: new fields.NumberField({ required: false, min: 0, integer: false }),\n life: new fields.SchemaField({\n value: new fields.NumberField({ required: true, initial: 0, integer: true }),\n max: new fields.NumberField({ required: true, initial: 0, integer: true })\n }),\n shipping: new fields.NumberField({ required: false, min: 0, integer: true }),\n cost: new fields.NumberField({ required: false, min: 0, integer: true }),\n armor: new fields.SchemaField({\n front: new fields.NumberField({ required: true, initial: 0, integer: true }),\n rear: new fields.NumberField({ required: true, initial: 0, integer: true }),\n sides: new fields.NumberField({ required: true, initial: 0, integer: true })\n }),\n skills: new fields.SchemaField({\n autopilot: new fields.NumberField({ required: true, initial: 0, integer: true })\n }),\n description: new fields.HTMLField({ required: false, blank: true, trim: true }),\n notes: new fields.HTMLField({ required: false, blank: true, trim: true })\n };\n }\n}\n","const fields = foundry.data.fields;\n\nexport default class CreatureData extends foundry.abstract.TypeDataModel {\n\n static defineSchema() {\n return {\n life: new fields.SchemaField({\n value: new fields.NumberField({ required: true, initial: 10, min: 0, integer: true }),\n max: new fields.NumberField({ required: true, initial: 10, min: 0, integer: true })\n }),\n\n speed: new fields.NumberField({ required: true, initial: 6, min: 0, integer: true }),\n\n armor: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n\n psi: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),\n\n initiativeBonus: new fields.NumberField({ required: true, initial: 0, integer: true }),\n\n skills: new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true, initial: \"\" }),\n level: new fields.NumberField({ required: true, initial: 0, integer: true }),\n note: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" })\n })\n ),\n\n attacks: new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true, initial: \"\" }),\n damage: new fields.StringField({ required: true, blank: true, trim: true, initial: \"1D\" }),\n skill: new fields.NumberField({ required: false, initial: -1, integer: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" })\n })\n ),\n\n traits: new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true, initial: \"\" }),\n value: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n description: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" })\n })\n ),\n\n behavior: new fields.SchemaField({\n type: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n subtype: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" })\n }),\n\n biography: new fields.HTMLField({ required: false, blank: true, trim: true }),\n notes: new fields.HTMLField({ required: false, blank: true, trim: true }),\n };\n }\n\n /** @override */\n prepareDerivedData() {\n // Compute initiative bonus from Métabolisme traits\n let bonus = 0;\n for (const trait of this.traits) {\n const nameLower = trait.name.toLowerCase();\n if (nameLower.includes(\"métabolisme rapide\") || nameLower.includes(\"metabolisme rapide\")) {\n const val = parseInt(trait.value);\n if (!isNaN(val)) bonus += val;\n } else if (nameLower.includes(\"métabolisme lent\") || nameLower.includes(\"metabolisme lent\")) {\n const val = parseInt(trait.value);\n if (!isNaN(val)) bonus -= val;\n }\n }\n this.initiativeBonus = bonus;\n\n // Compute armor from Armure trait if not set manually\n if (this.armor === 0) {\n for (const trait of this.traits) {\n if (trait.name.toLowerCase().startsWith(\"armure\")) {\n const val = parseInt(trait.value);\n if (!isNaN(val)) {\n this.armor = val;\n break;\n }\n }\n }\n }\n\n // Compute PSI from Psionique trait\n if (this.psi === 0) {\n for (const trait of this.traits) {\n if (trait.name.toLowerCase().startsWith(\"psionique\")) {\n const val = parseInt(trait.value);\n if (!isNaN(val)) {\n this.psi = val;\n break;\n }\n }\n }\n }\n }\n}\n","import { PhysicalItemData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class ItemData extends PhysicalItemData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.subType.initial = \"loot\";\n schema.software = new fields.SchemaField({\n bandwidth: new fields.NumberField({ required: false, initial: 0, min: 0, max: 10, integer: true }),\n effect: new fields.StringField({ required: false, blank: true, trim: true, initial: \"\" }),\n computerId: new fields.StringField({ required: false, blank: true, initial: \"\" })\n });\n return schema;\n }\n}\n","import { PhysicalItemData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class EquipmentData extends PhysicalItemData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.equipped = new fields.BooleanField({ required: false, initial: false });\n schema.augment = new fields.SchemaField({\n improvement: new fields.StringField({ required: false, blank: true, trim: true })\n });\n schema.subType.initial = \"equipment\"; // augment, clothing, trinket, toolkit, equipment\n return schema;\n }\n}\n","import { ItemBaseData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class DiseaseData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.subType.initial = \"disease\"; // disease, poison\n schema.difficulty = new fields.StringField({ required: true, initial: \"Average\" });\n schema.damage = new fields.StringField({ required: false, blank: true });\n schema.interval = new fields.StringField({ required: false, blank: true });\n return schema;\n }\n}\n","import { ItemBaseData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class CareerData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.difficulty = new fields.NumberField({ required: true, initial: 0, min: 0, integer: true });\n schema.damage = new fields.StringField({ required: false, blank: true });\n schema.interval = new fields.StringField({ required: false, blank: true });\n schema.assignment = new fields.StringField({ required: false, blank: true });\n schema.terms = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.rank = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.events = new fields.ArrayField(\n new fields.SchemaField({\n age: new fields.NumberField({ required: false, integer: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n );\n return schema;\n }\n}\n","import { ItemBaseData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class TalentData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.subType.initial = \"skill\";\n schema.cost = new fields.NumberField({ required: true, initial: 0, min: 0, integer: true });\n schema.level = new fields.NumberField({ required: true, initial: 0, min: 0, integer: true });\n schema.skill = new fields.SchemaField({\n speciality: new fields.StringField({ required: false, blank: true, trim: true }),\n reduceEncumbrance: new fields.BooleanField({ required: false, initial: false })\n });\n schema.psionic = new fields.SchemaField({\n reach: new fields.StringField({ required: false, blank: true, trim: true }),\n cost: new fields.NumberField({ required: false, initial: 1, min: 0, integer: true }),\n duration: new fields.StringField({ required: false, blank: true, trim: true }),\n durationUnit: new fields.StringField({ required: false })\n });\n schema.roll = new fields.SchemaField({\n characteristic: new fields.StringField({ required: false, blank: true, trim: true }),\n skill: new fields.StringField({ required: false, blank: true, trim: true }),\n difficulty: new fields.StringField({ required: false, blank: true, trim: true })\n });\n return schema;\n }\n}\n","import { ItemBaseData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class ContactData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.subType.initial = \"skill\";\n schema.cost = new fields.NumberField({ required: true, initial: 1, min: 0, integer: true });\n schema.skill = new fields.SchemaField({\n speciality: new fields.StringField({ required: false, blank: true, trim: true }),\n characteristic: new fields.StringField({ required: false, blank: true, trim: true })\n });\n schema.status = new fields.StringField({ required: false, blank: true, trim: true, initial: \"Alive\" });\n schema.attitude = new fields.StringField({ required: false, blank: true, trim: true, initial: \"Unknow\" });\n schema.relation = new fields.StringField({ required: false, blank: true, trim: true, initial: \"Contact\" });\n schema.title = new fields.StringField({ required: false, blank: true, trim: true });\n schema.nickname = new fields.StringField({ required: false, blank: true, trim: true });\n schema.species = new fields.StringField({ required: false, blank: true, trim: true });\n schema.gender = new fields.StringField({ required: false, blank: true, trim: true });\n schema.pronouns = new fields.StringField({ required: false, blank: true, trim: true });\n schema.homeworld = new fields.StringField({ required: false, blank: true, trim: true });\n schema.location = new fields.StringField({ required: false, blank: true, trim: true });\n schema.occupation = new fields.StringField({ required: false, blank: true, trim: true });\n schema.notes = new fields.HTMLField({ required: false, blank: true, trim: true });\n return schema;\n }\n}\n","import { PhysicalItemData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class WeaponData extends PhysicalItemData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.equipped = new fields.BooleanField({ required: false, initial: false });\n schema.range = new fields.SchemaField({\n isMelee: new fields.BooleanField({ required: false, initial: false }),\n value: new fields.NumberField({ required: false, integer: true, nullable: true }),\n unit: new fields.StringField({ required: false, blank: true, nullable: true })\n });\n schema.damage = new fields.StringField({ required: false, blank: true, trim: true });\n schema.magazine = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.magazineCost = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.traits = new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n );\n schema.options = new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n );\n return schema;\n }\n}\n","import { PhysicalItemData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class ArmorData extends PhysicalItemData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.equipped = new fields.BooleanField({ required: false, initial: false });\n schema.radiations = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.protection = new fields.StringField({ required: false, blank: false, trim: true });\n // A Traveller suffers DM-1 to all checks per missing skill level in the required skill.\n schema.requireSkill = new fields.StringField({ required: false, blank: false });\n schema.requireSkillLevel = new fields.NumberField({ required: false, min: 0, integer: true });\n // Powered armour supports its own weight and is effectively weightless for encumbrance.\n schema.powered = new fields.BooleanField({ required: false, initial: false });\n schema.options = new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n );\n return schema;\n }\n}\n","import { PhysicalItemData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class ComputerData extends PhysicalItemData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.processing = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.processingUsed = new fields.NumberField({ required: false, initial: 0, min: 0, integer: true });\n schema.overload = new fields.BooleanField({ required: false, initial: false });\n schema.options = new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n );\n return schema;\n }\n}\n","import { ItemBaseData } from \"./base-item.mjs\";\nconst fields = foundry.data.fields;\n\nexport default class ItemContainerData extends ItemBaseData {\n static defineSchema() {\n const schema = super.defineSchema();\n schema.onHand = new fields.BooleanField({ required: false, initial: false });\n schema.location = new fields.StringField({ required: false, blank: true, trim: true });\n schema.count = new fields.NumberField({ required: false, initial: 0, integer: true });\n schema.weight = new fields.NumberField({ required: false, initial: 0, integer: false });\n schema.weightless = new fields.BooleanField({ required: false, initial: false });\n schema.locked = new fields.BooleanField({ required: false, initial: false }); // GM only\n schema.lockedDescription = new fields.HTMLField({ required: false, blank: true, trim: true });\n return schema;\n }\n}\n","const fields = foundry.data.fields;\n\nexport default class SpeciesData extends foundry.abstract.TypeDataModel {\n static defineSchema() {\n return {\n description: new fields.HTMLField({ required: false, blank: true, trim: true }),\n descriptionLong: new fields.HTMLField({ required: false, blank: true, trim: true }),\n traits: new fields.ArrayField(\n new fields.SchemaField({\n name: new fields.StringField({ required: true, blank: true, trim: true }),\n description: new fields.StringField({ required: false, blank: true, trim: true })\n })\n ),\n modifiers: new fields.ArrayField(\n new fields.SchemaField({\n characteristic: new fields.StringField({ required: false, blank: true, trim: true }),\n value: new fields.NumberField({ required: false, integer: true, nullable: true })\n })\n )\n };\n }\n}\n","export const MGT2 = {};\n\nMGT2.MetricRange = Object.freeze({\n meter: \"MGT2.MetricRange.meter\",\n kilometer: \"MGT2.MetricRange.kilometer\"\n});\n\nMGT2.MetricWeight = Object.freeze({\n kilogram: \"MGT2.MetricWeight.kilogram\",\n ton: \"MGT2.MetricWeight.ton\"\n});\n\nMGT2.Difficulty = Object.freeze({\n NA: \"MGT2.Difficulty.NA\",\n Simple: \"MGT2.Difficulty.Simple\",\n Easy: \"MGT2.Difficulty.Easy\",\n Routine: \"MGT2.Difficulty.Routine\",\n Average: \"MGT2.Difficulty.Average\",\n Difficult: \"MGT2.Difficulty.Difficult\",\n VeryDifficult: \"MGT2.Difficulty.VeryDifficult\",\n Formidable: \"MGT2.Difficulty.Formidable\",\n Impossible: \"MGT2.Difficulty.Impossible\"\n});\n\nMGT2.ItemSubType = Object.freeze({\n loot: \"MGT2.ItemSubType.loot\",\n software: \"MGT2.ItemSubType.software\"\n});\n\nMGT2.EquipmentSubType = Object.freeze({\n augment: \"MGT2.EquipmentSubType.augment\",\n clothing: \"MGT2.EquipmentSubType.clothing\",\n equipment: \"MGT2.EquipmentSubType.equipment\",\n trinket: \"MGT2.EquipmentSubType.trinket\",\n toolkit: \"MGT2.EquipmentSubType.toolkit\"\n});\n\nMGT2.TalentSubType = Object.freeze({\n skill: \"MGT2.TalentSubType.skill\",\n psionic: \"MGT2.TalentSubType.psionic\"\n});\n\nMGT2.DiseaseSubType = Object.freeze({\n disease: \"MGT2.DiseaseSubType.disease\",\n poison: \"MGT2.DiseaseSubType.poison\",\n wound: \"MGT2.DiseaseSubType.wound\"\n});\n\nMGT2.PsionicReach = Object.freeze({\n NA: \"MGT2.PsionicReach.NA\",\n Personal: \"MGT2.PsionicReach.Personal\",\n Close: \"MGT2.PsionicReach.Close\",\n Short: \"MGT2.PsionicReach.Short\",\n Medium: \"MGT2.PsionicReach.Medium\",\n Long: \"MGT2.PsionicReach.Long\",\n VeryLong: \"MGT2.PsionicReach.VeryLong\",\n Distant: \"MGT2.PsionicReach.Distant\",\n VeryDistant: \"MGT2.PsionicReach.VeryDistant\",\n Continental: \"MGT2.PsionicReach.Continental\",\n Planetary: \"MGT2.PsionicReach.Planetary\"\n});\n\nMGT2.ContactRelations = Object.freeze({\n Allie: \"MGT2.Contact.Relation.Allie\",\n Contact: \"MGT2.Contact.Relation.Contact\",\n Rival: \"MGT2.Contact.Relation.Rival\",\n Enemy: \"MGT2.Contact.Relation.Enemy\"\n});\n\nMGT2.ContactStatus = Object.freeze({\n Alive: \"MGT2.Contact.Status.Alive\",\n Unknow: \"MGT2.Contact.Status.Unknow\",\n Dead: \"MGT2.Contact.Status.Dead\"\n});\n\nMGT2.Attitudes = Object.freeze({\n Unknow: \"MGT2.Contact.Attitude.Unknow\",\n Hostile: \"MGT2.Contact.Attitude.Hostile\",\n Unfriendly: \"MGT2.Contact.Attitude.Unfriendly\",\n Indifferent: \"MGT2.Contact.Attitude.Indifferent\",\n Friendly: \"MGT2.Contact.Attitude.Friendly\",\n Helpful: \"MGT2.Contact.Attitude.Helpful\",\n Complicated: \"MGT2.Contact.Attitude.Complicated\"\n});\n\nMGT2.Characteristics = Object.freeze({\n strength: \"MGT2.Characteristics.strength.name\",\n dexterity: \"MGT2.Characteristics.dexterity.name\",\n endurance: \"MGT2.Characteristics.endurance.name\",\n intellect: \"MGT2.Characteristics.intellect.name\",\n education: \"MGT2.Characteristics.education.name\",\n social: \"MGT2.Characteristics.social.name\",\n morale: \"MGT2.Characteristics.morale.name\",\n luck: \"MGT2.Characteristics.luck.name\",\n sanity: \"MGT2.Characteristics.sanity.name\",\n charm: \"MGT2.Characteristics.charm.name\",\n psionic: \"MGT2.Characteristics.psionic.name\",\n other: \"MGT2.Characteristics.other.name\"\n});\n\nMGT2.InitiativeCharacteristics = Object.freeze({\n dexterity: \"MGT2.Characteristics.dexterity.name\",\n intellect: \"MGT2.Characteristics.intellect.name\"\n});\n\nMGT2.DamageCharacteristics = Object.freeze({\n strength: \"MGT2.Characteristics.strength.name\",\n dexterity: \"MGT2.Characteristics.dexterity.name\",\n endurance: \"MGT2.Characteristics.endurance.name\"\n});\n\nMGT2.TL = Object.freeze({\n NA: \"MGT2.TL.NA\",\n Unknow: \"MGT2.TL.Unknow\",\n NotIdentified: \"MGT2.TL.NotIdentified\",\n TL00: \"MGT2.TL.L00\",\n TL01: \"MGT2.TL.L01\",\n TL02: \"MGT2.TL.L02\",\n TL03: \"MGT2.TL.L03\",\n TL04: \"MGT2.TL.L04\",\n TL05: \"MGT2.TL.L05\",\n TL06: \"MGT2.TL.L06\",\n TL07: \"MGT2.TL.L07\",\n TL08: \"MGT2.TL.L08\",\n TL09: \"MGT2.TL.L09\",\n TL10: \"MGT2.TL.L10\",\n TL11: \"MGT2.TL.L11\",\n TL12: \"MGT2.TL.L12\",\n TL13: \"MGT2.TL.L13\",\n TL14: \"MGT2.TL.L14\",\n TL15: \"MGT2.TL.L15\"\n});\n\nMGT2.Timeframes = Object.freeze({\n Normal: \"MGT2.Timeframes.Normal\",\n Slower: \"MGT2.Timeframes.Slower\",\n Faster: \"MGT2.Timeframes.Faster\"\n});\n\nMGT2.SpeedBands = Object.freeze({\n Stoppped: \"MGT2.SpeedBands.Stoppped\",\n Idle: \"MGT2.SpeedBands.Idle\",\n VerySlow: \"MGT2.SpeedBands.VerySlow\",\n Slow: \"MGT2.SpeedBands.Slow\",\n Medium: \"MGT2.SpeedBands.Medium\",\n High: \"MGT2.SpeedBands.High\",\n Fast: \"MGT2.SpeedBands.Fast\",\n VeryFast: \"MGT2.SpeedBands.VeryFast\",\n Subsonic: \"MGT2.SpeedBands.Subsonic\",\n Hypersonic: \"MGT2.SpeedBands.Hypersonic\"\n});\n\nMGT2.Durations = Object.freeze({\n Seconds: \"MGT2.Durations.Seconds\",\n Minutes: \"MGT2.Durations.Minutes\",\n Heures: \"MGT2.Durations.Heures\"\n});\n\nMGT2.CreatureBehaviorType = Object.freeze({\n herbivore: \"MGT2.CreatureBehaviorType.herbivore\",\n carnivore: \"MGT2.CreatureBehaviorType.carnivore\",\n charognard: \"MGT2.CreatureBehaviorType.charognard\",\n omnivore: \"MGT2.CreatureBehaviorType.omnivore\"\n});\n\nMGT2.CreatureBehaviorSubType = Object.freeze({\n accumulateur: \"MGT2.CreatureBehaviorSubType.accumulateur\",\n brouteur: \"MGT2.CreatureBehaviorSubType.brouteur\",\n filtreur: \"MGT2.CreatureBehaviorSubType.filtreur\",\n intermittent: \"MGT2.CreatureBehaviorSubType.intermittent\",\n chasseur: \"MGT2.CreatureBehaviorSubType.chasseur\",\n detourneur: \"MGT2.CreatureBehaviorSubType.detourneux\",\n guetteur: \"MGT2.CreatureBehaviorSubType.guetteur\",\n mangeur: \"MGT2.CreatureBehaviorSubType.mangeur\",\n piegeur: \"MGT2.CreatureBehaviorSubType.piegeur\",\n intimidateur: \"MGT2.CreatureBehaviorSubType.intimidateur\",\n necrophage: \"MGT2.CreatureBehaviorSubType.necrophage\",\n reducteur: \"MGT2.CreatureBehaviorSubType.reducteur\",\n opportuniste: \"MGT2.CreatureBehaviorSubType.opportuniste\"\n});\n\nMGT2.HealingType = Object.freeze({\n FIRST_AID: \"MGT2.Healing.FirstAid\",\n SURGERY: \"MGT2.Healing.Surgery\",\n MEDICAL_CARE: \"MGT2.Healing.MedicalCare\",\n NATURAL_HEALING: \"MGT2.Healing.NaturalHealing\"\n});","export class ActorCharacter {\n static preCreate($this, data, options, user) {\n $this.updateSource({ prototypeToken: { actorLink: true } }) // QoL\n }\n\n static prepareData(actorData) {\n actorData.initiative = this.getInitiative(actorData);\n }\n\n static getInitiative($this) {\n let c = $this.system.config.initiative;\n return $this.system.characteristics[c].dm;\n }\n\n static async onDeleteDescendantDocuments($this, parent, collection, documents, ids, options, userId) {\n const toDeleteIds = [];\n const itemToUpdates = [];\n\n for (let d of documents) {\n if (d.type === \"container\") {\n // Delete content\n for (let item of $this.items) {\n if (item.system.hasOwnProperty(\"container\") && item.system.container.id === d._id)\n toDeleteIds.push(item._id);\n }\n } else if (d.type === \"computer\") {\n // Eject software\n for (let item of $this.items) {\n if (item.system.hasOwnProperty(\"software\") && item.system.computerId === d._id) {\n let clone = foundry.utils.deepClone(item);\n clone.system.software.computerId = \"\";\n itemToUpdates.push(clone);\n }\n }\n }\n }\n\n if (toDeleteIds.length > 0)\n await $this.deleteEmbeddedDocuments(\"Item\", toDeleteIds);\n\n if (itemToUpdates.length > 0)\n await $this.updateEmbeddedDocuments('Item', itemToUpdates);\n\n await this.recalculateWeight($this);\n }\n\n static async onUpdateDescendantDocuments($this, parent, collection, documents, changes, options, userId) {\n await this.calculEncumbranceAndWeight($this, parent, collection, documents, changes, options, userId);\n await this.calculComputers($this, parent, collection, documents, changes, options, userId);\n }\n\n static async calculComputers($this, parent, collection, documents, changes, options, userId) {\n let change;\n let i = 0;\n\n let recalculProcessing = false;\n for (let d of documents) {\n if (changes[i].hasOwnProperty(\"system\")) {\n change = changes[i];\n if (d.type === \"item\" && d.system.subType === \"software\") {\n if (change.system.software.hasOwnProperty(\"bandwidth\") || change.system.software.hasOwnProperty(\"computerId\")) {\n recalculProcessing = true;\n break;\n }\n }\n }\n }\n\n if (recalculProcessing) {\n let updatedComputers = [];\n let computerChanges = {};\n let computers = [];\n\n for (let item of $this.items) {\n if (item.system.trash === true) continue;\n if (item.type === \"computer\") {\n computers.push(item);\n computerChanges[item._id] = { processingUsed: 0 };\n }\n }\n\n for (let item of $this.items) {\n if (item.type !== \"item\" && item.system.subType !== \"software\") continue;\n\n if (item.system.software.hasOwnProperty(\"computerId\") && item.system.software.computerId !== \"\") {\n computerChanges[item.system.software.computerId].processingUsed += item.system.software.bandwidth;\n }\n }\n\n for (let computer of computers) {\n let newProcessingUsed = computerChanges[computer._id].processingUsed;\n if (computer.system.processingUsed !== newProcessingUsed) {\n const cloneComputer = foundry.utils.deepClone($this.getEmbeddedDocument(\"Item\", computer._id));\n cloneComputer.system.processingUsed = newProcessingUsed;\n cloneComputer.system.overload = cloneComputer.system.processingUsed > cloneComputer.system.processing;\n updatedComputers.push(cloneComputer);\n }\n }\n\n if (updatedComputers.length > 0) {\n await $this.updateEmbeddedDocuments('Item', updatedComputers);\n }\n }\n }\n\n static async calculEncumbranceAndWeight($this, parent, collection, documents, changes, options, userId) {\n let recalculEncumbrance = false;\n let recalculWeight = false;\n\n let change;\n let i = 0;\n for (let d of documents) {\n if (changes[i].hasOwnProperty(\"system\")) {\n change = changes[i];\n\n if (d.type === \"armor\" ||\n d.type === \"computer\" ||\n d.type === \"gear\" ||\n d.type === \"item\" ||\n d.type === \"weapon\") {\n if (change.system.hasOwnProperty(\"quantity\") ||\n change.system.hasOwnProperty(\"weight\") ||\n change.system.hasOwnProperty(\"weightless\") ||\n change.system.hasOwnProperty(\"container\") ||\n change.system.hasOwnProperty(\"equipped\") ||\n d.type === \"armor\") {\n recalculWeight = true;\n }\n } else if (d.type === \"talent\" && d.system.subType === \"skill\") {\n if (change.system.level || (change.system?.hasOwnProperty(\"skill\") && change.system?.skill.hasOwnProperty(\"reduceEncumbrance\"))) {\n recalculEncumbrance = true;\n }\n } else if (d.type === \"container\" && (change.system.hasOwnProperty(\"onHand\") || change.system.hasOwnProperty(\"weightless\"))) {\n recalculWeight = true;\n }\n }\n i++;\n }\n\n if (recalculEncumbrance || recalculWeight) {\n const updateData = {};\n\n this.recalculateArmor($this, updateData);\n\n if (recalculEncumbrance) {\n const str = $this.system.characteristics.strength.value;\n const end = $this.system.characteristics.endurance.value;\n let sumSkill = 0;\n $this.items.filter(x => x.type === \"talent\" && x.system.subType === \"skill\" && x.system.skill.reduceEncumbrance === true).forEach(x => sumSkill += x.system.level);\n let normal = str + end + sumSkill;\n let heavy = normal * 2;\n\n updateData[\"system.states.encumbrance\"] = $this.system.inventory.weight > normal;\n updateData[\"system.inventory.encumbrance.normal\"] = normal;\n updateData[\"system.inventory.encumbrance.heavy\"] = heavy;\n }\n\n if (recalculWeight)\n await this.recalculateWeight($this, updateData);\n else if (Object.keys(updateData).length > 0)\n await $this.update(updateData);\n }\n }\n\n static recalculateArmor($this, updateData) {\n if (updateData === null || updateData === undefined)\n updateData = {};\n\n let armor = 0;\n for (let item of $this.items) {\n if (item.type === \"armor\") {\n if (item.system.equipped === true && !isNaN(item.system.protection)) {\n armor += (+item.system.protection || 0);\n }\n }\n }\n\n updateData[\"system.inventory.armor\"] = armor;\n return updateData;\n }\n\n static async recalculateWeight($this, updateData) {\n\n if (updateData === null || updateData === undefined)\n updateData = {};\n\n let updatedContainers = [];\n let containerChanges = {};\n\n let containers = [];\n\n // List all containers\n for (let item of $this.items) {\n if (item.system.trash === true) continue;\n\n if (item.type === \"container\") {\n containers.push(item);\n containerChanges[item._id] = { count: 0, weight: 0 };\n }\n }\n\n let onHandWeight = 0;\n for (let item of $this.items) {\n if (item.type === \"container\") continue;\n if (item.system.hasOwnProperty(\"weightless\") && item.system.weightless === true) continue;\n\n let itemWeight = 0;\n if (item.system.hasOwnProperty(\"weight\")) {\n let itemQty = item.system.quantity;\n if (!isNaN(itemQty) && itemQty > 0) {\n itemWeight = item.system.weight;\n if (itemWeight > 0) {\n itemWeight *= itemQty;\n }\n }\n\n if (item.type === \"armor\") {\n if (item.system.equipped === true) {\n if (item.system.powered === true)\n itemWeight = 0;\n else\n itemWeight *= 0.25; // mass of armor that is being worn by 75% OPTIONAL\n }\n }\n\n if (item.system.container && item.system.container.id && item.system.container.id !== \"\") {\n // bad deleted container id\n if (containerChanges.hasOwnProperty(item.system.container.id)) {\n containerChanges[item.system.container.id].weight += Math.round(itemWeight * 10) / 10;\n containerChanges[item.system.container.id].count += item.system.quantity;\n }\n } else {\n onHandWeight += Math.round(itemWeight * 10) / 10;\n }\n }\n }\n\n // Check containers new weight\n for (let container of containers) {\n let newWeight = containerChanges[container._id].weight;\n let newCount = containerChanges[container._id].count;\n if (container.system.weight !== newWeight || container.system.count !== newCount) {\n updatedContainers.push({\n _id: container._id,\n \"system.weight\": newWeight,\n \"system.count\": newCount,\n });\n\n if (container.system.onHand === true &&\n (container.system.weight > 0 || container.system.weightless !== true)) {\n onHandWeight += container.system.weight;\n }\n }\n }\n\n updateData[\"system.inventory.weight\"] = onHandWeight;\n updateData[\"system.states.encumbrance\"] = onHandWeight > $this.system.inventory.encumbrance.normal;\n\n await $this.update(updateData);\n\n if (updatedContainers.length > 0) {\n await $this.updateEmbeddedDocuments('Item', updatedContainers);\n }\n }\n\n static async preUpdate($this, changed, options, user) {\n // Calc encumbrance\n\n const newStr = foundry.utils.getProperty(changed, \"system.characteristics.strength.value\") ?? $this.system.characteristics.strength.value;\n const newEnd = foundry.utils.getProperty(changed, \"system.characteristics.endurance.value\") ?? $this.system.characteristics.endurance.value;\n if ((newStr !== $this.system.characteristics.strength.value) || (newEnd !== $this.system.characteristics.endurance.value)) {\n let sumSkill = 0;\n $this.items.filter(x => x.type === \"talent\" && x.system.subType === \"skill\" && x.system.skill.reduceEncumbrance === true).forEach(x => sumSkill += x.system.level);\n let normal = newStr + newEnd + sumSkill;\n let heavy = normal * 2;\n foundry.utils.setProperty(changed, \"system.inventory.encumbrance.normal\", normal);\n foundry.utils.setProperty(changed, \"system.inventory.encumbrance.heavy\", heavy);\n }\n\n //console.log(foundry.utils.getProperty(changed, \"system.characteristics.strength.value\"));\n const characteristicModified = this.computeCharacteristics(changed);\n const strengthValue = foundry.utils.getProperty(changed, \"system.characteristics.strength.value\") ?? $this.system.characteristics.strength.value;\n const strengthMax = foundry.utils.getProperty(changed, \"system.characteristics.strength.max\") ?? $this.system.characteristics.strength.max;\n const dexterityValue = foundry.utils.getProperty(changed, \"system.characteristics.dexterity.value\") ?? $this.system.characteristics.dexterity.value;\n const dexterityMax = foundry.utils.getProperty(changed, \"system.characteristics.dexterity.max\") ?? $this.system.characteristics.dexterity.max;\n const enduranceValue = foundry.utils.getProperty(changed, \"system.characteristics.endurance.value\") ?? $this.system.characteristics.endurance.value;\n const enduranceMax = foundry.utils.getProperty(changed, \"system.characteristics.endurance.max\") ?? $this.system.characteristics.endurance.max;\n const lifeValue = strengthValue + dexterityValue + enduranceValue;\n const lifeMax = strengthMax + dexterityMax + enduranceMax;\n\n if ($this.system.life.value !== lifeValue)\n foundry.utils.setProperty(changed, \"system.life.value\", lifeValue);\n if ($this.system.life.max !== lifeMax)\n foundry.utils.setProperty(changed, \"system.life.max\", lifeMax);\n\n if (characteristicModified && $this.system.personal.ucp === undefined || $this.system.personal.ucp === \"\") {\n // calc\n\n }\n //}\n\n // Apply changes in Actor size to Token width/height\n // if ( \"size\" in (this.system.traits || {}) ) {\n // const newSize = foundry.utils.getProperty(changed, \"system.traits.size\");\n // if ( newSize && (newSize !== this.system.traits?.size) ) {\n // let size = CONFIG.DND5E.tokenSizes[newSize];\n // if ( !foundry.utils.hasProperty(changed, \"prototypeToken.width\") ) {\n // changed.prototypeToken ||= {};\n // changed.prototypeToken.height = size;\n // changed.prototypeToken.width = size;\n // }\n // }\n // }\n }\n\n // static applyHealing($this, amount) {\n // if (isNaN(amount) || amount === 0) return;\n\n // const strength = $this.system.characteristics.strength;\n // const dexterity = $this.system.characteristics.dexterity;\n // const endurance = $this.system.characteristics.endurance;\n\n // const data = {\n // strength: { value: strength.value },\n // dexterity: { value: dexterity.value },\n // endurance: { value: endurance.value }\n // };\n\n\n\n // $this.update({ system: { characteristics: data } });\n // }\n\n static applyDamage($this, amount, { ignoreArmor = false } = {}) {\n if (isNaN(amount) || amount === 0) return;\n const rank1 = $this.system.config.damages.rank1;\n const rank2 = $this.system.config.damages.rank2;\n const rank3 = $this.system.config.damages.rank3;\n\n const data = {};\n data[rank1] = { value: $this.system.characteristics[rank1].value };\n data[rank2] = { value: $this.system.characteristics[rank2].value };\n data[rank3] = { value: $this.system.characteristics[rank3].value };\n\n if (amount < 0) amount = Math.abs(amount);\n\n if (!ignoreArmor) {\n const armorValue = $this.system.inventory?.armor ?? 0;\n amount = Math.max(0, amount - armorValue);\n if (amount === 0) return;\n }\n\n for (const [key, rank] of Object.entries(data)) {\n if (rank.value > 0) {\n if (rank.value >= amount) {\n rank.value -= amount;\n amount = 0;\n } else {\n amount -= rank.value;\n rank.value = 0;\n }\n rank.dm = this.getModifier(rank.value);\n if (amount <= 0) break;\n }\n }\n\n $this.update({ system: { characteristics: data } });\n }\n\n static applyHealing($this, amount, type) {\n if (isNaN(amount) || amount === 0) return;\n\n const rank1 = $this.system.config.damages.rank1;\n const rank2 = $this.system.config.damages.rank2;\n const rank3 = $this.system.config.damages.rank3;\n\n // Data to restore (reverse cascade: END → DEX → STR)\n const data = {};\n const rankOrder = [rank3, rank2, rank1]; // Reverse order for healing\n const maxValues = {\n [rank1]: $this.system.characteristics[rank1].max,\n [rank2]: $this.system.characteristics[rank2].max,\n [rank3]: $this.system.characteristics[rank3].max\n };\n\n if (amount < 0) amount = Math.abs(amount);\n\n // Distribute healing from lowest rank first (END → DEX → STR typically)\n for (const rank of rankOrder) {\n const current = $this.system.characteristics[rank].value;\n const max = maxValues[rank];\n\n if (current < max && amount > 0) {\n const canRestore = max - current;\n const restore = Math.min(amount, canRestore);\n \n if (!data[rank]) {\n data[rank] = { value: current };\n }\n data[rank].value += restore;\n data[rank].dm = this.getModifier(data[rank].value);\n amount -= restore;\n }\n }\n\n // Only update if something was restored\n if (Object.keys(data).length > 0) {\n return $this.update({ system: { characteristics: data } });\n }\n }\n\n static getContainers($this) {\n const containers = [];\n for (let item of $this.items) {\n if (item.type == \"container\") {\n containers.push(item);\n }\n }\n\n containers.sort(this.compareByName);\n\n return containers;\n }\n\n static getComputers($this) {\n const containers = [];\n for (let item of $this.items) {\n if (item.type == \"computer\") {\n containers.push(item);\n }\n }\n\n containers.sort(this.compareByName);\n\n return containers;\n }\n\n static getSkills($this) {\n const skills = [];\n for (let item of $this.items) {\n if (item.type === \"talent\" && item.system.subType === \"skill\") {\n skills.push(item);\n }\n }\n\n skills.sort(this.compareByName);\n\n return skills;\n }\n\n static computeCharacteristics(changed) {\n let modified = this.computeCharacteristic(changed, \"strength\");\n\n if (this.computeCharacteristic(changed, \"dexterity\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"endurance\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"intellect\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"education\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"social\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"morale\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"luck\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"sanity\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"charm\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"psionic\") && !modified) modified = true;\n if (this.computeCharacteristic(changed, \"other\") && !modified) modified = true;\n\n return modified;\n }\n\n static computeCharacteristic(changed, name) {\n //if (isNaN(c.value) || c.value <= 0) c.value = 0;\n //c.dm = this._getModifier(c.value)\n const path = `system.characteristics.${name}`;\n const newValue = foundry.utils.getProperty(changed, path + \".value\");// || this.system.characteristics[name].value;\n if (newValue) {\n const dm = this.getModifier(newValue);\n foundry.utils.setProperty(changed, path + \".dm\", dm);\n return true;\n }\n\n return false;\n }\n\n static getModifier(value) {\n if (isNaN(value) || value <= 0) return -3;\n if (value >= 1 && value <= 2) return -2;\n if (value >= 3 && value <= 5) return -1;\n if (value >= 6 && value <= 8) return 0;\n if (value >= 9 && value <= 11) return 1;\n if (value >= 12 && value <= 14) return 2;\n\n return 3;\n }\n\n static compareByName(a, b) {\n if (!a.hasOwnProperty(\"name\") || !b.hasOwnProperty(\"name\")) {\n return 0;\n }\n return a.name.toLowerCase().localeCompare(b.name.toLowerCase());\n }\n}","import { ActorCharacter } from \"./character.js\";\n\nexport class MGT2Combatant extends Combatant {\n \n}\n\nexport class TravellerActor extends Actor {\n\n\n prepareDerivedData() {\n if (this.type === \"character\") {\n this.system.initiative = ActorCharacter.getInitiative(this);\n }\n }\n\n async _preCreate(data, options, user) {\n if ( (await super._preCreate(data, options, user)) === false ) return false;\n \n if (this.type === \"character\") {\n ActorCharacter.preCreate(this, data, options, user);\n }\n }\n\n async _onDeleteDescendantDocuments(parent, collection, documents, ids, options, userId) {\n await super._onDeleteDescendantDocuments(parent, collection, documents, ids, options, userId);\n\n if (this.type === \"character\") {\n await ActorCharacter.onDeleteDescendantDocuments(this, parent, collection, documents, ids, options, userId);\n }\n }\n\n async _onUpdateDescendantDocuments(parent, collection, documents, changes, options, userId) {\n super._onUpdateDescendantDocuments(parent, collection, documents, changes, options, userId);\n //console.log(\"_onUpdateDescendantDocuments\");\n\n if (this.type === \"character\") {\n await ActorCharacter.onUpdateDescendantDocuments(this, parent, collection, documents, changes, options, userId);\n }\n }\n\n async _preUpdate(changed, options, user) {\n if ((await super._preUpdate(changed, options, user)) === false) return false;\n\n if (this.type === \"character\") {\n await ActorCharacter.preUpdate(this, changed, options, user);\n }\n }\n\n getInitiative($this) {\n if (this.type === \"character\") {\n return ActorCharacter.getInitiative(this);\n }\n }\n\n applyDamage(amount, { ignoreArmor = false } = {}) {\n if (this.type === \"character\") {\n return ActorCharacter.applyDamage(this, amount, { ignoreArmor });\n } else if (this.type === \"creature\") {\n if (isNaN(amount) || amount === 0) return;\n if (amount < 0) amount = Math.abs(amount);\n const armorValue = ignoreArmor ? 0 : (this.system.armor ?? 0);\n const effective = Math.max(0, amount - armorValue);\n if (effective === 0) return;\n const newValue = Math.max(0, (this.system.life.value ?? 0) - effective);\n return this.update({ \"system.life.value\": newValue });\n }\n }\n\n applyHealing(amount) {\n if (this.type === \"character\") {\n return ActorCharacter.applyHealing(this, amount);\n } else if (this.type === \"creature\") {\n if (isNaN(amount) || amount === 0) return;\n if (amount < 0) amount = Math.abs(amount);\n const maxValue = this.system.life.max ?? 0;\n const current = this.system.life.value ?? 0;\n const newValue = Math.min(current + amount, maxValue);\n if (newValue !== current) {\n return this.update({ \"system.life.value\": newValue });\n }\n }\n }\n\n getContainers() {\n if (this.type === \"character\") {\n return ActorCharacter.getContainers(this);\n }\n\n return [];\n }\n\n getComputers() {\n if (this.type === \"character\") {\n return ActorCharacter.getComputers(this);\n }\n\n return [];\n }\n\n getSkills() {\n if (this.type === \"character\") {\n return ActorCharacter.getSkills(this);\n }\n\n return [];\n }\n\n async recalculateWeight() {\n if (this.type === \"character\") {\n return ActorCharacter.recalculateWeight(this);\n }\n }\n\n}\n","export class TravellerItem extends Item {\n\n /** @inheritdoc */\n prepareDerivedData() {\n super.prepareDerivedData();\n\n }\n\n async _preUpdate(changed, options, user) {\n if ((await super._preUpdate(changed, options, user)) === false) return false;\n\n if (this.type === \"computer\") {\n // Overload\n const newProcessing = foundry.utils.getProperty(changed, \"system.processing\") ?? this.system.processing;\n if (newProcessing !== this.system.processing) {\n let overload = this.system.processingUsed > newProcessing;\n foundry.utils.setProperty(changed, \"system.overload\", overload);\n }\n }\n\n // Qty max 1\n if (this.type === \"computer\" || this.type === \"container\" || (this.type === \"item\" && this.system.subType === \"software\")) {\n const newQty = foundry.utils.getProperty(changed, \"system.quantity\") ?? this.system.quantity;\n if (newQty !== this.system.quantity && newQty > 1) {\n foundry.utils.setProperty(changed, \"system.quantity\", 1);\n }\n }\n\n // No Weight\n if (this.type === \"item\" && this.system.subType === \"software\") {\n const newWeight = foundry.utils.getProperty(changed, \"system.weight\") ?? this.system.weight;\n if (newWeight !== this.system.weight && newWeight > 0) {\n foundry.utils.setProperty(changed, \"system.weight\", 0);\n }\n }\n }\n\n getRollDisplay() {\n if (this.type === \"talent\") {\n if (this.system.subType === \"skill\") {\n let label;\n if (this.system.skill.speciality !== \"\" && this.system.skill.speciality !== undefined) {\n label = `${this.name} (${this.system.skill.speciality})`;\n } else {\n label = this.name;\n }\n\n if (this.system.level > 0)\n label += ` (+${this.system.level})`;\n else if (this.system.level < 0)\n label += ` (${this.system.level})`;\n\n return label;\n } else if (this.system.subType === \"psionic\") {\n\n }\n }\n\n return name;\n }\n}\n","const { HandlebarsApplicationMixin } = foundry.applications.api;\n\nexport default class MGT2ActorSheet extends HandlebarsApplicationMixin(foundry.applications.sheets.ActorSheetV2) {\n\n static SHEET_MODES = { EDIT: 0, PLAY: 1 }\n\n constructor(options = {}) {\n super(options);\n this._sheetMode = this.constructor.SHEET_MODES.PLAY;\n }\n\n /** @override */\n static DEFAULT_OPTIONS = {\n classes: [\"mgt2\", \"sheet\", \"actor\"],\n position: {\n width: 780,\n },\n form: {\n submitOnChange: true,\n closeOnSubmit: false,\n },\n window: {\n resizable: true,\n },\n dragDrop: [{ dragSelector: \".drag-item-list\", dropSelector: \".drop-item-list\" }],\n actions: {\n toggleSheet: MGT2ActorSheet.#onToggleSheet,\n },\n }\n\n get isPlayMode() {\n if (this._sheetMode === undefined) this._sheetMode = this.constructor.SHEET_MODES.PLAY;\n return this._sheetMode === this.constructor.SHEET_MODES.PLAY;\n }\n\n get isEditMode() {\n if (this._sheetMode === undefined) this._sheetMode = this.constructor.SHEET_MODES.PLAY;\n return this._sheetMode === this.constructor.SHEET_MODES.EDIT;\n }\n\n tabGroups = { sidebar: \"health\" }\n\n /** @override */\n async _prepareContext() {\n const base = await super._prepareContext();\n const actor = this.document;\n return {\n ...base,\n actor: actor,\n // Flat shorthands for template backward-compat (AppV1 style)\n name: actor.name,\n img: actor.img,\n cssClass: this.isEditable ? \"editable\" : \"locked\",\n system: actor.system,\n source: actor.toObject(),\n fields: actor.schema.fields,\n systemFields: actor.system.schema.fields,\n isEditable: this.isEditable,\n isEditMode: this.isEditMode,\n isPlayMode: this.isPlayMode,\n isGM: game.user.isGM,\n config: CONFIG.MGT2,\n };\n }\n\n /** @override */\n _onRender(context, options) {\n super._onRender(context, options);\n // Inject theme class dynamically (can't use game.settings in static DEFAULT_OPTIONS)\n const theme = game.settings.get(\"mgt2\", \"theme\");\n if (theme) this.element.classList.add(theme);\n this._activateTabGroups();\n }\n\n _activateTabGroups() {\n for (const [group, activeTab] of Object.entries(this.tabGroups)) {\n const nav = this.element.querySelector(`nav[data-group=\"${group}\"]`);\n if (!nav) continue;\n\n nav.querySelectorAll('[data-tab]').forEach(link => {\n link.classList.toggle('active', link.dataset.tab === activeTab);\n link.addEventListener('click', event => {\n event.preventDefault();\n this.tabGroups[group] = link.dataset.tab;\n this.render();\n });\n });\n\n this.element.querySelectorAll(`[data-group=\"${group}\"][data-tab]`).forEach(content => {\n content.classList.toggle('active', content.dataset.tab === activeTab);\n });\n }\n }\n\n /** @override */\n _canDragDrop(selector) {\n return this.isEditable;\n }\n\n static async #onToggleSheet(event) {\n event.preventDefault();\n this._sheetMode = this.isPlayMode\n ? this.constructor.SHEET_MODES.EDIT\n : this.constructor.SHEET_MODES.PLAY;\n this.render();\n }\n}\n","export class MGT2Helper {\n static POUNDS_CONVERT = 2.20462262185;\n\n static decimalSeparator;\n static badDecimalSeparator;\n\n static {\n this.decimalSeparator = Number(1.1).toLocaleString().charAt(1);\n this.badDecimalSeparator = (this.decimalSeparator === \".\" ? \",\" : \".\");\n }\n\n static format = function() {\n var s = arguments[0];\n for (var i = 0; i < arguments.length - 1; i++) { \n var reg = new RegExp(\"\\\\{\" + i + \"\\\\}\", \"gm\"); \n s = s.replace(reg, arguments[i + 1]);\n }\n return s;\n }\n\n static hasValue(object, property) {\n return object !== undefined && object.hasOwnProperty(property) && object[property] !== null && object[property] !== undefined && object[property] !== \"\";\n }\n\n static getItemsWeight(items) {\n let weight = 0;\n for (let i of items) {\n let item = i.hasOwnProperty(\"system\") ? i.system : i;\n if (item.hasOwnProperty(\"weightless\") && item.weightless === true) {\n continue;\n }\n\n if (item.hasOwnProperty(\"weight\")) {\n let itemQty = item.quantity\n if (!isNaN(itemQty) && itemQty > 0) {\n let itemWeight = item.weight;\n if (itemWeight > 0) {\n weight += itemWeight * itemQty;\n }\n }\n }\n }\n return weight;\n }\n\n static generateUID() {\n let result = '';\n const characters = 'abcdefghijklmnopqrstuvwxyz0123456789';\n\n for (let i = 0; i < 36; i++) {\n const randomIndex = Math.floor(Math.random() * characters.length);\n result += characters.charAt(randomIndex);\n if (i === 8 || i === 12 || i === 16 || i === 20)\n result += \"-\";\n }\n\n return result;\n }\n\n static compareByName(a, b) {\n if (!a.hasOwnProperty(\"name\") || !b.hasOwnProperty(\"name\")) {\n return 0;\n }\n return a.name.toLowerCase().localeCompare(b.name.toLowerCase());\n }\n\n static getDisplayDM(dm) {\n if (dm === 0) return \" (0)\";\n if (dm > 0) return ` (+${dm})`;\n if (dm < 0) return ` (${dm})`;\n return \"\";\n }\n static getFormulaDM(dm) {\n if (dm === 0) return \"+0\";\n if (dm > 0) return `+${dm}`;\n if (dm < 0) return `${dm}`;\n return \"\";\n }\n\n static getDiceResults(roll) {\n const results = [];\n for (const die of roll.dice) {\n results.push(die.results);\n }\n return results.flat(2);\n }\n\n static getDiceTotal(roll) {\n let total = 0;\n for (const die of roll.dice) {\n total += die.total;\n }\n return total;\n }\n\n static getDifficultyValue(difficulty) {\n switch(difficulty) {\n case \"Simple\": return 2;\n case \"Easy\": return 4;\n case \"Routine\": return 6;\n case \"Average\": return 8;\n case \"Difficult\": return 10;\n case \"VeryDifficult\": return 12;\n case \"Formidable\": return 14;\n case \"Impossible\": return 16;\n default:\n return 0;\n }\n }\n\n static getDifficultyDisplay(difficulty) {\n const key = `MGT2.Difficulty.${difficulty}`;\n const label = game.i18n.localize(key);\n return label !== key ? label : null;\n }\n\n static getRangeDisplay(range) {\n let value = Number(range.value);\n\n if (isNaN(value)) return null;\n\n let label;\n //if (game.settings.get(\"mgt2\", \"useDistanceMetric\") === true) {\n if (range.unit !== null && range.unit !== undefined && range.unit !== \"\")\n label = game.i18n.localize(`MGT2.MetricRange.${range.unit}`).toLowerCase();\n else\n label = \"\";\n //} else {\n // TODO\n //}\n\n return `${value}${label}`;\n }\n\n static getWeightLabel() {\n //const label = game.settings.get(\"mgt2\", \"useWeightMetric\") === true ? \"MGT2.MetricSystem.Weight.kg\" : \"MGT2.ImperialSystem.Weight.lb\";\n //return game.i18n.localize(label);\n return game.i18n.localize(\"MGT2.MetricSystem.Weight.kg\");\n }\n\n static getDistanceLabel() {\n //const label = game.settings.get(\"mgt2\", \"useDistanceMetric\") === true ? \"MGT2.MetricSystem.Distance.km\" : \"MGT2.ImperialSystem.Distance.mi\";\n //return game.i18n.localize(label);\n return game.i18n.localize(\"MGT2.MetricSystem.Distance.km\");\n }\n\n static getIntegerFromInput(data) {\n return Math.trunc(this.getNumberFromInput(data));\n }\n\n static getNumberFromInput(data) {\n if (data === undefined || data === null) return 0;\n\n if (typeof data === \"string\") {\n let converted = Number(data.replace(/\\s+/g, '').replace(this.badDecimalSeparator, this.decimalSeparator).trim());\n if (isNaN(converted))\n return 0;\n\n return converted;\n }\n\n let converted = Number(data);\n\n if (isNaN(converted))\n return 0;\n\n return converted;\n }\n\n static convertWeightForDisplay(weight) {\n //if (game.settings.get(\"mgt2\", \"useWeightMetric\") === true || weight === 0)\n return weight;\n\n // Metric to Imperial\n //const pounds = weight * this.POUNDS_CONVERT;\n //return Math.round(pounds * 10) / 10;\n }\n\n static convertWeightFromInput(weight) {\n //if (game.settings.get(\"mgt2\", \"useWeightMetric\") === true || weight === 0)\n return Math.round(weight * 10) / 10;\n\n // Imperial to Metric\n //const kg = this.POUNDS_CONVERT / weight;\n //return Math.round(kg * 10) / 10;\n }\n\n static getDataFromDropEvent(event) {\n let data;\n try {\n return JSON.parse(event.dataTransfer?.getData(\"text/plain\"));\n } catch (err) {\n return false;\n }\n\n //if ( data.type !== \"Item\" ) return false;\n //const item = await Item.implementation.fromDropData(data);\n }\n\n static async getItemDataFromDropData(dropData) {\n //console.log(\"getItemDataFromDropData\");\n let item;\n if (game.modules.get(\"monks-enhanced-journal\")?.active && dropData.itemId && dropData.uuid.includes(\"JournalEntry\")) {\n const journalEntry = await fromUuid(dropData.uuid);\n } else if (dropData.hasOwnProperty(\"uuid\")) {\n item = await fromUuid(dropData.uuid);\n } else {\n let uuid = `${dropData.type}.${dropData.data._id}`;\n item = await fromUuid(uuid);\n }\n\n if (!item) {\n throw new Error(game.i18n.localize(\"Errors.CouldNotFindItem\").replace(\"_ITEM_ID_\", dropData.uuid));\n }\n if (item.pack) {\n const pack = game.packs.get(item.pack);\n item = await pack?.getDocument(item._id);\n }\n return deepClone(item);\n }\n}","const { DialogV2 } = foundry.applications.api;\nconst { renderTemplate } = foundry.applications.handlebars;\nconst { FormDataExtended } = foundry.applications.ux;\n\nexport class RollPromptHelper {\n\n static async roll(options) {\n // Backward compat: allow (actor, options) or just (options)\n if (options.rollTypeName || options.characteristics || options.skill !== undefined) {\n // Normal call with options\n } else {\n // Called with (actor, options)\n options = arguments[1] || options;\n }\n\n const htmlContent = await renderTemplate('systems/mgt2/templates/roll-prompt.html', {\n config: CONFIG.MGT2,\n // Character-mode fields\n characteristics: options.characteristics ?? [],\n characteristic: options.characteristic ?? \"\",\n skills: options.skills ?? [],\n skill: options.skill ?? \"\",\n fatigue: options.fatigue ?? false,\n encumbrance: options.encumbrance ?? false,\n difficulty: options.difficulty ?? \"Average\",\n timeframe: options.timeframe ?? \"Normal\",\n customDM: options.customDM ?? \"0\",\n rollMode: options.rollMode ?? \"publicroll\",\n // Creature-mode flags\n isCreature: options.isCreature ?? false,\n creatureSkills: options.creatureSkills ?? [],\n selectedSkillIndex: options.selectedSkillIndex ?? -1,\n showSkillSelector: options.showSkillSelector ?? false,\n skillName: options.skillName ?? \"\",\n skillLevel: options.skillLevel ?? 0,\n // Healing fields\n showHeal: options.showHeal ?? false,\n healType: options.healType ?? null\n });\n\n return await DialogV2.wait({\n window: { title: options.title ?? options.rollTypeName ?? game.i18n.localize(\"MGT2.RollPrompt.Roll\") },\n classes: [\"mgt2-roll-dialog\"],\n content: htmlContent,\n rejectClose: false,\n buttons: [\n {\n action: \"boon\",\n label: game.i18n.localize(\"MGT2.RollPrompt.Boon\"),\n callback: (event, button, dialog) => {\n const formData = new FormDataExtended(dialog.element.querySelector('form')).object;\n formData.diceModifier = \"dl\";\n return formData;\n }\n },\n {\n action: \"submit\",\n label: game.i18n.localize(\"MGT2.RollPrompt.Roll\"),\n icon: '',\n default: true,\n callback: (event, button, dialog) => {\n return new FormDataExtended(dialog.element.querySelector('form')).object;\n }\n },\n {\n action: \"bane\",\n label: game.i18n.localize(\"MGT2.RollPrompt.Bane\"),\n callback: (event, button, dialog) => {\n const formData = new FormDataExtended(dialog.element.querySelector('form')).object;\n formData.diceModifier = \"dh\";\n return formData;\n }\n }\n ]\n });\n }\n}\n","const { DialogV2 } = foundry.applications.api;\nconst { renderTemplate } = foundry.applications.handlebars;\nconst { FormDataExtended } = foundry.applications.ux;\n\nasync function _dialogWithForm(title, templatePath, templateData) {\n const htmlContent = await renderTemplate(templatePath, templateData);\n const theme = game.settings.get(\"mgt2\", \"theme\");\n return await DialogV2.wait({\n window: { title },\n content: htmlContent,\n rejectClose: false,\n buttons: [\n {\n action: \"submit\",\n label: game.i18n.localize(\"MGT2.Save\"),\n icon: '',\n default: true,\n callback: (event, button, dialog) => {\n return new FormDataExtended(dialog.element.querySelector('form')).object;\n }\n }\n ]\n });\n}\n\nexport class CharacterPrompts {\n\n static async openConfig(system) {\n return _dialogWithForm(\n \"Configuration\",\n \"systems/mgt2/templates/actors/actor-config-sheet.html\",\n { config: CONFIG.MGT2, system }\n );\n }\n\n static async openCharacteristic(name, show, showMax, showAll = false) {\n return _dialogWithForm(\n \"Configuration: \" + name,\n \"systems/mgt2/templates/actors/actor-config-characteristic-sheet.html\",\n { name, show, showMax, showAll }\n );\n }\n\n static async openTraitEdit(data) {\n const title = data.name ?? game.i18n.localize(\"MGT2.Actor.EditTrait\");\n return _dialogWithForm(\n title,\n \"systems/mgt2/templates/actors/trait-sheet.html\",\n { config: CONFIG.MGT2, data }\n );\n }\n\n static async openEditorFullView(title, html) {\n const htmlContent = await renderTemplate(\"systems/mgt2/templates/editor-fullview.html\", {\n config: CONFIG.MGT2,\n html\n });\n const theme = game.settings.get(\"mgt2\", \"theme\");\n await DialogV2.wait({\n window: { title },\n content: htmlContent,\n rejectClose: false,\n buttons: [\n {\n action: \"close\",\n label: game.i18n.localize(\"MGT2.Close\") || \"Fermer\",\n default: true,\n callback: () => null\n }\n ]\n });\n }\n\n static async openHealingDays() {\n return await DialogV2.wait({\n window: { \n title: game.i18n.localize(\"MGT2.Healing.Title\")\n },\n classes: [\"mgt2-roll-dialog\"],\n content: `\n \n `,\n rejectClose: false,\n buttons: [\n {\n action: \"submit\",\n label: game.i18n.localize(\"MGT2.Save\"),\n icon: '',\n default: true,\n callback: (event, button, dialog) => {\n return new FormDataExtended(dialog.element.querySelector('form')).object;\n }\n }\n ]\n });\n }\n}","import MGT2ActorSheet from \"./base-actor-sheet.mjs\";\nimport { MGT2 } from \"../../config.js\";\nimport { MGT2Helper } from \"../../helper.js\";\nimport { RollPromptHelper } from \"../../roll-prompt.js\";\nimport { CharacterPrompts } from \"../../actors/character-prompts.js\";\n\nexport default class TravellerCharacterSheet extends MGT2ActorSheet {\n\n /** @override */\n static DEFAULT_OPTIONS = {\n ...super.DEFAULT_OPTIONS,\n classes: [...super.DEFAULT_OPTIONS.classes, \"character\", \"nopad\"],\n window: {\n ...super.DEFAULT_OPTIONS.window,\n title: \"TYPES.Actor.character\",\n },\n actions: {\n ...super.DEFAULT_OPTIONS.actions,\n createItem: TravellerCharacterSheet.#onCreateItem,\n editItem: TravellerCharacterSheet.#onEditItem,\n deleteItem: TravellerCharacterSheet.#onDeleteItem,\n equipItem: TravellerCharacterSheet.#onEquipItem,\n itemStorageIn: TravellerCharacterSheet.#onItemStorageIn,\n itemStorageOut: TravellerCharacterSheet.#onItemStorageOut,\n softwareEject: TravellerCharacterSheet.#onSoftwareEject,\n createContainer: TravellerCharacterSheet.#onContainerCreate,\n editContainer: TravellerCharacterSheet.#onContainerEdit,\n deleteContainer: TravellerCharacterSheet.#onContainerDelete,\n roll: TravellerCharacterSheet.#onRoll,\n openConfig: TravellerCharacterSheet.#onOpenConfig,\n openCharacteristic: TravellerCharacterSheet.#onOpenCharacteristic,\n traitCreate: TravellerCharacterSheet.#onTraitCreate,\n traitEdit: TravellerCharacterSheet.#onTraitEdit,\n traitDelete: TravellerCharacterSheet.#onTraitDelete,\n openEditor: TravellerCharacterSheet.#onOpenEditor,\n heal: TravellerCharacterSheet.#onHeal,\n },\n }\n\n /** @override */\n static PARTS = {\n sheet: {\n template: \"systems/mgt2/templates/actors/actor-sheet.html\",\n },\n }\n\n /** @override */\n tabGroups = {\n sidebar: \"inventory\",\n characteristics: \"core\",\n inventory: \"onhand\",\n }\n\n /** @override */\n async _prepareContext() {\n const context = await super._prepareContext();\n const actor = this.document;\n const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? \"\", { async: true });\n\n context.enrichedBiography = await enrich(actor.system.biography);\n context.enrichedNotes = await enrich(actor.system.notes);\n context.enrichedFinanceNotes = await enrich(actor.system.finance?.notes);\n context.settings = {\n weightUnit: \"kg\",\n usePronouns: game.settings.get(\"mgt2\", \"usePronouns\"),\n useGender: game.settings.get(\"mgt2\", \"useGender\"),\n showLife: game.settings.get(\"mgt2\", \"showLife\"),\n };\n context.isGM = game.user.isGM;\n context.showTrash = false;\n context.initiative = actor.getInitiative();\n\n this._prepareCharacterItems(context);\n\n return context;\n }\n\n _prepareCharacterItems(context) {\n const actor = this.document;\n const settings = context.settings;\n const items = actor.items;\n\n const weapons = [], armors = [], augments = [], computers = [], softwares = [];\n const miscItems = [], equipments = [], containerItems = [], careers = [];\n const skills = [], psionics = [], diseases = [], wounds = [], contacts = [];\n const actorContainers = [];\n\n for (let i of items) {\n if (i.type === \"container\") {\n actorContainers.push(i);\n } else if (i.type === \"computer\") {\n computers.push(i);\n i._subItems = [];\n if (i.system.overload === true)\n i._overloadClass = \"computer-overload\";\n }\n }\n\n actorContainers.sort(MGT2Helper.compareByName);\n\n const containers = [{ name: \"(tous)\", _id: \"\" }].concat(actorContainers);\n const containerIndex = new Map();\n\n for (let c of actorContainers) {\n containerIndex.set(c._id, c);\n\n if (c.system.weight > 0) {\n const w = MGT2Helper.convertWeightForDisplay(c.system.weight) + \" \" + settings.weightUnit;\n c._display = c.name.length > 12 ? `${c.name.substring(0, 12)}... (${w})` : `${c.name} (${w})`;\n } else {\n c._display = c.name.length > 12 ? c.name.substring(0, 12) + \"...\" : c.name;\n }\n\n if (c.system.onHand === true)\n c._subItems = [];\n }\n\n const containerView = actor.system.containerView;\n let currentContainerView = containerView !== \"\" ? containerIndex.get(containerView) : null;\n\n context.containerView = currentContainerView || null;\n context.containerWeight = currentContainerView\n ? MGT2Helper.convertWeightForDisplay(currentContainerView.system.weight)\n : MGT2Helper.convertWeightForDisplay(0);\n context.containerShowAll = containerView === \"\";\n\n for (let i of items) {\n const item = i.system;\n\n if (item.hasOwnProperty(\"weight\") && item.weight > 0) {\n i._weight = isNaN(item.quantity)\n ? MGT2Helper.convertWeightForDisplay(item.weight) + \" \" + settings.weightUnit\n : MGT2Helper.convertWeightForDisplay(item.weight * item.quantity) + \" \" + settings.weightUnit;\n }\n\n if (item.hasOwnProperty(\"container\") && item.container.id !== \"\" && item.container.id !== undefined) {\n const container = containerIndex.get(item.container.id);\n if (container === undefined) {\n if (context.containerShowAll) {\n i._containerName = \"#deleted#\";\n containerItems.push(i);\n }\n continue;\n }\n\n if (container.system.locked && !game.user.isGM) continue;\n\n if (container.system.onHand === true)\n container._subItems.push(i);\n\n if (context.containerShowAll || actor.system.containerView === item.container.id) {\n i._containerName = container.name;\n containerItems.push(i);\n }\n continue;\n }\n\n if (item.hasOwnProperty(\"equipped\")) {\n i._canEquip = true;\n i.toggleClass = item.equipped ? \"active\" : \"\";\n } else {\n i._canEquip = false;\n i.toggleClass = \"\";\n }\n\n switch (i.type) {\n case \"equipment\":\n (i.system.subType === \"augment\" ? augments : equipments).push(i);\n break;\n\n case \"armor\":\n if (i.system.options?.length > 0)\n i._subInfo = i.system.options.map(x => x.name).join(\", \");\n armors.push(i);\n break;\n\n case \"computer\":\n if (i.system.options?.length > 0)\n i._subInfo = i.system.options.map(x => x.name).join(\", \");\n break;\n\n case \"item\":\n if (i.system.subType === \"software\") {\n if (i.system.software.computerId && i.system.software.computerId !== \"\") {\n const computer = computers.find(x => x._id === i.system.software.computerId);\n if (computer !== undefined) computer._subItems.push(i);\n else softwares.push(i);\n } else {\n i._display = i.system.software.bandwidth > 0\n ? `${i.name} (${i.system.software.bandwidth})`\n : i.name;\n softwares.push(i);\n }\n } else {\n miscItems.push(i);\n }\n break;\n\n case \"weapon\":\n i._range = i.system.range.isMelee\n ? game.i18n.localize(\"MGT2.Melee\")\n : MGT2Helper.getRangeDisplay(i.system.range);\n if (i.system.traits?.length > 0)\n i._subInfo = i.system.traits.map(x => x.name).join(\", \");\n weapons.push(i);\n break;\n\n case \"career\":\n careers.push(i);\n break;\n\n case \"contact\":\n contacts.push(i);\n break;\n\n case \"disease\":\n (i.system.subType === \"wound\" ? wounds : diseases).push(i);\n break;\n\n case \"talent\":\n if (i.system.subType === \"skill\") {\n skills.push(i);\n } else {\n if (MGT2Helper.hasValue(i.system.psionic, \"reach\"))\n i._reach = game.i18n.localize(`MGT2.PsionicReach.${i.system.psionic.reach}`);\n if (MGT2Helper.hasValue(i.system.roll, \"difficulty\"))\n i._difficulty = game.i18n.localize(`MGT2.Difficulty.${i.system.roll.difficulty}`);\n psionics.push(i);\n }\n break;\n\n case \"container\":\n if (i.system.onHand === true)\n miscItems.push(i);\n break;\n }\n }\n\n const byName = MGT2Helper.compareByName;\n const byEquipName = (a, b) => a.name.toLowerCase().localeCompare(b.name.toLowerCase());\n\n context.encumbranceNormal = MGT2Helper.convertWeightForDisplay(actor.system.inventory.encumbrance.normal);\n context.encumbranceHeavy = MGT2Helper.convertWeightForDisplay(actor.system.inventory.encumbrance.heavy);\n\n const totalWeight = actor.system.inventory.weight;\n if (totalWeight > actor.system.inventory.encumbrance.heavy) {\n context.encumbranceClasses = \"encumbrance-heavy\";\n context.encumbrance = 2;\n } else if (totalWeight > actor.system.inventory.encumbrance.normal) {\n context.encumbranceClasses = \"encumbrance-normal\";\n context.encumbrance = 1;\n } else {\n context.encumbrance = 0;\n }\n\n if (softwares.length > 0) { softwares.sort(byName); context.softwares = softwares; }\n augments.sort(byEquipName); context.augments = augments;\n armors.sort(byEquipName); context.armors = armors;\n computers.sort(byEquipName); context.computers = computers;\n context.careers = careers;\n contacts.sort(byName); context.contacts = contacts;\n containers.sort(byName); context.containers = containers;\n diseases.sort(byName); context.diseases = diseases;\n context.wounds = wounds;\n equipments.sort(byEquipName); context.equipments = equipments;\n miscItems.sort(byEquipName); context.items = miscItems;\n actorContainers.sort(byName); context.actorContainers = actorContainers;\n skills.sort(byName); context.skills = skills;\n psionics.sort(byName); context.psionics = psionics;\n weapons.sort(byEquipName); context.weapons = weapons;\n\n if (containerItems.length > 0) {\n containerItems.sort((a, b) => {\n const r = a._containerName.localeCompare(b._containerName);\n return r !== 0 ? r : a.name.toLowerCase().localeCompare(b.name.toLowerCase());\n });\n }\n context.containerItems = containerItems;\n }\n\n // =========================================================\n // Event Binding (AppV2 _onRender — replaces jQuery activateListeners)\n // Templates still use CSS class selectors, so we bind manually here.\n // =========================================================\n\n /** @override */\n _onRender(context, options) {\n super._onRender(context, options);\n const html = this.element;\n if (!this.isEditable) return;\n\n this._bindClassEvent(html, \"a[data-roll]\", \"click\", TravellerCharacterSheet.#onRoll);\n this._bindClassEvent(html, \".cfg-characteristic\", \"click\", TravellerCharacterSheet.#onOpenCharacteristic);\n this._bindClassEvent(html, \".item-create\", \"click\", TravellerCharacterSheet.#onCreateItem);\n this._bindClassEvent(html, \".item-edit\", \"click\", TravellerCharacterSheet.#onEditItem);\n this._bindClassEvent(html, \".item-delete\", \"click\", TravellerCharacterSheet.#onDeleteItem);\n this._bindClassEvent(html, \".item-storage-in\", \"click\", TravellerCharacterSheet.#onItemStorageIn);\n this._bindClassEvent(html, \".item-storage-out\", \"click\", TravellerCharacterSheet.#onItemStorageOut);\n this._bindClassEvent(html, \".software-eject\", \"click\", TravellerCharacterSheet.#onSoftwareEject);\n this._bindClassEvent(html, \".container-create\", \"click\", TravellerCharacterSheet.#onContainerCreate);\n this._bindClassEvent(html, \".container-edit\", \"click\", TravellerCharacterSheet.#onContainerEdit);\n this._bindClassEvent(html, \".container-delete\", \"click\", TravellerCharacterSheet.#onContainerDelete);\n this._bindClassEvent(html, \".traits-create\", \"click\", TravellerCharacterSheet.#onTraitCreate);\n this._bindClassEvent(html, \".traits-edit\", \"click\", TravellerCharacterSheet.#onTraitEdit);\n this._bindClassEvent(html, \".traits-delete\", \"click\", TravellerCharacterSheet.#onTraitDelete);\n this._bindClassEvent(html, \"[data-editor='open']\", \"click\", TravellerCharacterSheet.#onOpenEditor);\n html.querySelector(\"[name='config']\")?.addEventListener(\"click\", (ev) => TravellerCharacterSheet.#onOpenConfig.call(this, ev, ev.currentTarget));\n }\n\n /** Helper: bind a handler to all matching elements, with `this` set to the sheet instance */\n _bindClassEvent(html, selector, event, handler) {\n for (const el of html.querySelectorAll(selector)) {\n el.addEventListener(event, (ev) => handler.call(this, ev, ev.currentTarget));\n }\n }\n\n // =========================================================\n // Drag & Drop\n // =========================================================\n\n /** @override */\n async _onDrop(event) {\n event.preventDefault();\n event.stopImmediatePropagation();\n const dropData = MGT2Helper.getDataFromDropEvent(event);\n if (!dropData) return false;\n\n const sourceItemData = await MGT2Helper.getItemDataFromDropData(dropData);\n\n if (sourceItemData.type === \"species\") {\n const update = {\n system: {\n personal: {\n species: sourceItemData.name,\n speciesText: {\n description: sourceItemData.system.description,\n descriptionLong: sourceItemData.system.descriptionLong,\n },\n },\n },\n };\n update.system.personal.traits = this.actor.system.personal.traits.concat(sourceItemData.system.traits);\n\n if (sourceItemData.system.modifiers?.length > 0) {\n update.system.characteristics = {};\n for (let modifier of sourceItemData.system.modifiers) {\n if (MGT2Helper.hasValue(modifier, \"characteristic\") && MGT2Helper.hasValue(modifier, \"value\")) {\n const c = this.actor.system.characteristics[modifier.characteristic];\n const updateValue = { value: c.value + modifier.value };\n if (c.showMax) updateValue.max = c.max + modifier.value;\n update.system.characteristics[modifier.characteristic] = updateValue;\n }\n }\n }\n\n this.actor.update(update);\n return true;\n }\n\n if ([\"contact\", \"disease\", \"career\", \"talent\"].includes(sourceItemData.type)) {\n let transferData = {};\n try { transferData = sourceItemData.toJSON(); } catch (e) { transferData = sourceItemData; }\n delete transferData._id;\n delete transferData.id;\n await this.actor.createEmbeddedDocuments(\"Item\", [transferData]);\n return true;\n }\n\n if (![\"armor\", \"weapon\", \"computer\", \"container\", \"item\", \"equipment\"].includes(sourceItemData.type)) return false;\n\n const target = event.target.closest(\".table-row\");\n let targetId = null;\n let targetItem = null;\n if (target !== null) {\n targetId = target.dataset.itemId;\n targetItem = this.actor.getEmbeddedDocument(\"Item\", targetId);\n }\n\n let sourceItem = this.actor.getEmbeddedDocument(\"Item\", sourceItemData.id);\n if (sourceItem) {\n if (!targetItem) return false;\n if (sourceItem.id === targetId) return false;\n\n if (targetItem.type === \"item\" || targetItem.type === \"equipment\") {\n if (targetItem.system.subType === \"software\")\n await sourceItem.update({ \"system.software.computerId\": targetItem.system.software.computerId });\n else\n await sourceItem.update({ \"system.container.id\": targetItem.system.container.id });\n return true;\n } else if (targetItem.type === \"computer\") {\n await sourceItem.update({ \"system.software.computerId\": targetId });\n return true;\n } else if (targetItem.type === \"container\") {\n if (targetItem.system.locked && !game.user.isGM) {\n ui.notifications.error(\"Verrouillé\");\n } else {\n await sourceItem.update({ \"system.container.id\": targetId });\n return true;\n }\n }\n } else {\n let transferData = {};\n try { transferData = sourceItemData.toJSON(); } catch (e) { transferData = sourceItemData; }\n delete transferData._id;\n delete transferData.id;\n\n const recalcWeight = transferData.system.hasOwnProperty(\"weight\");\n\n if (transferData.system.hasOwnProperty(\"container\")) transferData.system.container.id = \"\";\n if (transferData.type === \"item\" && transferData.system.subType === \"software\") transferData.system.software.computerId = \"\";\n if (transferData.type === \"container\") transferData.system.onHand = true;\n if (transferData.system.hasOwnProperty(\"equipment\")) transferData.system.equipped = false;\n\n if (targetItem !== null) {\n if (transferData.type === \"item\" && transferData.system.subType === \"software\") {\n if (targetItem.type === \"item\" && targetItem.system.subType === \"software\")\n transferData.system.software.computerId = targetItem.system.software.computerId;\n else if (targetItem.type === \"computer\")\n transferData.system.software.computerId = targetItem._id;\n } else if ([\"armor\", \"computer\", \"equipment\", \"item\", \"weapon\"].includes(transferData.type)) {\n if (targetItem.type === \"container\") {\n if (!targetItem.system.locked || game.user.isGM)\n transferData.system.container.id = targetId;\n } else {\n transferData.system.container.id = targetItem.system.container.id;\n }\n }\n }\n\n await this.actor.createEmbeddedDocuments(\"Item\", [transferData]);\n if (recalcWeight) await this.actor.recalculateWeight();\n }\n return true;\n }\n\n // =========================================================\n // Actions (static private methods)\n // =========================================================\n\n static async #onCreateItem(event, target) {\n event.preventDefault();\n const data = {\n name: target.dataset.createName,\n type: target.dataset.typeItem,\n };\n if (target.dataset.subtype) {\n data.system = { subType: target.dataset.subtype };\n }\n const cls = getDocumentClass(\"Item\");\n return cls.create(data, { parent: this.actor });\n }\n\n static async #onEditItem(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n const item = this.actor.getEmbeddedDocument(\"Item\", li?.dataset.itemId);\n if (item) item.sheet.render(true);\n }\n\n static async #confirmDelete(name) {\n return foundry.applications.api.DialogV2.confirm({\n window: { title: game.i18n.localize(\"MGT2.Dialog.ConfirmDeleteTitle\") },\n content: `${game.i18n.format(\"MGT2.Dialog.ConfirmDeleteContent\", { name })}
`,\n yes: { label: game.i18n.localize(\"MGT2.Dialog.Yes\"), icon: \"fas fa-trash\" },\n no: { label: game.i18n.localize(\"MGT2.Dialog.No\"), icon: \"fas fa-times\" },\n rejectClose: false,\n modal: true\n });\n }\n\n static async #onDeleteItem(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n if (!li?.dataset.itemId) return;\n const item = this.actor.items.get(li.dataset.itemId);\n if (!item) return;\n const confirmed = await TravellerCharacterSheet.#confirmDelete(item.name);\n if (!confirmed) return;\n this.actor.deleteEmbeddedDocuments(\"Item\", [li.dataset.itemId]);\n }\n\n static async #onEquipItem(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n const itemId = li?.dataset.itemId;\n if (!itemId) return;\n const item = this.actor.items.get(itemId);\n if (!item) return;\n await item.update({ \"system.equipped\": !item.system.equipped });\n }\n\n static async #onItemStorageIn(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n const item = this.actor.getEmbeddedDocument(\"Item\", li?.dataset.itemId);\n if (!item) return;\n\n if (item.type === \"container\") {\n await item.update({ \"system.onHand\": false });\n } else {\n const containers = this.actor.getContainers();\n let container;\n const dropInId = this.actor.system.containerDropIn;\n\n if (!dropInId) {\n container = containers.length === 0\n ? await getDocumentClass(\"Item\").create({ name: \"New container\", type: \"container\" }, { parent: this.actor })\n : containers[0];\n } else {\n container = containers.find(x => x._id === dropInId);\n }\n\n if (container?.system.locked && !game.user.isGM) {\n ui.notifications.error(\"Objet verrouillé\");\n return;\n }\n await item.update({ \"system.container.id\": container._id });\n }\n }\n\n static async #onItemStorageOut(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n const item = this.actor.getEmbeddedDocument(\"Item\", li?.dataset.itemId);\n if (!item) return;\n await item.update({ \"system.container.id\": \"\" });\n }\n\n static async #onSoftwareEject(event, target) {\n event.preventDefault();\n const li = target.closest(\"[data-item-id]\");\n const item = this.actor.getEmbeddedDocument(\"Item\", li?.dataset.itemId);\n if (!item) return;\n await item.update({ \"system.software.computerId\": \"\" });\n }\n\n static async #onContainerCreate(event) {\n event.preventDefault();\n const cls = getDocumentClass(\"Item\");\n return cls.create({ name: \"New container\", type: \"container\" }, { parent: this.actor });\n }\n\n static async #onContainerEdit(event) {\n event.preventDefault();\n const container = this.actor.getEmbeddedDocument(\"Item\", this.actor.system.containerView);\n if (container) container.sheet.render(true);\n }\n\n static async #onContainerDelete(event) {\n event.preventDefault();\n const containers = this.actor.getContainers();\n const container = containers.find(x => x._id === this.actor.system.containerView);\n if (!container) return;\n\n const confirmed = await TravellerCharacterSheet.#confirmDelete(container.name);\n if (!confirmed) return;\n\n const containerItems = this.actor.items.filter(\n x => x.system.hasOwnProperty(\"container\") && x.system.container.id === container._id\n );\n\n if (containerItems.length > 0) {\n const updates = containerItems.map(item => ({ _id: item.id, \"system.container.id\": \"\" }));\n await this.actor.updateEmbeddedDocuments(\"Item\", updates);\n }\n\n const actorUpdate = { \"system.containerView\": \"\" };\n if (this.actor.system.containerDropIn === container._id) {\n actorUpdate[\"system.containerDropIn\"] = \"\";\n const remaining = containers.filter(x => x._id !== container._id);\n if (remaining.length > 0) actorUpdate[\"system.containerDropIn\"] = remaining[0]._id;\n }\n\n await this.actor.deleteEmbeddedDocuments(\"Item\", [container._id]);\n await this.actor.update(actorUpdate);\n }\n\n static async #onRoll(event, target) {\n event.preventDefault();\n\n const rollOptions = {\n rollTypeName: game.i18n.localize(\"MGT2.RollPrompt.Roll\"),\n rollObjectName: \"\",\n characteristics: [{ _id: \"\", name: \"\" }],\n characteristic: \"\",\n skills: [],\n skill: \"\",\n fatigue: this.actor.system.states.fatigue,\n encumbrance: this.actor.system.states.encumbrance,\n difficulty: null,\n damageFormula: null,\n isMelee: false,\n };\n\n const cardButtons = [];\n for (const [key, label] of Object.entries(MGT2.Characteristics)) {\n const c = this.actor.system.characteristics[key];\n if (c.show) {\n rollOptions.characteristics.push({\n _id: key,\n name: game.i18n.localize(label) + MGT2Helper.getDisplayDM(c.dm),\n });\n }\n }\n\n for (let item of this.actor.items) {\n if (item.type === \"talent\" && item.system.subType === \"skill\")\n rollOptions.skills.push({ _id: item._id, name: item.getRollDisplay() });\n }\n\n rollOptions.skills.sort(MGT2Helper.compareByName);\n rollOptions.skills = [{ _id: \"NP\", name: game.i18n.localize(\"MGT2.Items.NotProficient\") }].concat(rollOptions.skills);\n\n let itemObj = null;\n let isInitiative = false;\n const rollType = target.dataset.roll;\n\n if (rollType === \"initiative\") {\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.RollPrompt.InitiativeRoll\");\n rollOptions.characteristic = this.actor.system.config.initiative;\n isInitiative = true;\n } else if (rollType === \"characteristic\") {\n rollOptions.characteristic = target.dataset.rollCharacteristic;\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.RollPrompt.CharacteristicRoll\");\n rollOptions.rollObjectName = game.i18n.localize(`MGT2.Characteristics.${rollOptions.characteristic}.name`);\n } else {\n if (rollType === \"skill\") {\n rollOptions.skill = target.dataset.rollSkill;\n itemObj = this.actor.getEmbeddedDocument(\"Item\", rollOptions.skill);\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.RollPrompt.SkillRoll\");\n rollOptions.rollObjectName = itemObj.name;\n } else if (rollType === \"psionic\") {\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.RollPrompt.PsionicRoll\");\n }\n\n if (itemObj === null && target.dataset.itemId) {\n itemObj = this.actor.getEmbeddedDocument(\"Item\", target.dataset.itemId);\n rollOptions.rollObjectName = itemObj.name;\n if (itemObj.type === \"weapon\") rollOptions.rollTypeName = game.i18n.localize(\"TYPES.Item.weapon\");\n else if (itemObj.type === \"armor\") rollOptions.rollTypeName = game.i18n.localize(\"TYPES.Item.armor\");\n else if (itemObj.type === \"computer\") rollOptions.rollTypeName = game.i18n.localize(\"TYPES.Item.computer\");\n }\n\n if (rollType === \"psionic\" && itemObj) {\n rollOptions.rollObjectName = itemObj.name;\n if (MGT2Helper.hasValue(itemObj.system.psionic, \"duration\")) {\n cardButtons.push({\n label: game.i18n.localize(\"MGT2.Items.Duration\"),\n formula: itemObj.system.psionic.duration,\n message: {\n objectName: itemObj.name,\n flavor: \"{0} \".concat(game.i18n.localize(`MGT2.Durations.${itemObj.system.psionic.durationUnit}`)),\n },\n });\n }\n }\n\n if (itemObj?.system.hasOwnProperty(\"damage\")) {\n rollOptions.damageFormula = itemObj.system.damage;\n if (itemObj.type === \"weapon\") {\n rollOptions.isMelee = itemObj.system.range?.isMelee === true;\n }\n if (itemObj.type === \"disease\") {\n if (itemObj.system.subType === \"disease\")\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.DiseaseSubType.disease\");\n else if (itemObj.system.subType === \"poison\")\n rollOptions.rollTypeName = game.i18n.localize(\"MGT2.DiseaseSubType.poison\");\n }\n }\n\n if (itemObj?.system.hasOwnProperty(\"roll\")) {\n if (MGT2Helper.hasValue(itemObj.system.roll, \"characteristic\")) rollOptions.characteristic = itemObj.system.roll.characteristic;\n if (MGT2Helper.hasValue(itemObj.system.roll, \"skill\")) rollOptions.skill = itemObj.system.roll.skill;\n if (MGT2Helper.hasValue(itemObj.system.roll, \"difficulty\")) rollOptions.difficulty = itemObj.system.roll.difficulty;\n }\n }\n\n const userRollData = await RollPromptHelper.roll(rollOptions);\n\n const rollModifiers = [];\n const rollFormulaParts = [];\n\n if (userRollData.diceModifier) {\n rollFormulaParts.push(\"3d6\", userRollData.diceModifier);\n } else {\n rollFormulaParts.push(\"2d6\");\n }\n\n if (userRollData.characteristic) {\n const c = this.actor.system.characteristics[userRollData.characteristic];\n rollFormulaParts.push(MGT2Helper.getFormulaDM(c.dm));\n rollModifiers.push(game.i18n.localize(`MGT2.Characteristics.${userRollData.characteristic}.name`) + MGT2Helper.getDisplayDM(c.dm));\n }\n\n if (userRollData.skill) {\n if (userRollData.skill === \"NP\") {\n rollFormulaParts.push(\"-3\");\n rollModifiers.push(game.i18n.localize(\"MGT2.Items.NotProficient\"));\n } else {\n const skillObj = this.actor.getEmbeddedDocument(\"Item\", userRollData.skill);\n rollFormulaParts.push(MGT2Helper.getFormulaDM(skillObj.system.level));\n rollModifiers.push(skillObj.getRollDisplay());\n }\n }\n\n if (userRollData.psionic) {\n const psionicObj = this.actor.getEmbeddedDocument(\"Item\", userRollData.psionic);\n rollFormulaParts.push(MGT2Helper.getFormulaDM(psionicObj.system.level));\n rollModifiers.push(psionicObj.getRollDisplay());\n }\n\n if (userRollData.timeframes && userRollData.timeframes !== \"\" && userRollData.timeframes !== \"Normal\") {\n rollModifiers.push(game.i18n.localize(`MGT2.Timeframes.${userRollData.timeframes}`));\n rollFormulaParts.push(userRollData.timeframes === \"Slower\" ? \"+2\" : \"-2\");\n }\n\n if (userRollData.encumbrance === true) {\n rollFormulaParts.push(\"-2\");\n rollModifiers.push(game.i18n.localize(\"MGT2.Actor.Encumbrance\") + \" -2\");\n }\n\n if (userRollData.fatigue === true) {\n rollFormulaParts.push(\"-2\");\n rollModifiers.push(game.i18n.localize(\"MGT2.Actor.Fatigue\") + \" -2\");\n }\n\n const customDMVal = parseInt(userRollData.customDM ?? \"0\", 10);\n if (!isNaN(customDMVal) && customDMVal !== 0) {\n rollFormulaParts.push(customDMVal > 0 ? `+${customDMVal}` : `${customDMVal}`);\n rollModifiers.push(game.i18n.localize(\"MGT2.RollPrompt.CustomDM\") + \" \" + (customDMVal > 0 ? `+${customDMVal}` : `${customDMVal}`));\n }\n\n if (MGT2Helper.hasValue(userRollData, \"difficulty\") && userRollData.difficulty !== \"\") rollOptions.difficulty = userRollData.difficulty;\n\n const rollFormula = rollFormulaParts.join(\"\");\n if (!Roll.validate(rollFormula)) {\n ui.notifications.error(game.i18n.localize(\"MGT2.Errors.InvalidRollFormula\"));\n return;\n }\n\n let roll = await new Roll(rollFormula, this.actor.getRollData()).roll({ rollMode: userRollData.rollMode });\n\n if (isInitiative && this.token?.combatant) {\n await this.token.combatant.update({ initiative: roll.total });\n }\n\n // ── Compute effect and effective damage formula ──────────────────────\n let rollSuccess = false;\n let rollFailure = false;\n let rollEffect = undefined;\n let rollEffectStr = undefined;\n let difficultyValue = null;\n\n if (MGT2Helper.hasValue(rollOptions, \"difficulty\")) {\n difficultyValue = MGT2Helper.getDifficultyValue(rollOptions.difficulty);\n rollEffect = roll.total - difficultyValue;\n rollEffectStr = (rollEffect >= 0 ? \"+\" : \"\") + rollEffect;\n rollSuccess = rollEffect >= 0;\n rollFailure = !rollSuccess;\n }\n\n // Build effective damage formula: base + effect + STR DM (melee)\n let effectiveDamageFormula = rollOptions.damageFormula || null;\n if (effectiveDamageFormula) {\n if (rollEffect !== undefined && rollEffect !== 0) {\n effectiveDamageFormula += (rollEffect >= 0 ? \"+\" : \"\") + rollEffect;\n }\n if (rollOptions.isMelee) {\n const strDm = this.actor.system.characteristics.strength?.dm ?? 0;\n if (strDm !== 0) effectiveDamageFormula += (strDm >= 0 ? \"+\" : \"\") + strDm;\n }\n }\n\n // ── Build roll breakdown tooltip ─────────────────────────────────────\n const diceRawTotal = roll.dice.reduce((s, d) => s + d.total, 0);\n const breakdownParts = [game.i18n.localize(\"MGT2.Chat.Roll.Dice\") + \" \" + diceRawTotal];\n for (const mod of rollModifiers) breakdownParts.push(mod);\n if (rollEffectStr !== undefined)\n breakdownParts.push(game.i18n.localize(\"MGT2.Chat.Roll.Effect\") + \" \" + rollEffectStr);\n const rollBreakdown = breakdownParts.join(\" | \");\n\n const chatData = {\n user: game.user.id,\n speaker: this.actor ? ChatMessage.getSpeaker({ actor: this.actor }) : null,\n formula: roll._formula,\n tooltip: await roll.getTooltip(),\n total: Math.round(roll.total * 100) / 100,\n rollBreakdown,\n showButtons: true,\n showLifeButtons: false,\n showRollRequest: false,\n rollTypeName: rollOptions.rollTypeName,\n rollObjectName: rollOptions.rollObjectName,\n rollModifiers: rollModifiers,\n // Show damage button only if there's a formula AND (no difficulty check OR roll succeeded)\n showRollDamage: !!effectiveDamageFormula && (!difficultyValue || rollSuccess),\n cardButtons: cardButtons,\n };\n\n if (MGT2Helper.hasValue(rollOptions, \"difficulty\")) {\n chatData.rollDifficulty = rollOptions.difficulty;\n chatData.rollDifficultyLabel = MGT2Helper.getDifficultyDisplay(rollOptions.difficulty);\n chatData.rollEffect = rollEffect;\n chatData.rollEffectStr = rollEffectStr;\n chatData.rollSuccess = rollSuccess || undefined;\n chatData.rollFailure = rollFailure || undefined;\n }\n\n const html = await foundry.applications.handlebars.renderTemplate(\"systems/mgt2/templates/chat/roll.html\", chatData);\n chatData.content = html;\n\n let flags = null;\n if (effectiveDamageFormula) {\n flags = { mgt2: { damage: { formula: effectiveDamageFormula, rollObjectName: rollOptions.rollObjectName, rollTypeName: rollOptions.rollTypeName } } };\n }\n if (cardButtons.length > 0) {\n if (!flags) flags = { mgt2: {} };\n flags.mgt2.buttons = cardButtons;\n }\n if (flags) chatData.flags = flags;\n\n return roll.toMessage(chatData);\n }\n\n static async #onOpenConfig(event) {\n event.preventDefault();\n const userConfig = await CharacterPrompts.openConfig(this.actor.system);\n if (userConfig) this.actor.update({ \"system.config\": userConfig });\n }\n\n static async #onOpenCharacteristic(event, target) {\n event.preventDefault();\n const name = target.dataset.cfgCharacteristic;\n const c = this.actor.system.characteristics[name];\n\n let showAll = false;\n for (const value of Object.values(this.actor.system.characteristics)) {\n if (!value.show) { showAll = true; break; }\n }\n\n const userConfig = await CharacterPrompts.openCharacteristic(\n game.i18n.localize(`MGT2.Characteristics.${name}.name`),\n c.show, c.showMax, showAll\n );\n\n if (userConfig) {\n const data = { system: { characteristics: {} } };\n data.system.characteristics[name] = { show: userConfig.show, showMax: userConfig.showMax };\n\n if (userConfig.showAll === true) {\n for (const [key, value] of Object.entries(this.actor.system.characteristics)) {\n if (key !== name && !value.show)\n data.system.characteristics[key] = { show: true };\n }\n }\n this.actor.update(data);\n }\n }\n\n static async #onTraitCreate(event) {\n event.preventDefault();\n let traits = this.actor.system.personal.traits;\n let newTraits;\n if (traits.length === 0) {\n newTraits = [{ name: \"\", description: \"\" }];\n } else {\n newTraits = [...traits, { name: \"\", description: \"\" }];\n }\n return this.actor.update({ system: { personal: { traits: newTraits } } });\n }\n\n static async #onTraitEdit(event, target) {\n event.preventDefault();\n const element = target.closest(\"[data-traits-part]\");\n const index = Number(element.dataset.traitsPart);\n const trait = this.actor.system.personal.traits[index];\n const result = await CharacterPrompts.openTraitEdit(trait);\n const traits = [...this.actor.system.personal.traits];\n traits[index] = { ...traits[index], name: result.name, description: result.description };\n return this.actor.update({ system: { personal: { traits: traits } } });\n }\n\n static async #onTraitDelete(event, target) {\n event.preventDefault();\n const confirmed = await TravellerCharacterSheet.#confirmDelete(game.i18n.localize(\"MGT2.Actor.ThisTrait\"));\n if (!confirmed) return;\n const element = target.closest(\"[data-traits-part]\");\n const index = Number(element.dataset.traitsPart);\n const traits = foundry.utils.deepClone(this.actor.system.personal.traits);\n const newTraits = Object.entries(traits)\n .filter(([key]) => Number(key) !== index)\n .map(([, value]) => value);\n return this.actor.update({ system: { personal: { traits: newTraits } } });\n }\n\n static async #onOpenEditor(event) {\n event.preventDefault();\n await CharacterPrompts.openEditorFullView(\n this.actor.system.personal.species,\n this.actor.system.personal.speciesText.descriptionLong\n );\n }\n\n static async #onHeal(event, target) {\n event.preventDefault();\n const healType = target.dataset.healType;\n\n if (canvas.tokens.controlled.length === 0) {\n ui.notifications.warn(game.i18n.localize(\"MGT2.Errors.NoTokenSelected\"));\n return;\n }\n\n if (healType === \"firstaid\") {\n // Find Medicine skill to pre-select\n // Use normalized string matching to handle accents\n const medSkill = this.actor.items.find(i => {\n if (i.type !== \"talent\" || i.system.subType !== \"skill\") return false;\n const normalized = i.name.toLowerCase().normalize(\"NFD\").replace(/[\\u0300-\\u036f]/g, \"\");\n return normalized.includes(\"medecin\") || normalized.includes(\"medicine\");\n });\n \n // Only EDU characteristic available for First Aid\n const characteristics = [\n { _id: \"education\", name: game.i18n.localize(\"MGT2.Characteristics.education.name\") }\n ];\n \n const rollOptions = {\n rollTypeName: game.i18n.localize(\"MGT2.Healing.FirstAid\"),\n rollObjectName: this.actor.name,\n characteristics: characteristics, // Only EDU\n characteristic: \"education\", // Pre-selected\n skill: medSkill?.id ?? \"\", // Medicine skill ID for pre-selection (must match _id in array)\n skillName: medSkill?.name ?? game.i18n.localize(\"MGT2.Healing.NoMedicineSkill\"), // Display name\n skillLevel: medSkill?.system.level ?? -3, // -3 if not found\n skills: medSkill ? [{ _id: medSkill.id, name: medSkill.name, level: medSkill.system.level }] : [],\n difficulty: \"Average\", // First Aid difficulty is 8 (Average)\n showHeal: true,\n healType: MGT2.HealingType.FIRST_AID,\n };\n const userRollData = await RollPromptHelper.roll(rollOptions);\n if (userRollData) {\n // Build formula with all DMs — same pattern as standard skill roll\n const rollFormulaParts = [];\n const rollModifiers = [];\n\n if (userRollData.diceModifier) {\n rollFormulaParts.push(\"3d6\");\n rollFormulaParts.push(userRollData.diceModifier);\n } else {\n rollFormulaParts.push(\"2d6\");\n }\n\n if (userRollData.characteristic) {\n const c = this.actor.system.characteristics[userRollData.characteristic];\n rollFormulaParts.push(MGT2Helper.getFormulaDM(c.dm));\n rollModifiers.push(game.i18n.localize(`MGT2.Characteristics.${userRollData.characteristic}.name`) + MGT2Helper.getDisplayDM(c.dm));\n }\n\n if (userRollData.skill && userRollData.skill !== \"\") {\n if (userRollData.skill === \"NP\") {\n rollFormulaParts.push(\"-3\");\n rollModifiers.push(game.i18n.localize(\"MGT2.Items.NotProficient\"));\n } else {\n const skillObj = this.actor.getEmbeddedDocument(\"Item\", userRollData.skill);\n rollFormulaParts.push(MGT2Helper.getFormulaDM(skillObj.system.level));\n rollModifiers.push(skillObj.getRollDisplay());\n }\n }\n\n if (userRollData.customDM && userRollData.customDM !== \"\") {\n let s = userRollData.customDM.trim();\n if (/^[0-9]/.test(s)) rollFormulaParts.push(\"+\");\n rollFormulaParts.push(s);\n rollModifiers.push(\"DM \" + s);\n }\n\n const rollFormula = rollFormulaParts.join(\"\");\n const roll = await new Roll(rollFormula, this.actor.getRollData()).roll();\n\n // Difficulty for First Aid is Average (8)\n const difficulty = 8;\n const effect = roll.total - difficulty;\n const isSuccess = effect >= 0;\n const healing = isSuccess ? Math.max(1, effect) : 0;\n\n const cardButtons = isSuccess\n ? [{ label: game.i18n.localize(\"MGT2.Healing.ApplyHealing\"), action: \"healing\" }]\n : [];\n\n const chatData = {\n user: game.user.id,\n speaker: ChatMessage.getSpeaker({ actor: this.actor }),\n formula: roll._formula,\n tooltip: await roll.getTooltip(),\n total: Math.round(roll.total * 100) / 100,\n rollTypeName: game.i18n.localize(\"MGT2.Healing.FirstAid\"),\n rollObjectName: this.actor.name,\n rollModifiers: rollModifiers,\n rollDifficulty: difficulty,\n rollDifficultyLabel: MGT2Helper.getDifficultyDisplay(\"Average\"),\n rollEffectStr: isSuccess ? effect.toString() : undefined,\n healingAmount: isSuccess ? healing : undefined,\n rollSuccess: isSuccess || undefined,\n rollFailure: !isSuccess || undefined,\n showButtons: isSuccess,\n hasDamage: false,\n showRollDamage: false,\n cardButtons: cardButtons,\n };\n\n const html = await foundry.applications.handlebars.renderTemplate(\"systems/mgt2/templates/chat/roll.html\", chatData);\n chatData.content = html;\n chatData.flags = { mgt2: { healing: { amount: healing } } };\n\n return roll.toMessage(chatData);\n }\n } else if (healType === \"surgery\") {\n // Find Medicine skill to pre-select (same as first aid)\n const medSkill = this.actor.items.find(i => {\n if (i.type !== \"talent\" || i.system.subType !== \"skill\") return false;\n const normalized = i.name.toLowerCase().normalize(\"NFD\").replace(/[\\u0300-\\u036f]/g, \"\");\n return normalized.includes(\"medecin\") || normalized.includes(\"medicine\");\n });\n\n const characteristics = [\n { _id: \"education\", name: game.i18n.localize(\"MGT2.Characteristics.education.name\") }\n ];\n\n const rollOptions = {\n rollTypeName: game.i18n.localize(\"MGT2.Healing.Surgery\"),\n rollObjectName: this.actor.name,\n characteristics: characteristics,\n characteristic: \"education\",\n skill: medSkill?.id ?? \"\",\n skillName: medSkill?.name ?? game.i18n.localize(\"MGT2.Healing.NoMedicineSkill\"),\n skillLevel: medSkill?.system.level ?? -3,\n skills: medSkill ? [{ _id: medSkill.id, name: medSkill.name, level: medSkill.system.level }] : [],\n difficulty: \"Average\",\n showHeal: true,\n healType: MGT2.HealingType.SURGERY,\n };\n const userRollData = await RollPromptHelper.roll(rollOptions);\n if (userRollData) {\n // Build formula with all DMs — same pattern as standard skill roll\n const rollFormulaParts = [];\n const rollModifiers = [];\n\n if (userRollData.diceModifier) {\n rollFormulaParts.push(\"3d6\");\n rollFormulaParts.push(userRollData.diceModifier);\n } else {\n rollFormulaParts.push(\"2d6\");\n }\n\n if (userRollData.characteristic) {\n const c = this.actor.system.characteristics[userRollData.characteristic];\n rollFormulaParts.push(MGT2Helper.getFormulaDM(c.dm));\n rollModifiers.push(game.i18n.localize(`MGT2.Characteristics.${userRollData.characteristic}.name`) + MGT2Helper.getDisplayDM(c.dm));\n }\n\n if (userRollData.skill && userRollData.skill !== \"\") {\n if (userRollData.skill === \"NP\") {\n rollFormulaParts.push(\"-3\");\n rollModifiers.push(game.i18n.localize(\"MGT2.Items.NotProficient\"));\n } else {\n const skillObj = this.actor.getEmbeddedDocument(\"Item\", userRollData.skill);\n rollFormulaParts.push(MGT2Helper.getFormulaDM(skillObj.system.level));\n rollModifiers.push(skillObj.getRollDisplay());\n }\n }\n\n if (userRollData.customDM && userRollData.customDM !== \"\") {\n let s = userRollData.customDM.trim();\n if (/^[0-9]/.test(s)) rollFormulaParts.push(\"+\");\n rollFormulaParts.push(s);\n rollModifiers.push(\"DM \" + s);\n }\n\n const rollFormula = rollFormulaParts.join(\"\");\n const roll = await new Roll(rollFormula, this.actor.getRollData()).roll();\n\n // Difficulty for Surgery is Average (8)\n const difficulty = 8;\n const effect = roll.total - difficulty;\n const isSuccess = effect >= 0;\n\n // Success: heal Math.max(1, effect); Failure: patient takes 3 + |effect| damage\n const healing = isSuccess ? Math.max(1, effect) : 0;\n const surgeryDamage = isSuccess ? 0 : 3 + Math.abs(effect);\n\n const cardButtons = [];\n if (isSuccess) {\n cardButtons.push({ label: game.i18n.localize(\"MGT2.Healing.ApplyHealing\"), action: \"healing\" });\n } else {\n cardButtons.push({ label: game.i18n.localize(\"MGT2.Healing.ApplySurgeryDamage\"), action: \"surgeryDamage\" });\n }\n\n const chatData = {\n user: game.user.id,\n speaker: ChatMessage.getSpeaker({ actor: this.actor }),\n formula: roll._formula,\n tooltip: await roll.getTooltip(),\n total: Math.round(roll.total * 100) / 100,\n rollTypeName: game.i18n.localize(\"MGT2.Healing.Surgery\"),\n rollObjectName: this.actor.name,\n rollModifiers: rollModifiers,\n rollDifficulty: difficulty,\n rollDifficultyLabel: MGT2Helper.getDifficultyDisplay(\"Average\"),\n rollEffectStr: effect.toString(),\n healingAmount: isSuccess ? healing : undefined,\n surgeryDamageAmount: isSuccess ? undefined : surgeryDamage,\n rollSuccess: isSuccess || undefined,\n rollFailure: !isSuccess || undefined,\n showButtons: true,\n hasDamage: false,\n showRollDamage: false,\n cardButtons: cardButtons,\n };\n\n const html = await foundry.applications.handlebars.renderTemplate(\"systems/mgt2/templates/chat/roll.html\", chatData);\n chatData.content = html;\n chatData.flags = { mgt2: { surgery: { healing, surgeryDamage } } };\n\n return roll.toMessage(chatData);\n }\n } else if (healType === \"medical\") {\n const result = await CharacterPrompts.openHealingDays();\n if (result) {\n const endMD = this.actor.system.characteristics.endurance.dm;\n const medSkill = this.actor.items.find(i =>\n i.type === \"talent\" &&\n i.system.subType === \"skill\" &&\n (i.name.toLowerCase().includes(\"medecin\") || i.name.toLowerCase().includes(\"medicine\"))\n );\n const skillValue = medSkill ? medSkill.system.level : 0;\n const days = result.days;\n const healingPerDay = Math.max(1, 3 + endMD + skillValue);\n const totalHealing = healingPerDay * days;\n\n const rollModifiers = [\n `3 (base)`,\n `${endMD >= 0 ? \"+\" : \"\"}${endMD} END`,\n `+${skillValue} ${medSkill?.name ?? \"Médecine\"}`,\n `× ${days} ${game.i18n.localize(\"MGT2.RollPrompt.Days\").toLowerCase()}`\n ];\n\n const templateData = {\n rollObjectName: this.actor.name,\n rollTypeName: game.i18n.localize(\"MGT2.Healing.MedicalCare\"),\n rollModifiers,\n formula: `${healingPerDay} ${game.i18n.localize(\"MGT2.Items.PerDay\")}`,\n tooltip: \"\",\n total: totalHealing,\n rollSuccess: true,\n showButtons: true,\n cardButtons: [\n { action: \"healing\", label: game.i18n.localize(\"MGT2.Healing.ApplyHealing\") }\n ]\n };\n\n const content = await renderTemplate(\n \"systems/mgt2/templates/chat/roll.html\",\n templateData\n );\n await ChatMessage.create({\n user: game.user.id,\n speaker: ChatMessage.getSpeaker({ actor: this.actor }),\n content,\n flags: { mgt2: { healing: { amount: totalHealing } } }\n });\n }\n } else if (healType === \"natural\") {\n const result = await CharacterPrompts.openHealingDays();\n if (result) {\n const endMD = this.actor.system.characteristics.endurance.dm;\n let totalAmount = 0;\n const rolls = [];\n \n for (let i = 0; i < result.days; i++) {\n const roll = await new Roll(\"1d6\").evaluate();\n const dayHealing = Math.max(1, roll.total + endMD);\n rolls.push({ roll, dayHealing });\n totalAmount += dayHealing;\n }\n \n // Build roll details\n const rollDisplay = rolls.map((r, idx) => \n `${game.i18n.localize(\"MGT2.RollPrompt.Days\")} ${idx + 1}: 1d6 = ${r.roll.total} + ${endMD > 0 ? \"+\" : \"\"}${endMD} = ${r.dayHealing}
`\n ).join(\"\");\n \n const chatData = {\n user: game.user.id,\n speaker: ChatMessage.getSpeaker({ actor: this.actor }),\n content: `\n \n
${result.days} ${game.i18n.localize(\"MGT2.RollPrompt.Days\")}
\n
\n ${rollDisplay}\n
\n
\n ${game.i18n.localize(\"MGT2.Chat.Roll.Effect\")} ${totalAmount}\n
\n
`,\n flags: { mgt2: { healing: { amount: totalAmount } } }\n };\n await ChatMessage.create(chatData);\n \n // Apply healing immediately\n await this.actor.applyHealing(totalAmount);\n ui.notifications.info(\n game.i18n.format(\"MGT2.Notifications.HealingApplied\",\n { name: this.actor.name, amount: totalAmount })\n );\n }\n }\n }\n}\n","import MGT2ActorSheet from \"./base-actor-sheet.mjs\";\n\nexport default class TravellerVehiculeSheet extends MGT2ActorSheet {\n\n /** @override */\n static DEFAULT_OPTIONS = {\n ...super.DEFAULT_OPTIONS,\n classes: [...super.DEFAULT_OPTIONS.classes, \"vehicule\", \"nopad\"],\n window: {\n ...super.DEFAULT_OPTIONS.window,\n title: \"TYPES.Actor.vehicule\",\n },\n }\n\n /** @override */\n static PARTS = {\n sheet: {\n template: \"systems/mgt2/templates/actors/vehicule-sheet.html\",\n },\n }\n\n /** @override */\n tabGroups = { primary: \"stats\" }\n\n /** @override */\n async _prepareContext() {\n const context = await super._prepareContext();\n const actor = this.document;\n const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? \"\", { async: true });\n\n context.enrichedDescription = await enrich(actor.system.description);\n context.enrichedNotes = await enrich(actor.system.notes);\n return context;\n }\n}\n","import MGT2ActorSheet from \"./base-actor-sheet.mjs\";\nimport { RollPromptHelper } from \"../../roll-prompt.js\";\nimport { MGT2Helper } from \"../../helper.js\";\n\nconst { renderTemplate } = foundry.applications.handlebars;\n\n/** Convert Traveller dice notation (e.g. \"2D\", \"4D+2\", \"3D6\") to FoundryVTT formula */\nfunction normalizeDice(formula) {\n if (!formula) return \"1d6\";\n return formula\n .replace(/(\\d*)D(\\d*)([+-]\\d+)?/gi, (_, count, sides, mod) => {\n const n = count || \"1\";\n const d = sides || \"6\";\n return mod ? `${n}d${d}${mod}` : `${n}d${d}`;\n });\n}\n\nexport default class TravellerCreatureSheet extends MGT2ActorSheet {\n\n /** @override */\n static DEFAULT_OPTIONS = {\n ...super.DEFAULT_OPTIONS,\n classes: [...super.DEFAULT_OPTIONS.classes, \"creature\", \"nopad\"],\n position: {\n width: 720,\n height: 600,\n },\n window: {\n ...super.DEFAULT_OPTIONS.window,\n title: \"TYPES.Actor.creature\",\n },\n actions: {\n ...super.DEFAULT_OPTIONS.actions,\n rollAttack: TravellerCreatureSheet.#onRollAttack,\n rollSkill: TravellerCreatureSheet.#onRollSkill,\n addSkill: TravellerCreatureSheet.#onAddRow,\n deleteSkill: TravellerCreatureSheet.#onDeleteRow,\n addAttack: TravellerCreatureSheet.#onAddRow,\n deleteAttack: TravellerCreatureSheet.#onDeleteRow,\n addTrait: TravellerCreatureSheet.#onAddRow,\n deleteTrait: TravellerCreatureSheet.#onDeleteRow,\n },\n }\n\n /** @override */\n static PARTS = {\n sheet: {\n template: \"systems/mgt2/templates/actors/creature-sheet.html\",\n },\n }\n\n /** @override */\n tabGroups = { primary: \"combat\" }\n\n /** @override */\n async _prepareContext() {\n const context = await super._prepareContext();\n const actor = this.document;\n const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? \"\", { async: true });\n\n context.enrichedBiography = await enrich(actor.system.biography);\n context.enrichedNotes = await enrich(actor.system.notes);\n context.sizeLabel = this._getSizeLabel(actor.system.life.max);\n context.sizeTraitLabel = this._getSizeTrait(actor.system.life.max);\n context.config = CONFIG.MGT2;\n\n return context;\n }\n\n _getSizeLabel(pdv) {\n if (pdv <= 2) return \"Souris / Rat\";\n if (pdv <= 5) return \"Chat\";\n if (pdv <= 7) return \"Blaireau / Chien\";\n if (pdv <= 13) return \"Chimpanzé / Chèvre\";\n if (pdv <= 28) return \"Humain\";\n if (pdv <= 35) return \"Vache / Cheval\";\n if (pdv <= 49) return \"Requin\";\n if (pdv <= 70) return \"Rhinocéros\";\n if (pdv <= 90) return \"Éléphant\";\n if (pdv <= 125) return \"Carnosaure\";\n return \"Sauropode / Baleine\";\n }\n\n _getSizeTrait(pdv) {\n if (pdv <= 2) return \"Petit (−4)\";\n if (pdv <= 5) return \"Petit (−3)\";\n if (pdv <= 7) return \"Petit (−2)\";\n if (pdv <= 13) return \"Petit (−1)\";\n if (pdv <= 28) return \"—\";\n if (pdv <= 35) return \"Grand (+1)\";\n if (pdv <= 49) return \"Grand (+2)\";\n if (pdv <= 70) return \"Grand (+3)\";\n if (pdv <= 90) return \"Grand (+4)\";\n if (pdv <= 125) return \"Grand (+5)\";\n return \"Grand (+6)\";\n }\n\n // ───────────────────────────────────────────────────────── Roll Helpers\n\n static async #postCreatureRoll({ actor, roll, rollLabel, dm, difficulty, difficultyLabel, rollMode, extraTooltip }) {\n const diffTarget = MGT2Helper.getDifficultyValue(difficulty ?? \"Average\");\n const hasDifficulty = !!difficulty;\n const success = hasDifficulty ? roll.total >= diffTarget : true;\n const effect = roll.total - diffTarget;\n const effectStr = (effect >= 0 ? \"+\" : \"\") + effect;\n\n const diceRawTotal = roll.dice.reduce((s, d) => s + d.total, 0);\n const breakdownParts = [game.i18n.localize(\"MGT2.Chat.Roll.Dice\") + \" \" + diceRawTotal];\n if (dm !== 0) breakdownParts.push(`DM ${dm >= 0 ? \"+\" : \"\"}${dm}`);\n if (hasDifficulty) breakdownParts.push(game.i18n.localize(\"MGT2.Chat.Roll.Effect\") + \" \" + effectStr);\n if (extraTooltip) breakdownParts.push(extraTooltip);\n const rollBreakdown = breakdownParts.join(\" | \");\n\n const chatData = {\n creatureName: actor.name,\n creatureImg: actor.img,\n rollLabel,\n formula: roll.formula,\n total: roll.total,\n tooltip: await roll.getTooltip(),\n rollBreakdown,\n difficulty: hasDifficulty ? diffTarget : null,\n difficultyLabel: difficultyLabel ?? MGT2Helper.getDifficultyDisplay(difficulty),\n success: hasDifficulty ? success : null,\n failure: hasDifficulty ? !success : null,\n effect: hasDifficulty ? effect : null,\n effectStr: hasDifficulty ? effectStr : null,\n modifiers: dm !== 0 ? [`DM ${dm >= 0 ? \"+\" : \"\"}${dm}`] : [],\n };\n\n const chatContent = await renderTemplate(\n \"systems/mgt2/templates/chat/creature-roll.html\",\n chatData\n );\n\n await ChatMessage.create({\n content: chatContent,\n speaker: ChatMessage.getSpeaker({ actor }),\n rolls: [roll],\n rollMode: rollMode ?? game.settings.get(\"core\", \"rollMode\"),\n });\n\n return { success, effect, total: roll.total };\n }\n\n // ───────────────────────────────────────────────────────── Roll Handlers\n\n /** Roll a skill check (2d6 + level vs difficulty) — uses unified dialog */\n static async #onRollSkill(event, target) {\n const index = parseInt(target.dataset.index ?? 0);\n const actor = this.document;\n const skill = actor.system.skills[index];\n if (!skill) return;\n\n const result = await RollPromptHelper.roll({\n isCreature: true,\n showSkillSelector: false,\n skillName: skill.name,\n skillLevel: skill.level,\n difficulty: \"Average\",\n title: game.i18n.localize(\"MGT2.Creature.RollSkill\") + \" — \" + skill.name,\n });\n if (!result) return;\n\n const customDM = parseInt(result.customDM ?? \"0\", 10) || 0;\n const skillLevel = parseInt(skill.level ?? 0, 10) || 0;\n const dm = skillLevel + customDM;\n const diceModifier = result.diceModifier ?? \"\";\n\n // Build formula exactly like character-sheet: parts joined without spaces\n const parts = [];\n if (diceModifier) {\n parts.push(\"3d6\", diceModifier);\n } else {\n parts.push(\"2d6\");\n }\n if (dm !== 0) parts.push(MGT2Helper.getFormulaDM(dm));\n const fullFormula = parts.join(\"\");\n\n const roll = await new Roll(fullFormula).evaluate();\n const rollLabel = `${skill.name.toUpperCase()} (${skillLevel >= 0 ? \"+\" : \"\"}${skillLevel})`;\n\n const tooltipParts = [`Dés: ${roll.dice.reduce((s, d) => s + d.total, 0)}`];\n if (skillLevel !== 0) tooltipParts.push(`${skill.name} ${skillLevel >= 0 ? \"+\" : \"\"}${skillLevel}`);\n if (customDM !== 0) tooltipParts.push(`MD perso ${customDM >= 0 ? \"+\" : \"\"}${customDM}`);\n\n await TravellerCreatureSheet.#postCreatureRoll({\n actor, roll, rollLabel,\n dm,\n difficulty: result.difficulty,\n rollMode: result.rollMode,\n extraTooltip: tooltipParts.join(\" | \"),\n });\n }\n\n /** Roll an attack: dialog with skill selector, then roll 2d6+skill+DM vs difficulty; on success roll damage */\n static async #onRollAttack(event, target) {\n const index = parseInt(target.dataset.index ?? 0);\n const actor = this.document;\n const attack = actor.system.attacks[index];\n if (!attack) return;\n\n const skills = actor.system.skills ?? [];\n\n const result = await RollPromptHelper.roll({\n isCreature: true,\n showSkillSelector: true,\n creatureSkills: skills,\n selectedSkillIndex: attack.skill ?? -1,\n difficulty: \"Average\",\n title: game.i18n.localize(\"MGT2.Creature.RollAttack\") + \" — \" + attack.name,\n });\n if (!result) return;\n\n const skillIndex = parseInt(result.creatureSkillIndex ?? \"-1\", 10);\n const chosenSkill = (skillIndex >= 0 && skillIndex < skills.length) ? skills[skillIndex] : null;\n const skillLevel = parseInt(chosenSkill?.level ?? 0, 10) || 0;\n const customDM = parseInt(result.customDM ?? \"0\", 10) || 0;\n const dm = skillLevel + customDM;\n const diceModifier = result.diceModifier ?? \"\";\n\n // Build formula exactly like character-sheet: parts joined without spaces\n const parts = [];\n if (diceModifier) {\n parts.push(\"3d6\", diceModifier);\n } else {\n parts.push(\"2d6\");\n }\n if (dm !== 0) parts.push(MGT2Helper.getFormulaDM(dm));\n const fullFormula = parts.join(\"\");\n\n const roll = await new Roll(fullFormula).evaluate();\n const rollLabel = chosenSkill\n ? `${attack.name} — ${chosenSkill.name} (${skillLevel >= 0 ? \"+\" : \"\"}${skillLevel})`\n : attack.name;\n\n const tooltipParts = [`Dés: ${roll.dice.reduce((s, d) => s + d.total, 0)}`];\n if (chosenSkill) tooltipParts.push(`${chosenSkill.name} ${skillLevel >= 0 ? \"+\" : \"\"}${skillLevel}`);\n if (customDM !== 0) tooltipParts.push(`MD perso ${customDM >= 0 ? \"+\" : \"\"}${customDM}`);\n\n const { success } = await TravellerCreatureSheet.#postCreatureRoll({\n actor, roll, rollLabel,\n dm,\n difficulty: result.difficulty,\n rollMode: result.rollMode,\n extraTooltip: tooltipParts.join(\" | \"),\n });\n\n // Roll damage only on success\n if (success && attack.damage) {\n const dmgFormula = normalizeDice(attack.damage);\n const dmgRoll = await new Roll(dmgFormula).evaluate();\n await dmgRoll.toMessage({\n speaker: ChatMessage.getSpeaker({ actor }),\n flavor: `${actor.name} — ${game.i18n.localize(\"MGT2.Chat.Weapon.Damage\")}: ${attack.name} (${attack.damage})`,\n rollMode: result.rollMode ?? game.settings.get(\"core\", \"rollMode\"),\n });\n }\n }\n\n // ───────────────────────────────────────────────────────── CRUD Handlers\n\n static async #onAddRow(event, target) {\n const prop = target.dataset.prop;\n if (!prop) return;\n const actor = this.document;\n const arr = foundry.utils.deepClone(actor.system[prop] ?? []);\n arr.push(this._getDefaultRow(prop));\n await actor.update({ [`system.${prop}`]: arr });\n }\n\n static async #onDeleteRow(event, target) {\n const prop = target.dataset.prop;\n const index = parseInt(target.dataset.index);\n if (!prop || isNaN(index)) return;\n const actor = this.document;\n const arr = foundry.utils.deepClone(actor.system[prop] ?? []);\n arr.splice(index, 1);\n await actor.update({ [`system.${prop}`]: arr });\n }\n\n _getDefaultRow(prop) {\n switch (prop) {\n case \"skills\": return { name: \"\", level: 0, note: \"\" };\n case \"attacks\": return { name: \"\", damage: \"1D\", skill: -1, description: \"\" };\n case \"traits\": return { name: \"\", value: \"\", description: \"\" };\n default: return {};\n }\n }\n}\n","const { HandlebarsApplicationMixin } = foundry.applications.api;\nimport { MGT2Helper } from \"../../helper.js\";\n\nexport default class TravellerItemSheet extends HandlebarsApplicationMixin(foundry.applications.sheets.ItemSheetV2) {\n\n /** @override */\n static DEFAULT_OPTIONS = {\n classes: [\"mgt2\", \"sheet\", \"item\"],\n position: { width: 630 },\n form: {\n submitOnChange: true,\n closeOnSubmit: false,\n },\n window: { resizable: true },\n actions: {\n careerEventCreate: TravellerItemSheet.#onCareerEventCreate,\n careerEventDelete: TravellerItemSheet.#onCareerEventDelete,\n optionCreate: TravellerItemSheet.#onOptionCreate,\n optionDelete: TravellerItemSheet.#onOptionDelete,\n modifierCreate: TravellerItemSheet.#onModifierCreate,\n modifierDelete: TravellerItemSheet.#onModifierDelete,\n },\n }\n\n /** Dynamic PARTS: template resolved per item type */\n get PARTS() {\n const type = this.document?.type ?? \"item\";\n return {\n sheet: {\n template: `systems/mgt2/templates/items/${type}-sheet.html`,\n },\n };\n }\n\n /** Resolve template dynamically based on item type */\n get template() {\n return `systems/mgt2/templates/items/${this.document.type}-sheet.html`;\n }\n\n tabGroups = { primary: \"tab1\" }\n\n /** @override */\n async _prepareContext() {\n const item = this.document;\n const source = item.toObject();\n\n const settings = {\n usePronouns: game.settings.get(\"mgt2\", \"usePronouns\"),\n };\n\n let containers = null;\n let computers = null;\n let hadContainer = false;\n\n if (item.actor !== null) {\n hadContainer = true;\n containers = [{ name: \"\", _id: \"\" }].concat(item.actor.getContainers());\n computers = [{ name: \"\", _id: \"\" }].concat(item.actor.getComputers());\n }\n\n let weight = null;\n if (item.system.hasOwnProperty(\"weight\")) {\n weight = MGT2Helper.convertWeightForDisplay(item.system.weight);\n }\n\n let skills = [];\n if (this.actor !== null) {\n for (let actorItem of this.actor.items) {\n if (actorItem.type === \"talent\" && actorItem.system.subType === \"skill\")\n skills.push({ _id: actorItem._id, name: actorItem.getRollDisplay() });\n }\n }\n skills.sort(MGT2Helper.compareByName);\n skills = [{ _id: \"NP\", name: game.i18n.localize(\"MGT2.Items.NotProficient\") }].concat(skills);\n\n const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? \"\", { async: true });\n\n return {\n item: item,\n document: item,\n cssClass: this.isEditable ? \"editable\" : \"locked\",\n system: item.system,\n source: source.system,\n fields: item.schema.fields,\n systemFields: item.system.schema.fields,\n isEditable: this.isEditable,\n isGM: game.user.isGM,\n config: CONFIG.MGT2,\n settings: settings,\n containers: containers,\n computers: computers,\n hadContainer: hadContainer,\n weight: weight,\n unitlabels: { weight: MGT2Helper.getWeightLabel() },\n skills: skills,\n enrichedDescription: await enrich(item.system.description),\n enrichedDescriptionLong: await enrich(item.system.descriptionLong),\n enrichedNotes: await enrich(item.system.notes),\n enrichedLockedDescription: await enrich(item.system.lockedDescription),\n };\n }\n\n /** @override — resolve the per-type template before rendering */\n async _renderHTML(context, options) {\n const templatePath = `systems/mgt2/templates/items/${this.document.type}-sheet.html`;\n const html = await foundry.applications.handlebars.renderTemplate(templatePath, context);\n return { sheet: html };\n }\n\n /** @override — put rendered HTML into the window content */\n _replaceHTML(result, content, options) {\n content.innerHTML = result.sheet;\n // Inject theme class dynamically (can't use game.settings in static DEFAULT_OPTIONS)\n const theme = game.settings.get(\"mgt2\", \"theme\");\n if (theme) this.element.classList.add(theme);\n this._activateTabGroups();\n this._bindItemEvents();\n }\n\n /** Bind CSS class-based events (templates not yet migrated to data-action) */\n _bindItemEvents() {\n const html = this.element;\n if (!this.isEditable) return;\n const bind = (sel, handler) => {\n for (const el of html.querySelectorAll(sel)) {\n el.addEventListener(\"click\", (ev) => handler.call(this, ev, ev.currentTarget));\n }\n };\n bind(\".event-create\", TravellerItemSheet.#onCareerEventCreate);\n bind(\".event-delete\", TravellerItemSheet.#onCareerEventDelete);\n bind(\".options-create\", TravellerItemSheet.#onOptionCreate);\n bind(\".options-delete\", TravellerItemSheet.#onOptionDelete);\n bind(\".modifiers-create\", TravellerItemSheet.#onModifierCreate);\n bind(\".modifiers-delete\", TravellerItemSheet.#onModifierDelete);\n\n // Activate ProseMirror editors for HTMLField fields\n for (const btn of html.querySelectorAll(\".editor-edit\")) {\n btn.addEventListener(\"click\", async (event) => {\n event.preventDefault();\n const editorWrapper = btn.closest(\".editor\");\n if (!editorWrapper) return;\n const editorContent = editorWrapper.querySelector(\".editor-content\");\n if (!editorContent || editorContent.classList.contains(\"ProseMirror\")) return;\n const target = editorContent.dataset.edit;\n const value = foundry.utils.getProperty(this.document, target) ?? \"\";\n btn.remove();\n editorWrapper.classList.add(\"prosemirror\");\n await ProseMirrorEditor.create(editorContent, value, {\n document: this.document,\n fieldName: target,\n plugins: {},\n collaborate: false,\n });\n });\n }\n }\n\n _activateTabGroups() {\n for (const [group, activeTab] of Object.entries(this.tabGroups)) {\n const nav = this.element.querySelector(`nav[data-group=\"${group}\"], .horizontal-tabs`);\n if (!nav) continue;\n\n nav.querySelectorAll('[data-tab]').forEach(link => {\n link.classList.toggle('active', link.dataset.tab === activeTab);\n link.addEventListener('click', event => {\n event.preventDefault();\n this.tabGroups[group] = link.dataset.tab;\n this.render();\n });\n });\n\n this.element.querySelectorAll(`.itemsheet-panel [data-tab], [data-group=\"${group}\"][data-tab]`).forEach(content => {\n content.classList.toggle('active', content.dataset.tab === activeTab);\n });\n }\n }\n\n /** @override — process form data before submit (weight/qty/cost conversions + container logic) */\n _prepareSubmitData(event, form, formData) {\n const data = foundry.utils.expandObject(formData.object);\n\n if (data.hasOwnProperty(\"weight\")) {\n data.system = data.system || {};\n data.system.weight = MGT2Helper.convertWeightFromInput(data.weight);\n delete data.weight;\n }\n\n if (data.system?.hasOwnProperty(\"quantity\")) {\n data.system.quantity = MGT2Helper.getIntegerFromInput(data.system.quantity);\n }\n\n if (data.system?.hasOwnProperty(\"cost\")) {\n data.system.cost = MGT2Helper.getIntegerFromInput(data.system.cost);\n }\n\n // Container/equipped logic\n if (data.system?.hasOwnProperty(\"container\") && this.document.system.hasOwnProperty(\"equipped\")) {\n const equippedChange = this.document.system.equipped !== data.system.equipped;\n const containerChange = this.document.system.container?.id !== data.system.container?.id;\n\n if (equippedChange && data.system.equipped === true) {\n data.system.container = { id: \"\" };\n } else if (containerChange && data.system.container?.id !== \"\" && this.document.system.container?.id === \"\") {\n data.system.equipped = false;\n }\n }\n\n return foundry.utils.flattenObject(data);\n }\n\n // =========================================================\n // Actions\n // =========================================================\n\n static async #onCareerEventCreate(event) {\n event.preventDefault();\n const events = this.document.system.events;\n let newEvents;\n if (!events || events.length === 0) {\n newEvents = [{ age: \"\", description: \"\" }];\n } else {\n newEvents = [...events, { age: \"\", description: \"\" }];\n }\n return this.document.update({ system: { events: newEvents } });\n }\n\n static async #onCareerEventDelete(event, target) {\n event.preventDefault();\n const element = target.closest(\"[data-events-part]\");\n const index = Number(element.dataset.eventsPart);\n const events = foundry.utils.deepClone(this.document.system.events);\n const newEvents = Object.entries(events)\n .filter(([key]) => Number(key) !== index)\n .map(([, val]) => val);\n return this.document.update({ system: { events: newEvents } });\n }\n\n static async #onOptionCreate(event, target) {\n event.preventDefault();\n const property = target.dataset.property;\n const options = this.document.system[property];\n let newOptions;\n if (!options || options.length === 0) {\n newOptions = [{ name: \"\", description: \"\" }];\n } else {\n newOptions = [...options, { name: \"\", description: \"\" }];\n }\n return this.document.update({ [`system.${property}`]: newOptions });\n }\n\n static async #onOptionDelete(event, target) {\n event.preventDefault();\n const element = target.closest(\"[data-options-part]\");\n const property = element.dataset.property;\n const index = Number(element.dataset.optionsPart);\n const options = foundry.utils.deepClone(this.document.system[property]);\n const newOptions = Object.entries(options)\n .filter(([key]) => Number(key) !== index)\n .map(([, val]) => val);\n return this.document.update({ [`system.${property}`]: newOptions });\n }\n\n static async #onModifierCreate(event) {\n event.preventDefault();\n const modifiers = this.document.system.modifiers;\n let newModifiers;\n if (!modifiers || modifiers.length === 0) {\n newModifiers = [{ characteristic: \"Endurance\", value: null }];\n } else {\n newModifiers = [...modifiers, { characteristic: \"Endurance\", value: null }];\n }\n return this.document.update({ system: { modifiers: newModifiers } });\n }\n\n static async #onModifierDelete(event, target) {\n event.preventDefault();\n const element = target.closest(\"[data-modifiers-part]\");\n const index = Number(element.dataset.modifiersPart);\n const modifiers = foundry.utils.deepClone(this.document.system.modifiers);\n const newModifiers = Object.entries(modifiers)\n .filter(([key]) => Number(key) !== index)\n .map(([, val]) => val);\n return this.document.update({ system: { modifiers: newModifiers } });\n }\n}\n","/**\n * Define a set of template paths to pre-load\n * Pre-loaded templates are compiled and cached for fast access when rendering\n * @return {Promise}\n */\nexport const preloadHandlebarsTemplates = async function() {\n\n const templatePaths = [\n \"systems/mgt2/templates/items/armor-sheet.html\",\n \"systems/mgt2/templates/items/career-sheet.html\",\n \"systems/mgt2/templates/items/computer-sheet.html\",\n \"systems/mgt2/templates/items/contact-sheet.html\",\n \"systems/mgt2/templates/items/container-sheet.html\",\n \"systems/mgt2/templates/items/disease-sheet.html\",\n \"systems/mgt2/templates/items/equipment-sheet.html\",\n \"systems/mgt2/templates/items/item-sheet.html\",\n \"systems/mgt2/templates/items/species-sheet.html\",\n \"systems/mgt2/templates/items/talent-sheet.html\",\n \"systems/mgt2/templates/items/weapon-sheet.html\",\n \"systems/mgt2/templates/items/parts/sheet-configuration.html\",\n \"systems/mgt2/templates/items/parts/sheet-physical-item.html\",\n \"systems/mgt2/templates/items/parts/sheet-physical-item-tab.html\",\n \"systems/mgt2/templates/roll-prompt.html\",\n \"systems/mgt2/templates/chat/roll.html\",\n //\"systems/mgt2/templates/chat/roll-characteristic.html\",\n \"systems/mgt2/templates/actors/actor-config-sheet.html\",\n \"systems/mgt2/templates/actors/actor-config-characteristic-sheet.html\",\n \"systems/mgt2/templates/actors/trait-sheet.html\",\n \"systems/mgt2/templates/actors/creature-sheet.html\",\n \"systems/mgt2/templates/chat/creature-roll.html\",\n \"systems/mgt2/templates/editor-fullview.html\"\n ];\n \n const loader = foundry.applications?.handlebars?.loadTemplates ?? loadTemplates;\n return loader(templatePaths);\n };","import { MGT2Helper } from \"./helper.js\";\n\nexport class ChatHelper {\n\n static setupCardListeners(message, element, messageData) {\n if (!message || !element) {\n return;\n }\n element.querySelectorAll('button[data-action=\"rollDamage\"]').forEach(el => {\n el.addEventListener('click', async event => {\n await this._processRollDamageButtonEvent(message, event);\n });\n });\n\n element.querySelectorAll('button[data-action=\"damage\"]').forEach(el => {\n el.addEventListener('click', async event => {\n await this._applyChatCardDamage(message, event);\n });\n });\n\n element.querySelectorAll('button[data-action=\"healing\"]').forEach(el => {\n el.addEventListener('click', async event => {\n await this._applyChatCardHealing(message, event);\n });\n });\n\n element.querySelectorAll('button[data-action=\"surgeryDamage\"]').forEach(el => {\n el.addEventListener('click', async event => {\n await this._applyChatCardSurgeryDamage(message, event);\n });\n });\n\n element.querySelectorAll('button[data-index]:not([data-action])').forEach(el => {\n el.addEventListener('click', async event => {\n await this._processRollButtonEvent(message, event);\n });\n });\n }\n\n static async _processRollButtonEvent(message, event) {\n event.preventDefault();\n event.stopPropagation();\n let buttons = message.flags.mgt2.buttons;\n const index = event.target.dataset.index;\n const button = buttons[index];\n let roll = await new Roll(button.formula, {}).roll();\n\n const chatData = {\n user: game.user.id,\n speaker: message.speaker,\n formula: roll._formula,\n tooltip: await roll.getTooltip(),\n total: Math.round(roll.total * 100) / 100,\n rollObjectName: button.message.objectName,\n rollMessage: MGT2Helper.format(button.message.flavor, Math.round(roll.total * 100) / 100),\n };\n\n const html = await foundry.applications.handlebars.renderTemplate(\"systems/mgt2/templates/chat/roll.html\", chatData);\n chatData.content = html;\n return roll.toMessage(chatData);\n }\n\n static async _processRollDamageButtonEvent(message, event) {\n event.preventDefault();\n event.stopPropagation();\n let rollFormula = message.flags.mgt2.damage.formula;\n\n let roll = await new Roll(rollFormula, {}).roll();\n\n let speaker;\n let selectTokens = canvas.tokens.controlled;\n if (selectTokens.length > 0) {\n speaker = selectTokens[0].actor;\n } else {\n speaker = game.user.character;\n }\n\n let rollTypeName = message.flags.mgt2.damage.rollTypeName ? message.flags.mgt2.damage.rollTypeName + \" \" + game.i18n.localize(\"MGT2.Actor.Damage\") : null;\n\n const chatData = {\n user: game.user.id,\n speaker: ChatMessage.getSpeaker({ actor: speaker }),\n formula: roll._formula,\n tooltip: await roll.getTooltip(),\n total: Math.round(roll.total * 100) / 100,\n showButtons: true,\n hasDamage: true,\n rollTypeName: rollTypeName,\n rollObjectName: message.flags.mgt2.damage.rollObjectName\n };\n\n const html = await foundry.applications.handlebars.renderTemplate(\"systems/mgt2/templates/chat/roll.html\", chatData);\n chatData.content = html;\n\n return roll.toMessage(chatData);\n }\n\n static _applyChatCardDamage(message, event) {\n if (canvas.tokens.controlled.length === 0) {\n ui.notifications.warn(game.i18n.localize(\"MGT2.Errors.NoTokenSelected\"));\n return;\n }\n const roll = message.rolls[0];\n return Promise.all(canvas.tokens.controlled.map(t => {\n const a = t.actor;\n return a.applyDamage(roll.total);\n }));\n }\n\n static _applyChatCardHealing(message, event) {\n if (canvas.tokens.controlled.length === 0) {\n ui.notifications.warn(game.i18n.localize(\"MGT2.Errors.NoTokenSelected\"));\n return;\n }\n // For First Aid/Surgery healing, use amount from flags; otherwise use roll total\n const amount = message.flags?.mgt2?.healing?.amount\n ?? message.flags?.mgt2?.surgery?.healing\n ?? Math.max(1, message.rolls[0].total);\n return Promise.all(canvas.tokens.controlled.map(t => {\n const a = t.actor;\n return a.applyHealing(amount);\n }));\n }\n\n static _applyChatCardSurgeryDamage(message, event) {\n if (canvas.tokens.controlled.length === 0) {\n ui.notifications.warn(game.i18n.localize(\"MGT2.Errors.NoTokenSelected\"));\n return;\n }\n const amount = message.flags?.mgt2?.surgery?.surgeryDamage ?? 3;\n return Promise.all(canvas.tokens.controlled.map(t => {\n const a = t.actor;\n return a.applyDamage(amount, { ignoreArmor: true });\n }));\n }\n}","export const registerSettings = function () {\n\n game.settings.register(\"mgt2\", \"theme\", {\n name: \"MGT2.Settings.theme.name\",\n hint: \"MGT2.Settings.theme.hint\",\n scope: \"client\",\n config: true,\n default: \"black-and-red\",\n type: String,\n choices: {\n \"black-and-red\": \"MGT2.Themes.BlackAndRed\",\n \"mwamba\": \"MGT2.Themes.Mwamba\",\n \"blue\": \"MGT2.Themes.Blue\"\n },\n requiresReload: true\n });\n\n game.settings.register('mgt2', 'usePronouns', {\n name: \"MGT2.Settings.usePronouns.name\",\n hint: \"MGT2.Settings.usePronouns.hint\",\n default: false,\n scope: 'world',\n type: Boolean,\n config: true,\n requiresReload: false\n });\n\n game.settings.register('mgt2', 'useGender', {\n name: \"MGT2.Settings.useGender.name\",\n hint: \"MGT2.Settings.useGender.hint\",\n default: false,\n scope: 'world',\n type: Boolean,\n config: true,\n requiresReload: false\n });\n\n game.settings.register('mgt2', 'showLife', {\n name: \"MGT2.Settings.showLife.name\",\n hint: \"MGT2.Settings.showLife.hint\",\n default: false,\n scope: 'world',\n type: Boolean,\n config: true,\n requiresReload: false\n });\n\n // game.settings.register('mgt2', 'useWeightMetric', {\n // name: \"MGT2.Settings.useWeightMetric.name\",\n // hint: \"MGT2.Settings.useWeightMetric.hint\",\n // default: true,\n // scope: 'world',\n // type: Boolean,\n // config: true,\n // requiresReload: true\n // });\n\n // game.settings.register('mgt2', 'useDistanceMetric', {\n // name: \"MGT2.Settings.useDistanceMetric.name\",\n // hint: \"MGT2.Settings.useDistanceMetric.hint\",\n // default: true,\n // scope: 'world',\n // type: Boolean,\n // config: true,\n // requiresReload: true\n // });\n\n // game.settings.register('mgt2', 'showTrash', {\n // name: \"Show Trash tab to Player\",\n // hint: \"Player can see the Trash tab and recover item\",\n // default: false,\n // scope: 'world',\n // type: Boolean,\n // config: true,\n // requiresReload: false\n // });\n\n /*game.settings.register('mgt2', 'containerDropIn', {\n name: \"Test\",\n hint: \"Mon hint\",\n default: true,\n scope: 'client',\n type: Boolean,\n config: true\n });*/\n};\n","import {\n CharacterData,\n VehiculeData,\n CreatureData,\n ItemData,\n EquipmentData,\n DiseaseData,\n CareerData,\n TalentData,\n ContactData,\n ArmorData,\n ComputerData,\n WeaponData,\n ItemContainerData,\n SpeciesData\n} from \"./models/index.mjs\";\n\nimport { MGT2 } from \"./config.js\";\nimport { TravellerActor, MGT2Combatant } from \"./actors/actor.js\";\nimport { TravellerItem } from \"./item.js\";\nimport { TravellerItemSheet, TravellerCharacterSheet, TravellerVehiculeSheet, TravellerCreatureSheet } from \"./applications/sheets/_module.mjs\";\nimport { preloadHandlebarsTemplates } from \"./templates.js\";\n//import { MGT2Helper } from \"./helper.js\";\nimport {ChatHelper} from \"./chatHelper.js\";\n\n/* -------------------------------------------- */\n/* Foundry VTT Initialization */\n/* -------------------------------------------- */\nimport { registerSettings } from \"./settings.js\";\n\nfunction registerHandlebarsHelpers() {\n Handlebars.registerHelper('showDM', function (dm) {\n if (dm === 0) return \"0\";\n if (dm > 0) return `+${dm}`;\n if (dm < 0) return `${dm}`;\n return \"\";\n });\n}\n\nHooks.once(\"init\", async function () {\n CONFIG.MGT2 = MGT2;\n CONFIG.Combat.initiative = {\n formula: \"2d6 + @initiative\",\n decimals: 2\n };\n\n CONFIG.Actor.trackableAttributes = {\n character: {\n bar: [\"life\",\n \"characteristics.strength\",\n \"characteristics.dexterity\",\n \"characteristics.endurance\",\n \"characteristics.intellect\",\n \"characteristics.education\",\n \"characteristics.social\",\n \"characteristics.morale\",\n \"characteristics.luck\",\n \"characteristics.sanity\",\n \"characteristics.charm\",\n \"characteristics.psionic\",\n \"characteristics.other\"\n ],\n value: [\"life.value\",\n \"health.radiations\",\n \"characteristics.strength.value\",\n \"characteristics.dexterity.value\",\n \"characteristics.endurance.value\",\n \"characteristics.intellect.value\",\n \"characteristics.education.value\",\n \"characteristics.social.value\",\n \"characteristics.morale.value\",\n \"characteristics.luck.value\",\n \"characteristics.sanity.value\",\n \"characteristics.charm.value\",\n \"characteristics.psionic.value\",\n \"characteristics.other.value\"]\n },\n creature: {\n bar: [\"life\"],\n value: [\"life.value\", \"life.max\", \"speed\", \"armor\", \"psi\"]\n }\n };\n\n game.mgt2 = {\n TravellerActor,\n TravellerItem\n };\n\n registerHandlebarsHelpers();\n registerSettings();\n\n CONFIG.Combatant.documentClass = MGT2Combatant;\n CONFIG.Actor.documentClass = TravellerActor;\n CONFIG.Item.documentClass = TravellerItem;\n\n foundry.documents.collections.Actors.unregisterSheet(\"core\", foundry.appv1.sheets.ActorSheet);\n foundry.documents.collections.Actors.registerSheet(\"mgt2\", TravellerCharacterSheet, { types: [\"character\"], makeDefault: true, label: \"Traveller Sheet\" });\n foundry.documents.collections.Actors.registerSheet(\"mgt2\", TravellerVehiculeSheet, { types: [\"vehicule\"], makeDefault: true, label: \"Vehicule Sheet\" });\n foundry.documents.collections.Actors.registerSheet(\"mgt2\", TravellerCreatureSheet, { types: [\"creature\"], makeDefault: true, label: \"Creature Sheet\" });\n\n foundry.documents.collections.Items.unregisterSheet(\"core\", foundry.appv1.sheets.ItemSheet);\n foundry.documents.collections.Items.registerSheet(\"mgt2\", TravellerItemSheet, { makeDefault: true });\n\n Object.assign(CONFIG.Actor.dataModels, {\n \"character\": CharacterData,\n \"vehicule\": VehiculeData,\n \"creature\": CreatureData\n });\n\n Object.assign(CONFIG.Item.dataModels, {\n \"item\": ItemData,\n \"equipment\": EquipmentData,\n \"disease\": DiseaseData,\n \"career\": CareerData,\n \"talent\": TalentData,\n \"contact\": ContactData,\n \"weapon\": WeaponData,\n \"computer\": ComputerData,\n \"armor\": ArmorData,\n \"container\": ItemContainerData,\n \"species\": SpeciesData\n });\n\n\n Hooks.on(\"renderChatMessageHTML\", (message, element, messageData) => {\n ChatHelper.setupCardListeners(message, element, messageData);\n });\n\n // Preload template partials\n await preloadHandlebarsTemplates();\n});\n\nexport { MGT2 };"],"names":["fields","HandlebarsApplicationMixin","DialogV2","renderTemplate","FormDataExtended"],"mappings":"AAAA,MAAMA,QAAM,GAAG,OAAO,CAAC,IAAI,CAAC,MAAM;;AAE3B,SAAS,yBAAyB,CAAC,IAAI,GAAG,IAAI,EAAE,OAAO,GAA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CAAC,SAAS,CAAC,WAAW,CAAC,KAAK,CAAC,eAAe,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC,SAAS,CAAC;AAC7F,EAAE,OAAO,CAAC,SAAS,CAAC,WAAW,CAAC,KAAK,CAAC,aAAa,CAAC,MAAM,EAAE,kBAAkB,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE,CAAC;;AAEtG,EAAE,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,UAAU,EAAE;AACzC,IAAI,WAAW,EAAE,aAAa;AAC9B,IAAI,UAAU,EAAE,YAAY;AAC5B,IAAI,UAAU,EAAE;AAChB,GAAG,CAAC;;AAEJ,EAAE,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU,EAAE;AACxC,IAAI,MAAM,EAAE,QAAQ;AACpB,IAAI,WAAW,EAAE,aAAa;AAC9B,IAAI,SAAS,EAAE,WAAW;AAC1B,IAAI,QAAQ,EAAE,UAAU;AACxB,IAAI,QAAQ,EAAE,UAAU;AACxB,IAAI,SAAS,EAAE,WAAW;AAC1B,IAAI,QAAQ,EAAE,UAAU;AACxB,IAAI,UAAU,EAAE,YAAY;AAC5B,IAAI,OAAO,EAAE,SAAS;AACtB,IAAI,WAAW,EAAE,iBAAiB;AAClC,IAAI,SAAS,EAAE;AACf,GAAG,CAAC;;;AAGJ,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,EAAE,CAAC,OAAO,EAAE,OAAO,EAAE,WAAW,KAAK;AACvE,IAAI,UAAU,CAAC,kBAAkB,CAAC,OAAO,EAAE,OAAO,EAAE,WAAW,CAAC;AAChE,EAAE,CAAC,CAAC;;AAEJ;AACA,EAAE,MAAM,0BAA0B,EAAE;AACpC,CAAC,CAAC;;;;"}
\ No newline at end of file
diff --git a/src/module/actors/actor.js b/src/module/actors/actor.js
index ea4eaf6..52b2193 100644
--- a/src/module/actors/actor.js
+++ b/src/module/actors/actor.js
@@ -52,9 +52,32 @@ export class TravellerActor extends Actor {
}
}
- applyDamage(amount) {
+ applyDamage(amount, { ignoreArmor = false } = {}) {
if (this.type === "character") {
- ActorCharacter.applyDamage(this, amount);
+ return ActorCharacter.applyDamage(this, amount, { ignoreArmor });
+ } else if (this.type === "creature") {
+ if (isNaN(amount) || amount === 0) return;
+ if (amount < 0) amount = Math.abs(amount);
+ const armorValue = ignoreArmor ? 0 : (this.system.armor ?? 0);
+ const effective = Math.max(0, amount - armorValue);
+ if (effective === 0) return;
+ const newValue = Math.max(0, (this.system.life.value ?? 0) - effective);
+ return this.update({ "system.life.value": newValue });
+ }
+ }
+
+ applyHealing(amount) {
+ if (this.type === "character") {
+ return ActorCharacter.applyHealing(this, amount);
+ } else if (this.type === "creature") {
+ if (isNaN(amount) || amount === 0) return;
+ if (amount < 0) amount = Math.abs(amount);
+ const maxValue = this.system.life.max ?? 0;
+ const current = this.system.life.value ?? 0;
+ const newValue = Math.min(current + amount, maxValue);
+ if (newValue !== current) {
+ return this.update({ "system.life.value": newValue });
+ }
}
}
diff --git a/src/module/actors/character-prompts.js b/src/module/actors/character-prompts.js
index 257b96b..52a9ac5 100644
--- a/src/module/actors/character-prompts.js
+++ b/src/module/actors/character-prompts.js
@@ -70,4 +70,35 @@ export class CharacterPrompts {
]
});
}
+
+ static async openHealingDays() {
+ return await DialogV2.wait({
+ window: {
+ title: game.i18n.localize("MGT2.Healing.Title")
+ },
+ classes: ["mgt2-roll-dialog"],
+ content: `
+
+ `,
+ rejectClose: false,
+ buttons: [
+ {
+ action: "submit",
+ label: game.i18n.localize("MGT2.Save"),
+ icon: '',
+ default: true,
+ callback: (event, button, dialog) => {
+ return new FormDataExtended(dialog.element.querySelector('form')).object;
+ }
+ }
+ ]
+ });
+ }
}
\ No newline at end of file
diff --git a/src/module/actors/character.js b/src/module/actors/character.js
index 8e39d07..dfd14c1 100644
--- a/src/module/actors/character.js
+++ b/src/module/actors/character.js
@@ -331,7 +331,7 @@ export class ActorCharacter {
// $this.update({ system: { characteristics: data } });
// }
- static applyDamage($this, amount) {
+ static applyDamage($this, amount, { ignoreArmor = false } = {}) {
if (isNaN(amount) || amount === 0) return;
const rank1 = $this.system.config.damages.rank1;
const rank2 = $this.system.config.damages.rank2;
@@ -344,6 +344,12 @@ export class ActorCharacter {
if (amount < 0) amount = Math.abs(amount);
+ if (!ignoreArmor) {
+ const armorValue = $this.system.inventory?.armor ?? 0;
+ amount = Math.max(0, amount - armorValue);
+ if (amount === 0) return;
+ }
+
for (const [key, rank] of Object.entries(data)) {
if (rank.value > 0) {
if (rank.value >= amount) {
@@ -361,6 +367,48 @@ export class ActorCharacter {
$this.update({ system: { characteristics: data } });
}
+ static applyHealing($this, amount, type) {
+ if (isNaN(amount) || amount === 0) return;
+
+ const rank1 = $this.system.config.damages.rank1;
+ const rank2 = $this.system.config.damages.rank2;
+ const rank3 = $this.system.config.damages.rank3;
+
+ // Data to restore (reverse cascade: END → DEX → STR)
+ const data = {};
+ const rankOrder = [rank3, rank2, rank1]; // Reverse order for healing
+ const maxValues = {
+ [rank1]: $this.system.characteristics[rank1].max,
+ [rank2]: $this.system.characteristics[rank2].max,
+ [rank3]: $this.system.characteristics[rank3].max
+ };
+
+ if (amount < 0) amount = Math.abs(amount);
+
+ // Distribute healing from lowest rank first (END → DEX → STR typically)
+ for (const rank of rankOrder) {
+ const current = $this.system.characteristics[rank].value;
+ const max = maxValues[rank];
+
+ if (current < max && amount > 0) {
+ const canRestore = max - current;
+ const restore = Math.min(amount, canRestore);
+
+ if (!data[rank]) {
+ data[rank] = { value: current };
+ }
+ data[rank].value += restore;
+ data[rank].dm = this.getModifier(data[rank].value);
+ amount -= restore;
+ }
+ }
+
+ // Only update if something was restored
+ if (Object.keys(data).length > 0) {
+ return $this.update({ system: { characteristics: data } });
+ }
+ }
+
static getContainers($this) {
const containers = [];
for (let item of $this.items) {
diff --git a/src/module/applications/sheets/character-sheet.mjs b/src/module/applications/sheets/character-sheet.mjs
index cecedce..1a0e051 100644
--- a/src/module/applications/sheets/character-sheet.mjs
+++ b/src/module/applications/sheets/character-sheet.mjs
@@ -33,6 +33,7 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
traitEdit: TravellerCharacterSheet.#onTraitEdit,
traitDelete: TravellerCharacterSheet.#onTraitDelete,
openEditor: TravellerCharacterSheet.#onOpenEditor,
+ heal: TravellerCharacterSheet.#onHeal,
},
}
@@ -54,7 +55,11 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
async _prepareContext() {
const context = await super._prepareContext();
const actor = this.document;
+ const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? "", { async: true });
+ context.enrichedBiography = await enrich(actor.system.biography);
+ context.enrichedNotes = await enrich(actor.system.notes);
+ context.enrichedFinanceNotes = await enrich(actor.system.finance?.notes);
context.settings = {
weightUnit: "kg",
usePronouns: game.settings.get("mgt2", "usePronouns"),
@@ -152,9 +157,10 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
if (item.hasOwnProperty("equipped")) {
i._canEquip = true;
- i._toggleClass = item.equipped ? "active" : "";
+ i.toggleClass = item.equipped ? "active" : "";
} else {
i._canEquip = false;
+ i.toggleClass = "";
}
switch (i.type) {
@@ -288,7 +294,6 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
this._bindClassEvent(html, ".item-create", "click", TravellerCharacterSheet.#onCreateItem);
this._bindClassEvent(html, ".item-edit", "click", TravellerCharacterSheet.#onEditItem);
this._bindClassEvent(html, ".item-delete", "click", TravellerCharacterSheet.#onDeleteItem);
- this._bindClassEvent(html, ".item-equip", "click", TravellerCharacterSheet.#onEquipItem);
this._bindClassEvent(html, ".item-storage-in", "click", TravellerCharacterSheet.#onItemStorageIn);
this._bindClassEvent(html, ".item-storage-out", "click", TravellerCharacterSheet.#onItemStorageOut);
this._bindClassEvent(html, ".software-eject", "click", TravellerCharacterSheet.#onSoftwareEject);
@@ -452,17 +457,34 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
if (item) item.sheet.render(true);
}
+ static async #confirmDelete(name) {
+ return foundry.applications.api.DialogV2.confirm({
+ window: { title: game.i18n.localize("MGT2.Dialog.ConfirmDeleteTitle") },
+ content: `${game.i18n.format("MGT2.Dialog.ConfirmDeleteContent", { name })}
`,
+ yes: { label: game.i18n.localize("MGT2.Dialog.Yes"), icon: "fas fa-trash" },
+ no: { label: game.i18n.localize("MGT2.Dialog.No"), icon: "fas fa-times" },
+ rejectClose: false,
+ modal: true
+ });
+ }
+
static async #onDeleteItem(event, target) {
event.preventDefault();
const li = target.closest("[data-item-id]");
if (!li?.dataset.itemId) return;
+ const item = this.actor.items.get(li.dataset.itemId);
+ if (!item) return;
+ const confirmed = await TravellerCharacterSheet.#confirmDelete(item.name);
+ if (!confirmed) return;
this.actor.deleteEmbeddedDocuments("Item", [li.dataset.itemId]);
}
static async #onEquipItem(event, target) {
event.preventDefault();
const li = target.closest("[data-item-id]");
- const item = this.actor.getEmbeddedDocument("Item", li?.dataset.itemId);
+ const itemId = li?.dataset.itemId;
+ if (!itemId) return;
+ const item = this.actor.items.get(itemId);
if (!item) return;
await item.update({ "system.equipped": !item.system.equipped });
}
@@ -530,6 +552,9 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
const container = containers.find(x => x._id === this.actor.system.containerView);
if (!container) return;
+ const confirmed = await TravellerCharacterSheet.#confirmDelete(container.name);
+ if (!confirmed) return;
+
const containerItems = this.actor.items.filter(
x => x.system.hasOwnProperty("container") && x.system.container.id === container._id
);
@@ -564,6 +589,7 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
encumbrance: this.actor.system.states.encumbrance,
difficulty: null,
damageFormula: null,
+ isMelee: false,
};
const cardButtons = [];
@@ -631,6 +657,9 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
if (itemObj?.system.hasOwnProperty("damage")) {
rollOptions.damageFormula = itemObj.system.damage;
+ if (itemObj.type === "weapon") {
+ rollOptions.isMelee = itemObj.system.range?.isMelee === true;
+ }
if (itemObj.type === "disease") {
if (itemObj.system.subType === "disease")
rollOptions.rollTypeName = game.i18n.localize("MGT2.DiseaseSubType.disease");
@@ -695,13 +724,13 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
rollModifiers.push(game.i18n.localize("MGT2.Actor.Fatigue") + " -2");
}
- if (userRollData.customDM) {
- const s = userRollData.customDM.trim();
- if (/^[0-9]/.test(s)) rollFormulaParts.push("+");
- rollFormulaParts.push(s);
+ const customDMVal = parseInt(userRollData.customDM ?? "0", 10);
+ if (!isNaN(customDMVal) && customDMVal !== 0) {
+ rollFormulaParts.push(customDMVal > 0 ? `+${customDMVal}` : `${customDMVal}`);
+ rollModifiers.push(game.i18n.localize("MGT2.RollPrompt.CustomDM") + " " + (customDMVal > 0 ? `+${customDMVal}` : `${customDMVal}`));
}
- if (MGT2Helper.hasValue(userRollData, "difficulty")) rollOptions.difficulty = userRollData.difficulty;
+ if (MGT2Helper.hasValue(userRollData, "difficulty") && userRollData.difficulty !== "") rollOptions.difficulty = userRollData.difficulty;
const rollFormula = rollFormulaParts.join("");
if (!Roll.validate(rollFormula)) {
@@ -715,37 +744,74 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
await this.token.combatant.update({ initiative: roll.total });
}
+ // ── Compute effect and effective damage formula ──────────────────────
+ let rollSuccess = false;
+ let rollFailure = false;
+ let rollEffect = undefined;
+ let rollEffectStr = undefined;
+ let difficultyValue = null;
+
+ if (MGT2Helper.hasValue(rollOptions, "difficulty")) {
+ difficultyValue = MGT2Helper.getDifficultyValue(rollOptions.difficulty);
+ rollEffect = roll.total - difficultyValue;
+ rollEffectStr = (rollEffect >= 0 ? "+" : "") + rollEffect;
+ rollSuccess = rollEffect >= 0;
+ rollFailure = !rollSuccess;
+ }
+
+ // Build effective damage formula: base + effect + STR DM (melee)
+ let effectiveDamageFormula = rollOptions.damageFormula || null;
+ if (effectiveDamageFormula) {
+ if (rollEffect !== undefined && rollEffect !== 0) {
+ effectiveDamageFormula += (rollEffect >= 0 ? "+" : "") + rollEffect;
+ }
+ if (rollOptions.isMelee) {
+ const strDm = this.actor.system.characteristics.strength?.dm ?? 0;
+ if (strDm !== 0) effectiveDamageFormula += (strDm >= 0 ? "+" : "") + strDm;
+ }
+ }
+
+ // ── Build roll breakdown tooltip ─────────────────────────────────────
+ const diceRawTotal = roll.dice.reduce((s, d) => s + d.total, 0);
+ const breakdownParts = [game.i18n.localize("MGT2.Chat.Roll.Dice") + " " + diceRawTotal];
+ for (const mod of rollModifiers) breakdownParts.push(mod);
+ if (rollEffectStr !== undefined)
+ breakdownParts.push(game.i18n.localize("MGT2.Chat.Roll.Effect") + " " + rollEffectStr);
+ const rollBreakdown = breakdownParts.join(" | ");
+
const chatData = {
user: game.user.id,
speaker: this.actor ? ChatMessage.getSpeaker({ actor: this.actor }) : null,
formula: roll._formula,
tooltip: await roll.getTooltip(),
total: Math.round(roll.total * 100) / 100,
+ rollBreakdown,
showButtons: true,
showLifeButtons: false,
showRollRequest: false,
rollTypeName: rollOptions.rollTypeName,
rollObjectName: rollOptions.rollObjectName,
rollModifiers: rollModifiers,
- showRollDamage: rollOptions.damageFormula !== null && rollOptions.damageFormula !== "",
+ // Show damage button only if there's a formula AND (no difficulty check OR roll succeeded)
+ showRollDamage: !!effectiveDamageFormula && (!difficultyValue || rollSuccess),
cardButtons: cardButtons,
};
if (MGT2Helper.hasValue(rollOptions, "difficulty")) {
chatData.rollDifficulty = rollOptions.difficulty;
chatData.rollDifficultyLabel = MGT2Helper.getDifficultyDisplay(rollOptions.difficulty);
- if (roll.total >= MGT2Helper.getDifficultyValue(rollOptions.difficulty))
- chatData.rollSuccess = true;
- else
- chatData.rollFailure = true;
+ chatData.rollEffect = rollEffect;
+ chatData.rollEffectStr = rollEffectStr;
+ chatData.rollSuccess = rollSuccess || undefined;
+ chatData.rollFailure = rollFailure || undefined;
}
const html = await foundry.applications.handlebars.renderTemplate("systems/mgt2/templates/chat/roll.html", chatData);
chatData.content = html;
let flags = null;
- if (rollOptions.damageFormula) {
- flags = { mgt2: { damage: { formula: rollOptions.damageFormula, rollObjectName: rollOptions.rollObjectName, rollTypeName: rollOptions.rollTypeName } } };
+ if (effectiveDamageFormula) {
+ flags = { mgt2: { damage: { formula: effectiveDamageFormula, rollObjectName: rollOptions.rollObjectName, rollTypeName: rollOptions.rollTypeName } } };
}
if (cardButtons.length > 0) {
if (!flags) flags = { mgt2: {} };
@@ -816,6 +882,8 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
static async #onTraitDelete(event, target) {
event.preventDefault();
+ const confirmed = await TravellerCharacterSheet.#confirmDelete(game.i18n.localize("MGT2.Actor.ThisTrait"));
+ if (!confirmed) return;
const element = target.closest("[data-traits-part]");
const index = Number(element.dataset.traitsPart);
const traits = foundry.utils.deepClone(this.actor.system.personal.traits);
@@ -832,4 +900,323 @@ export default class TravellerCharacterSheet extends MGT2ActorSheet {
this.actor.system.personal.speciesText.descriptionLong
);
}
+
+ static async #onHeal(event, target) {
+ event.preventDefault();
+ const healType = target.dataset.healType;
+
+ if (canvas.tokens.controlled.length === 0) {
+ ui.notifications.warn(game.i18n.localize("MGT2.Errors.NoTokenSelected"));
+ return;
+ }
+
+ if (healType === "firstaid") {
+ // Find Medicine skill to pre-select
+ // Use normalized string matching to handle accents
+ const medSkill = this.actor.items.find(i => {
+ if (i.type !== "talent" || i.system.subType !== "skill") return false;
+ const normalized = i.name.toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g, "");
+ return normalized.includes("medecin") || normalized.includes("medicine");
+ });
+
+ // Only EDU characteristic available for First Aid
+ const characteristics = [
+ { _id: "education", name: game.i18n.localize("MGT2.Characteristics.education.name") }
+ ];
+
+ const rollOptions = {
+ rollTypeName: game.i18n.localize("MGT2.Healing.FirstAid"),
+ rollObjectName: this.actor.name,
+ characteristics: characteristics, // Only EDU
+ characteristic: "education", // Pre-selected
+ skill: medSkill?.id ?? "", // Medicine skill ID for pre-selection (must match _id in array)
+ skillName: medSkill?.name ?? game.i18n.localize("MGT2.Healing.NoMedicineSkill"), // Display name
+ skillLevel: medSkill?.system.level ?? -3, // -3 if not found
+ skills: medSkill ? [{ _id: medSkill.id, name: medSkill.name, level: medSkill.system.level }] : [],
+ difficulty: "Average", // First Aid difficulty is 8 (Average)
+ showHeal: true,
+ healType: MGT2.HealingType.FIRST_AID,
+ };
+ const userRollData = await RollPromptHelper.roll(rollOptions);
+ if (userRollData) {
+ // Build formula with all DMs — same pattern as standard skill roll
+ const rollFormulaParts = [];
+ const rollModifiers = [];
+
+ if (userRollData.diceModifier) {
+ rollFormulaParts.push("3d6");
+ rollFormulaParts.push(userRollData.diceModifier);
+ } else {
+ rollFormulaParts.push("2d6");
+ }
+
+ if (userRollData.characteristic) {
+ const c = this.actor.system.characteristics[userRollData.characteristic];
+ rollFormulaParts.push(MGT2Helper.getFormulaDM(c.dm));
+ rollModifiers.push(game.i18n.localize(`MGT2.Characteristics.${userRollData.characteristic}.name`) + MGT2Helper.getDisplayDM(c.dm));
+ }
+
+ if (userRollData.skill && userRollData.skill !== "") {
+ if (userRollData.skill === "NP") {
+ rollFormulaParts.push("-3");
+ rollModifiers.push(game.i18n.localize("MGT2.Items.NotProficient"));
+ } else {
+ const skillObj = this.actor.getEmbeddedDocument("Item", userRollData.skill);
+ rollFormulaParts.push(MGT2Helper.getFormulaDM(skillObj.system.level));
+ rollModifiers.push(skillObj.getRollDisplay());
+ }
+ }
+
+ if (userRollData.customDM && userRollData.customDM !== "") {
+ let s = userRollData.customDM.trim();
+ if (/^[0-9]/.test(s)) rollFormulaParts.push("+");
+ rollFormulaParts.push(s);
+ rollModifiers.push("DM " + s);
+ }
+
+ const rollFormula = rollFormulaParts.join("");
+ const roll = await new Roll(rollFormula, this.actor.getRollData()).roll();
+
+ // Difficulty for First Aid is Average (8)
+ const difficulty = 8;
+ const effect = roll.total - difficulty;
+ const isSuccess = effect >= 0;
+ const healing = isSuccess ? Math.max(1, effect) : 0;
+
+ const cardButtons = isSuccess
+ ? [{ label: game.i18n.localize("MGT2.Healing.ApplyHealing"), action: "healing" }]
+ : [];
+
+ const chatData = {
+ user: game.user.id,
+ speaker: ChatMessage.getSpeaker({ actor: this.actor }),
+ formula: roll._formula,
+ tooltip: await roll.getTooltip(),
+ total: Math.round(roll.total * 100) / 100,
+ rollTypeName: game.i18n.localize("MGT2.Healing.FirstAid"),
+ rollObjectName: this.actor.name,
+ rollModifiers: rollModifiers,
+ rollDifficulty: difficulty,
+ rollDifficultyLabel: MGT2Helper.getDifficultyDisplay("Average"),
+ rollEffectStr: isSuccess ? effect.toString() : undefined,
+ healingAmount: isSuccess ? healing : undefined,
+ rollSuccess: isSuccess || undefined,
+ rollFailure: !isSuccess || undefined,
+ showButtons: isSuccess,
+ hasDamage: false,
+ showRollDamage: false,
+ cardButtons: cardButtons,
+ };
+
+ const html = await foundry.applications.handlebars.renderTemplate("systems/mgt2/templates/chat/roll.html", chatData);
+ chatData.content = html;
+ chatData.flags = { mgt2: { healing: { amount: healing } } };
+
+ return roll.toMessage(chatData);
+ }
+ } else if (healType === "surgery") {
+ // Find Medicine skill to pre-select (same as first aid)
+ const medSkill = this.actor.items.find(i => {
+ if (i.type !== "talent" || i.system.subType !== "skill") return false;
+ const normalized = i.name.toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g, "");
+ return normalized.includes("medecin") || normalized.includes("medicine");
+ });
+
+ const characteristics = [
+ { _id: "education", name: game.i18n.localize("MGT2.Characteristics.education.name") }
+ ];
+
+ const rollOptions = {
+ rollTypeName: game.i18n.localize("MGT2.Healing.Surgery"),
+ rollObjectName: this.actor.name,
+ characteristics: characteristics,
+ characteristic: "education",
+ skill: medSkill?.id ?? "",
+ skillName: medSkill?.name ?? game.i18n.localize("MGT2.Healing.NoMedicineSkill"),
+ skillLevel: medSkill?.system.level ?? -3,
+ skills: medSkill ? [{ _id: medSkill.id, name: medSkill.name, level: medSkill.system.level }] : [],
+ difficulty: "Average",
+ showHeal: true,
+ healType: MGT2.HealingType.SURGERY,
+ };
+ const userRollData = await RollPromptHelper.roll(rollOptions);
+ if (userRollData) {
+ // Build formula with all DMs — same pattern as standard skill roll
+ const rollFormulaParts = [];
+ const rollModifiers = [];
+
+ if (userRollData.diceModifier) {
+ rollFormulaParts.push("3d6");
+ rollFormulaParts.push(userRollData.diceModifier);
+ } else {
+ rollFormulaParts.push("2d6");
+ }
+
+ if (userRollData.characteristic) {
+ const c = this.actor.system.characteristics[userRollData.characteristic];
+ rollFormulaParts.push(MGT2Helper.getFormulaDM(c.dm));
+ rollModifiers.push(game.i18n.localize(`MGT2.Characteristics.${userRollData.characteristic}.name`) + MGT2Helper.getDisplayDM(c.dm));
+ }
+
+ if (userRollData.skill && userRollData.skill !== "") {
+ if (userRollData.skill === "NP") {
+ rollFormulaParts.push("-3");
+ rollModifiers.push(game.i18n.localize("MGT2.Items.NotProficient"));
+ } else {
+ const skillObj = this.actor.getEmbeddedDocument("Item", userRollData.skill);
+ rollFormulaParts.push(MGT2Helper.getFormulaDM(skillObj.system.level));
+ rollModifiers.push(skillObj.getRollDisplay());
+ }
+ }
+
+ if (userRollData.customDM && userRollData.customDM !== "") {
+ let s = userRollData.customDM.trim();
+ if (/^[0-9]/.test(s)) rollFormulaParts.push("+");
+ rollFormulaParts.push(s);
+ rollModifiers.push("DM " + s);
+ }
+
+ const rollFormula = rollFormulaParts.join("");
+ const roll = await new Roll(rollFormula, this.actor.getRollData()).roll();
+
+ // Difficulty for Surgery is Average (8)
+ const difficulty = 8;
+ const effect = roll.total - difficulty;
+ const isSuccess = effect >= 0;
+
+ // Success: heal Math.max(1, effect); Failure: patient takes 3 + |effect| damage
+ const healing = isSuccess ? Math.max(1, effect) : 0;
+ const surgeryDamage = isSuccess ? 0 : 3 + Math.abs(effect);
+
+ const cardButtons = [];
+ if (isSuccess) {
+ cardButtons.push({ label: game.i18n.localize("MGT2.Healing.ApplyHealing"), action: "healing" });
+ } else {
+ cardButtons.push({ label: game.i18n.localize("MGT2.Healing.ApplySurgeryDamage"), action: "surgeryDamage" });
+ }
+
+ const chatData = {
+ user: game.user.id,
+ speaker: ChatMessage.getSpeaker({ actor: this.actor }),
+ formula: roll._formula,
+ tooltip: await roll.getTooltip(),
+ total: Math.round(roll.total * 100) / 100,
+ rollTypeName: game.i18n.localize("MGT2.Healing.Surgery"),
+ rollObjectName: this.actor.name,
+ rollModifiers: rollModifiers,
+ rollDifficulty: difficulty,
+ rollDifficultyLabel: MGT2Helper.getDifficultyDisplay("Average"),
+ rollEffectStr: effect.toString(),
+ healingAmount: isSuccess ? healing : undefined,
+ surgeryDamageAmount: isSuccess ? undefined : surgeryDamage,
+ rollSuccess: isSuccess || undefined,
+ rollFailure: !isSuccess || undefined,
+ showButtons: true,
+ hasDamage: false,
+ showRollDamage: false,
+ cardButtons: cardButtons,
+ };
+
+ const html = await foundry.applications.handlebars.renderTemplate("systems/mgt2/templates/chat/roll.html", chatData);
+ chatData.content = html;
+ chatData.flags = { mgt2: { surgery: { healing, surgeryDamage } } };
+
+ return roll.toMessage(chatData);
+ }
+ } else if (healType === "medical") {
+ const result = await CharacterPrompts.openHealingDays();
+ if (result) {
+ const endMD = this.actor.system.characteristics.endurance.dm;
+ const medSkill = this.actor.items.find(i =>
+ i.type === "talent" &&
+ i.system.subType === "skill" &&
+ (i.name.toLowerCase().includes("medecin") || i.name.toLowerCase().includes("medicine"))
+ );
+ const skillValue = medSkill ? medSkill.system.level : 0;
+ const days = result.days;
+ const healingPerDay = Math.max(1, 3 + endMD + skillValue);
+ const totalHealing = healingPerDay * days;
+
+ const rollModifiers = [
+ `3 (base)`,
+ `${endMD >= 0 ? "+" : ""}${endMD} END`,
+ `+${skillValue} ${medSkill?.name ?? "Médecine"}`,
+ `× ${days} ${game.i18n.localize("MGT2.RollPrompt.Days").toLowerCase()}`
+ ];
+
+ const templateData = {
+ rollObjectName: this.actor.name,
+ rollTypeName: game.i18n.localize("MGT2.Healing.MedicalCare"),
+ rollModifiers,
+ formula: `${healingPerDay} ${game.i18n.localize("MGT2.Items.PerDay")}`,
+ tooltip: "",
+ total: totalHealing,
+ rollSuccess: true,
+ showButtons: true,
+ cardButtons: [
+ { action: "healing", label: game.i18n.localize("MGT2.Healing.ApplyHealing") }
+ ]
+ };
+
+ const content = await renderTemplate(
+ "systems/mgt2/templates/chat/roll.html",
+ templateData
+ );
+ await ChatMessage.create({
+ user: game.user.id,
+ speaker: ChatMessage.getSpeaker({ actor: this.actor }),
+ content,
+ flags: { mgt2: { healing: { amount: totalHealing } } }
+ });
+ }
+ } else if (healType === "natural") {
+ const result = await CharacterPrompts.openHealingDays();
+ if (result) {
+ const endMD = this.actor.system.characteristics.endurance.dm;
+ let totalAmount = 0;
+ const rolls = [];
+
+ for (let i = 0; i < result.days; i++) {
+ const roll = await new Roll("1d6").evaluate();
+ const dayHealing = Math.max(1, roll.total + endMD);
+ rolls.push({ roll, dayHealing });
+ totalAmount += dayHealing;
+ }
+
+ // Build roll details
+ const rollDisplay = rolls.map((r, idx) =>
+ `${game.i18n.localize("MGT2.RollPrompt.Days")} ${idx + 1}: 1d6 = ${r.roll.total} + ${endMD > 0 ? "+" : ""}${endMD} = ${r.dayHealing}
`
+ ).join("");
+
+ const chatData = {
+ user: game.user.id,
+ speaker: ChatMessage.getSpeaker({ actor: this.actor }),
+ content: `
+
+
${result.days} ${game.i18n.localize("MGT2.RollPrompt.Days")}
+
+ ${rollDisplay}
+
+
+ ${game.i18n.localize("MGT2.Chat.Roll.Effect")} ${totalAmount}
+
+
`,
+ flags: { mgt2: { healing: { amount: totalAmount } } }
+ };
+ await ChatMessage.create(chatData);
+
+ // Apply healing immediately
+ await this.actor.applyHealing(totalAmount);
+ ui.notifications.info(
+ game.i18n.format("MGT2.Notifications.HealingApplied",
+ { name: this.actor.name, amount: totalAmount })
+ );
+ }
+ }
+ }
}
diff --git a/src/module/applications/sheets/creature-sheet.mjs b/src/module/applications/sheets/creature-sheet.mjs
index 1a71823..3dbf10b 100644
--- a/src/module/applications/sheets/creature-sheet.mjs
+++ b/src/module/applications/sheets/creature-sheet.mjs
@@ -1,4 +1,8 @@
import MGT2ActorSheet from "./base-actor-sheet.mjs";
+import { RollPromptHelper } from "../../roll-prompt.js";
+import { MGT2Helper } from "../../helper.js";
+
+const { renderTemplate } = foundry.applications.handlebars;
/** Convert Traveller dice notation (e.g. "2D", "4D+2", "3D6") to FoundryVTT formula */
function normalizeDice(formula) {
@@ -46,13 +50,16 @@ export default class TravellerCreatureSheet extends MGT2ActorSheet {
}
/** @override */
- tabGroups = { primary: "skills" }
+ tabGroups = { primary: "combat" }
/** @override */
async _prepareContext() {
const context = await super._prepareContext();
const actor = this.document;
+ const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? "", { async: true });
+ context.enrichedBiography = await enrich(actor.system.biography);
+ context.enrichedNotes = await enrich(actor.system.notes);
context.sizeLabel = this._getSizeLabel(actor.system.life.max);
context.sizeTraitLabel = this._getSizeTrait(actor.system.life.max);
context.config = CONFIG.MGT2;
@@ -88,101 +95,36 @@ export default class TravellerCreatureSheet extends MGT2ActorSheet {
return "Grand (+6)";
}
- // ───────────────────────────────────────────────────────── Roll Handlers
+ // ───────────────────────────────────────────────────────── Roll Helpers
- /** Roll an attack (damage) with optional difficulty dialog */
- static async #onRollAttack(event, target) {
- const index = parseInt(target.dataset.index ?? 0);
- const actor = this.document;
- const attack = actor.system.attacks[index];
- if (!attack) return;
+ static async #postCreatureRoll({ actor, roll, rollLabel, dm, difficulty, difficultyLabel, rollMode, extraTooltip }) {
+ const diffTarget = MGT2Helper.getDifficultyValue(difficulty ?? "Average");
+ const hasDifficulty = !!difficulty;
+ const success = hasDifficulty ? roll.total >= diffTarget : true;
+ const effect = roll.total - diffTarget;
+ const effectStr = (effect >= 0 ? "+" : "") + effect;
- const rollFormula = normalizeDice(attack.damage);
-
- const roll = await new Roll(rollFormula).evaluate();
- const total = roll.total;
-
- await roll.toMessage({
- speaker: ChatMessage.getSpeaker({ actor }),
- flavor: `${actor.name} — ${attack.name}`,
- rollMode: game.settings.get("core", "rollMode"),
- });
- }
-
- /** Roll a skill check (2d6 + level vs difficulty) */
- static async #onRollSkill(event, target) {
- const index = parseInt(target.dataset.index ?? 0);
- const actor = this.document;
- const skill = actor.system.skills[index];
- if (!skill) return;
-
- const htmlContent = await renderTemplate(
- "systems/mgt2/templates/actors/creature-roll-prompt.html",
- {
- skillName: skill.name,
- skillLevel: skill.level,
- config: CONFIG.MGT2
- }
- );
-
- const result = await foundry.applications.api.DialogV2.wait({
- window: { title: game.i18n.localize("MGT2.Creature.RollSkill") + " — " + skill.name },
- content: htmlContent,
- rejectClose: false,
- buttons: [
- {
- action: "boon",
- label: game.i18n.localize("MGT2.RollPrompt.Boon"),
- callback: (event, button, dialog) => {
- const fd = new foundry.applications.ux.FormDataExtended(dialog.element.querySelector("form")).object;
- fd.diceModifier = "dl";
- return fd;
- }
- },
- {
- action: "roll",
- label: game.i18n.localize("MGT2.RollPrompt.Roll"),
- icon: '',
- default: true,
- callback: (event, button, dialog) =>
- new foundry.applications.ux.FormDataExtended(dialog.element.querySelector("form")).object
- },
- {
- action: "bane",
- label: game.i18n.localize("MGT2.RollPrompt.Bane"),
- callback: (event, button, dialog) => {
- const fd = new foundry.applications.ux.FormDataExtended(dialog.element.querySelector("form")).object;
- fd.diceModifier = "dh";
- return fd;
- }
- }
- ]
- });
-
- if (!result) return;
-
- const dm = parseInt(result.dm ?? 0) + (skill.level ?? 0);
- const modifier = result.diceModifier ?? "";
- const difficultyTarget = parseInt(result.difficulty ?? 8);
- const difficultyLabel = result.difficultyLabel ?? "";
-
- const diceFormula = modifier ? `3d6${modifier}` : "2d6";
- const fullFormula = dm !== 0 ? `${diceFormula} + ${dm}` : diceFormula;
-
- const roll = await new Roll(fullFormula).evaluate();
- const success = roll.total >= difficultyTarget;
+ const diceRawTotal = roll.dice.reduce((s, d) => s + d.total, 0);
+ const breakdownParts = [game.i18n.localize("MGT2.Chat.Roll.Dice") + " " + diceRawTotal];
+ if (dm !== 0) breakdownParts.push(`DM ${dm >= 0 ? "+" : ""}${dm}`);
+ if (hasDifficulty) breakdownParts.push(game.i18n.localize("MGT2.Chat.Roll.Effect") + " " + effectStr);
+ if (extraTooltip) breakdownParts.push(extraTooltip);
+ const rollBreakdown = breakdownParts.join(" | ");
const chatData = {
creatureName: actor.name,
creatureImg: actor.img,
- rollLabel: skill.name.toUpperCase(),
- formula: fullFormula,
+ rollLabel,
+ formula: roll.formula,
total: roll.total,
tooltip: await roll.getTooltip(),
- difficulty: difficultyTarget,
- difficultyLabel,
- success,
- failure: !success,
+ rollBreakdown,
+ difficulty: hasDifficulty ? diffTarget : null,
+ difficultyLabel: difficultyLabel ?? MGT2Helper.getDifficultyDisplay(difficulty),
+ success: hasDifficulty ? success : null,
+ failure: hasDifficulty ? !success : null,
+ effect: hasDifficulty ? effect : null,
+ effectStr: hasDifficulty ? effectStr : null,
modifiers: dm !== 0 ? [`DM ${dm >= 0 ? "+" : ""}${dm}`] : [],
};
@@ -195,8 +137,125 @@ export default class TravellerCreatureSheet extends MGT2ActorSheet {
content: chatContent,
speaker: ChatMessage.getSpeaker({ actor }),
rolls: [roll],
- rollMode: game.settings.get("core", "rollMode"),
+ rollMode: rollMode ?? game.settings.get("core", "rollMode"),
});
+
+ return { success, effect, total: roll.total };
+ }
+
+ // ───────────────────────────────────────────────────────── Roll Handlers
+
+ /** Roll a skill check (2d6 + level vs difficulty) — uses unified dialog */
+ static async #onRollSkill(event, target) {
+ const index = parseInt(target.dataset.index ?? 0);
+ const actor = this.document;
+ const skill = actor.system.skills[index];
+ if (!skill) return;
+
+ const result = await RollPromptHelper.roll({
+ isCreature: true,
+ showSkillSelector: false,
+ skillName: skill.name,
+ skillLevel: skill.level,
+ difficulty: "Average",
+ title: game.i18n.localize("MGT2.Creature.RollSkill") + " — " + skill.name,
+ });
+ if (!result) return;
+
+ const customDM = parseInt(result.customDM ?? "0", 10) || 0;
+ const skillLevel = parseInt(skill.level ?? 0, 10) || 0;
+ const dm = skillLevel + customDM;
+ const diceModifier = result.diceModifier ?? "";
+
+ // Build formula exactly like character-sheet: parts joined without spaces
+ const parts = [];
+ if (diceModifier) {
+ parts.push("3d6", diceModifier);
+ } else {
+ parts.push("2d6");
+ }
+ if (dm !== 0) parts.push(MGT2Helper.getFormulaDM(dm));
+ const fullFormula = parts.join("");
+
+ const roll = await new Roll(fullFormula).evaluate();
+ const rollLabel = `${skill.name.toUpperCase()} (${skillLevel >= 0 ? "+" : ""}${skillLevel})`;
+
+ const tooltipParts = [`Dés: ${roll.dice.reduce((s, d) => s + d.total, 0)}`];
+ if (skillLevel !== 0) tooltipParts.push(`${skill.name} ${skillLevel >= 0 ? "+" : ""}${skillLevel}`);
+ if (customDM !== 0) tooltipParts.push(`MD perso ${customDM >= 0 ? "+" : ""}${customDM}`);
+
+ await TravellerCreatureSheet.#postCreatureRoll({
+ actor, roll, rollLabel,
+ dm,
+ difficulty: result.difficulty,
+ rollMode: result.rollMode,
+ extraTooltip: tooltipParts.join(" | "),
+ });
+ }
+
+ /** Roll an attack: dialog with skill selector, then roll 2d6+skill+DM vs difficulty; on success roll damage */
+ static async #onRollAttack(event, target) {
+ const index = parseInt(target.dataset.index ?? 0);
+ const actor = this.document;
+ const attack = actor.system.attacks[index];
+ if (!attack) return;
+
+ const skills = actor.system.skills ?? [];
+
+ const result = await RollPromptHelper.roll({
+ isCreature: true,
+ showSkillSelector: true,
+ creatureSkills: skills,
+ selectedSkillIndex: attack.skill ?? -1,
+ difficulty: "Average",
+ title: game.i18n.localize("MGT2.Creature.RollAttack") + " — " + attack.name,
+ });
+ if (!result) return;
+
+ const skillIndex = parseInt(result.creatureSkillIndex ?? "-1", 10);
+ const chosenSkill = (skillIndex >= 0 && skillIndex < skills.length) ? skills[skillIndex] : null;
+ const skillLevel = parseInt(chosenSkill?.level ?? 0, 10) || 0;
+ const customDM = parseInt(result.customDM ?? "0", 10) || 0;
+ const dm = skillLevel + customDM;
+ const diceModifier = result.diceModifier ?? "";
+
+ // Build formula exactly like character-sheet: parts joined without spaces
+ const parts = [];
+ if (diceModifier) {
+ parts.push("3d6", diceModifier);
+ } else {
+ parts.push("2d6");
+ }
+ if (dm !== 0) parts.push(MGT2Helper.getFormulaDM(dm));
+ const fullFormula = parts.join("");
+
+ const roll = await new Roll(fullFormula).evaluate();
+ const rollLabel = chosenSkill
+ ? `${attack.name} — ${chosenSkill.name} (${skillLevel >= 0 ? "+" : ""}${skillLevel})`
+ : attack.name;
+
+ const tooltipParts = [`Dés: ${roll.dice.reduce((s, d) => s + d.total, 0)}`];
+ if (chosenSkill) tooltipParts.push(`${chosenSkill.name} ${skillLevel >= 0 ? "+" : ""}${skillLevel}`);
+ if (customDM !== 0) tooltipParts.push(`MD perso ${customDM >= 0 ? "+" : ""}${customDM}`);
+
+ const { success } = await TravellerCreatureSheet.#postCreatureRoll({
+ actor, roll, rollLabel,
+ dm,
+ difficulty: result.difficulty,
+ rollMode: result.rollMode,
+ extraTooltip: tooltipParts.join(" | "),
+ });
+
+ // Roll damage only on success
+ if (success && attack.damage) {
+ const dmgFormula = normalizeDice(attack.damage);
+ const dmgRoll = await new Roll(dmgFormula).evaluate();
+ await dmgRoll.toMessage({
+ speaker: ChatMessage.getSpeaker({ actor }),
+ flavor: `${actor.name} — ${game.i18n.localize("MGT2.Chat.Weapon.Damage")}: ${attack.name} (${attack.damage})`,
+ rollMode: result.rollMode ?? game.settings.get("core", "rollMode"),
+ });
+ }
}
// ───────────────────────────────────────────────────────── CRUD Handlers
@@ -223,7 +282,7 @@ export default class TravellerCreatureSheet extends MGT2ActorSheet {
_getDefaultRow(prop) {
switch (prop) {
case "skills": return { name: "", level: 0, note: "" };
- case "attacks": return { name: "", damage: "1D", description: "" };
+ case "attacks": return { name: "", damage: "1D", skill: -1, description: "" };
case "traits": return { name: "", value: "", description: "" };
default: return {};
}
diff --git a/src/module/applications/sheets/item-sheet.mjs b/src/module/applications/sheets/item-sheet.mjs
index d80120a..95e6d20 100644
--- a/src/module/applications/sheets/item-sheet.mjs
+++ b/src/module/applications/sheets/item-sheet.mjs
@@ -73,6 +73,8 @@ export default class TravellerItemSheet extends HandlebarsApplicationMixin(found
skills.sort(MGT2Helper.compareByName);
skills = [{ _id: "NP", name: game.i18n.localize("MGT2.Items.NotProficient") }].concat(skills);
+ const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? "", { async: true });
+
return {
item: item,
document: item,
@@ -91,6 +93,10 @@ export default class TravellerItemSheet extends HandlebarsApplicationMixin(found
weight: weight,
unitlabels: { weight: MGT2Helper.getWeightLabel() },
skills: skills,
+ enrichedDescription: await enrich(item.system.description),
+ enrichedDescriptionLong: await enrich(item.system.descriptionLong),
+ enrichedNotes: await enrich(item.system.notes),
+ enrichedLockedDescription: await enrich(item.system.lockedDescription),
};
}
@@ -126,6 +132,27 @@ export default class TravellerItemSheet extends HandlebarsApplicationMixin(found
bind(".options-delete", TravellerItemSheet.#onOptionDelete);
bind(".modifiers-create", TravellerItemSheet.#onModifierCreate);
bind(".modifiers-delete", TravellerItemSheet.#onModifierDelete);
+
+ // Activate ProseMirror editors for HTMLField fields
+ for (const btn of html.querySelectorAll(".editor-edit")) {
+ btn.addEventListener("click", async (event) => {
+ event.preventDefault();
+ const editorWrapper = btn.closest(".editor");
+ if (!editorWrapper) return;
+ const editorContent = editorWrapper.querySelector(".editor-content");
+ if (!editorContent || editorContent.classList.contains("ProseMirror")) return;
+ const target = editorContent.dataset.edit;
+ const value = foundry.utils.getProperty(this.document, target) ?? "";
+ btn.remove();
+ editorWrapper.classList.add("prosemirror");
+ await ProseMirrorEditor.create(editorContent, value, {
+ document: this.document,
+ fieldName: target,
+ plugins: {},
+ collaborate: false,
+ });
+ });
+ }
}
_activateTabGroups() {
diff --git a/src/module/applications/sheets/vehicule-sheet.mjs b/src/module/applications/sheets/vehicule-sheet.mjs
index e57a6e6..9392304 100644
--- a/src/module/applications/sheets/vehicule-sheet.mjs
+++ b/src/module/applications/sheets/vehicule-sheet.mjs
@@ -21,4 +21,15 @@ export default class TravellerVehiculeSheet extends MGT2ActorSheet {
/** @override */
tabGroups = { primary: "stats" }
+
+ /** @override */
+ async _prepareContext() {
+ const context = await super._prepareContext();
+ const actor = this.document;
+ const enrich = (html) => foundry.applications.ux.TextEditor.implementation.enrichHTML(html ?? "", { async: true });
+
+ context.enrichedDescription = await enrich(actor.system.description);
+ context.enrichedNotes = await enrich(actor.system.notes);
+ return context;
+ }
}
diff --git a/src/module/chatHelper.js b/src/module/chatHelper.js
index 9dbb314..42205f9 100644
--- a/src/module/chatHelper.js
+++ b/src/module/chatHelper.js
@@ -20,11 +20,17 @@ export class ChatHelper {
element.querySelectorAll('button[data-action="healing"]').forEach(el => {
el.addEventListener('click', async event => {
- ui.notifications.warn("healing");
+ await this._applyChatCardHealing(message, event);
});
});
- element.querySelectorAll('button[data-index]').forEach(el => {
+ element.querySelectorAll('button[data-action="surgeryDamage"]').forEach(el => {
+ el.addEventListener('click', async event => {
+ await this._applyChatCardSurgeryDamage(message, event);
+ });
+ });
+
+ element.querySelectorAll('button[data-index]:not([data-action])').forEach(el => {
el.addEventListener('click', async event => {
await this._processRollButtonEvent(message, event);
});
@@ -90,10 +96,41 @@ export class ChatHelper {
}
static _applyChatCardDamage(message, event) {
+ if (canvas.tokens.controlled.length === 0) {
+ ui.notifications.warn(game.i18n.localize("MGT2.Errors.NoTokenSelected"));
+ return;
+ }
const roll = message.rolls[0];
return Promise.all(canvas.tokens.controlled.map(t => {
const a = t.actor;
return a.applyDamage(roll.total);
}));
}
+
+ static _applyChatCardHealing(message, event) {
+ if (canvas.tokens.controlled.length === 0) {
+ ui.notifications.warn(game.i18n.localize("MGT2.Errors.NoTokenSelected"));
+ return;
+ }
+ // For First Aid/Surgery healing, use amount from flags; otherwise use roll total
+ const amount = message.flags?.mgt2?.healing?.amount
+ ?? message.flags?.mgt2?.surgery?.healing
+ ?? Math.max(1, message.rolls[0].total);
+ return Promise.all(canvas.tokens.controlled.map(t => {
+ const a = t.actor;
+ return a.applyHealing(amount);
+ }));
+ }
+
+ static _applyChatCardSurgeryDamage(message, event) {
+ if (canvas.tokens.controlled.length === 0) {
+ ui.notifications.warn(game.i18n.localize("MGT2.Errors.NoTokenSelected"));
+ return;
+ }
+ const amount = message.flags?.mgt2?.surgery?.surgeryDamage ?? 3;
+ return Promise.all(canvas.tokens.controlled.map(t => {
+ const a = t.actor;
+ return a.applyDamage(amount, { ignoreArmor: true });
+ }));
+ }
}
\ No newline at end of file
diff --git a/src/module/config.js b/src/module/config.js
index adb9e4f..14e2eb7 100644
--- a/src/module/config.js
+++ b/src/module/config.js
@@ -143,7 +143,7 @@ MGT2.SpeedBands = Object.freeze({
VerySlow: "MGT2.SpeedBands.VerySlow",
Slow: "MGT2.SpeedBands.Slow",
Medium: "MGT2.SpeedBands.Medium",
- High: "MGT2.SpeedBands.High.",
+ High: "MGT2.SpeedBands.High",
Fast: "MGT2.SpeedBands.Fast",
VeryFast: "MGT2.SpeedBands.VeryFast",
Subsonic: "MGT2.SpeedBands.Subsonic",
@@ -177,4 +177,11 @@ MGT2.CreatureBehaviorSubType = Object.freeze({
necrophage: "MGT2.CreatureBehaviorSubType.necrophage",
reducteur: "MGT2.CreatureBehaviorSubType.reducteur",
opportuniste: "MGT2.CreatureBehaviorSubType.opportuniste"
+});
+
+MGT2.HealingType = Object.freeze({
+ FIRST_AID: "MGT2.Healing.FirstAid",
+ SURGERY: "MGT2.Healing.Surgery",
+ MEDICAL_CARE: "MGT2.Healing.MedicalCare",
+ NATURAL_HEALING: "MGT2.Healing.NaturalHealing"
});
\ No newline at end of file
diff --git a/src/module/models/character.mjs b/src/module/models/character.mjs
index 4ece334..dbc0c9c 100644
--- a/src/module/models/character.mjs
+++ b/src/module/models/character.mjs
@@ -47,7 +47,9 @@ export default class CharacterData extends foundry.abstract.TypeDataModel {
}),
health: new fields.SchemaField({
- radiations: new fields.NumberField({ required: false, initial: 0, min: 0, integer: true })
+ radiations: new fields.NumberField({ required: false, initial: 0, min: 0, integer: true }),
+ lastFirstAidDate: new fields.StringField({ required: false, blank: true, trim: true }),
+ healingRecoveryMode: new fields.StringField({ required: false, blank: true, trim: true, initial: "" })
}),
study: new fields.SchemaField({
skill: new fields.StringField({ required: false, blank: true, trim: true, initial: "" }),
@@ -61,7 +63,7 @@ export default class CharacterData extends foundry.abstract.TypeDataModel {
debt: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),
livingCost: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),
monthlyShipPayments: new fields.NumberField({ required: true, initial: 0, min: 0, integer: true }),
- notes: new fields.StringField({ required: false, blank: true, trim: true, initial: "" })
+ notes: new fields.HTMLField({ required: false, blank: true, trim: true })
}),
containerView: new fields.StringField({ required: false, blank: true, trim: true, initial: "" }),
containerDropIn: new fields.StringField({ required: false, blank: true, trim: true, initial: "" }),
diff --git a/src/module/models/creature.mjs b/src/module/models/creature.mjs
index 241f2ad..68e0eb9 100644
--- a/src/module/models/creature.mjs
+++ b/src/module/models/creature.mjs
@@ -29,6 +29,7 @@ export default class CreatureData extends foundry.abstract.TypeDataModel {
new fields.SchemaField({
name: new fields.StringField({ required: true, blank: true, trim: true, initial: "" }),
damage: new fields.StringField({ required: true, blank: true, trim: true, initial: "1D" }),
+ skill: new fields.NumberField({ required: false, initial: -1, integer: true }),
description: new fields.StringField({ required: false, blank: true, trim: true, initial: "" })
})
),
diff --git a/src/module/models/items/base-item.mjs b/src/module/models/items/base-item.mjs
index eb21a6c..356639d 100644
--- a/src/module/models/items/base-item.mjs
+++ b/src/module/models/items/base-item.mjs
@@ -13,7 +13,7 @@ export function createCharacteristicField(show = true, showMax = false) {
export class ItemBaseData extends foundry.abstract.TypeDataModel {
static defineSchema() {
return {
- description: new fields.StringField({ required: false, blank: true, trim: true, nullable: true }),
+ description: new fields.HTMLField({ required: false, blank: true, trim: true }),
subType: new fields.StringField({ required: false, blank: false, nullable: true })
};
}
diff --git a/src/module/models/items/container.mjs b/src/module/models/items/container.mjs
index e72368e..efe410c 100644
--- a/src/module/models/items/container.mjs
+++ b/src/module/models/items/container.mjs
@@ -10,7 +10,7 @@ export default class ItemContainerData extends ItemBaseData {
schema.weight = new fields.NumberField({ required: false, initial: 0, integer: false });
schema.weightless = new fields.BooleanField({ required: false, initial: false });
schema.locked = new fields.BooleanField({ required: false, initial: false }); // GM only
- schema.lockedDescription = new fields.StringField({ required: false, blank: true, trim: true, nullable: true });
+ schema.lockedDescription = new fields.HTMLField({ required: false, blank: true, trim: true });
return schema;
}
}
diff --git a/src/module/models/items/species.mjs b/src/module/models/items/species.mjs
index 3d4fb6e..838de31 100644
--- a/src/module/models/items/species.mjs
+++ b/src/module/models/items/species.mjs
@@ -3,7 +3,7 @@ const fields = foundry.data.fields;
export default class SpeciesData extends foundry.abstract.TypeDataModel {
static defineSchema() {
return {
- description: new fields.StringField({ required: false, blank: true, trim: true, nullable: true }),
+ description: new fields.HTMLField({ required: false, blank: true, trim: true }),
descriptionLong: new fields.HTMLField({ required: false, blank: true, trim: true }),
traits: new fields.ArrayField(
new fields.SchemaField({
diff --git a/src/module/models/vehicule.mjs b/src/module/models/vehicule.mjs
index ac4e8b5..7e321cc 100644
--- a/src/module/models/vehicule.mjs
+++ b/src/module/models/vehicule.mjs
@@ -27,7 +27,9 @@ export default class VehiculeData extends foundry.abstract.TypeDataModel {
}),
skills: new fields.SchemaField({
autopilot: new fields.NumberField({ required: true, initial: 0, integer: true })
- })
+ }),
+ description: new fields.HTMLField({ required: false, blank: true, trim: true }),
+ notes: new fields.HTMLField({ required: false, blank: true, trim: true })
};
}
}
diff --git a/src/module/roll-prompt.js b/src/module/roll-prompt.js
index c1dd471..f62054c 100644
--- a/src/module/roll-prompt.js
+++ b/src/module/roll-prompt.js
@@ -5,19 +5,39 @@ const { FormDataExtended } = foundry.applications.ux;
export class RollPromptHelper {
static async roll(options) {
+ // Backward compat: allow (actor, options) or just (options)
+ if (options.rollTypeName || options.characteristics || options.skill !== undefined) {
+ // Normal call with options
+ } else {
+ // Called with (actor, options)
+ options = arguments[1] || options;
+ }
+
const htmlContent = await renderTemplate('systems/mgt2/templates/roll-prompt.html', {
config: CONFIG.MGT2,
- characteristics: options.characteristics,
- characteristic: options.characteristic,
- skills: options.skills,
- skill: options.skill,
- fatigue: options.fatigue,
- encumbrance: options.encumbrance,
- difficulty: options.difficulty
+ // Character-mode fields
+ characteristics: options.characteristics ?? [],
+ characteristic: options.characteristic ?? "",
+ skills: options.skills ?? [],
+ skill: options.skill ?? "",
+ fatigue: options.fatigue ?? false,
+ encumbrance: options.encumbrance ?? false,
+ difficulty: options.difficulty ?? "Average",
+ timeframe: options.timeframe ?? "Normal",
+ customDM: options.customDM ?? "0",
+ rollMode: options.rollMode ?? "publicroll",
+ // Creature-mode flags
+ isCreature: options.isCreature ?? false,
+ creatureSkills: options.creatureSkills ?? [],
+ selectedSkillIndex: options.selectedSkillIndex ?? -1,
+ showSkillSelector: options.showSkillSelector ?? false,
+ skillName: options.skillName ?? "",
+ skillLevel: options.skillLevel ?? 0,
+ // Healing fields
+ showHeal: options.showHeal ?? false,
+ healType: options.healType ?? null
});
- const theme = game.settings.get("mgt2", "theme");
-
return await DialogV2.wait({
window: { title: options.title ?? options.rollTypeName ?? game.i18n.localize("MGT2.RollPrompt.Roll") },
classes: ["mgt2-roll-dialog"],
@@ -54,4 +74,4 @@ export class RollPromptHelper {
]
});
}
-}
\ No newline at end of file
+}
diff --git a/src/module/templates.js b/src/module/templates.js
index e994b2b..8cd137d 100644
--- a/src/module/templates.js
+++ b/src/module/templates.js
@@ -19,6 +19,7 @@ export const preloadHandlebarsTemplates = async function() {
"systems/mgt2/templates/items/weapon-sheet.html",
"systems/mgt2/templates/items/parts/sheet-configuration.html",
"systems/mgt2/templates/items/parts/sheet-physical-item.html",
+ "systems/mgt2/templates/items/parts/sheet-physical-item-tab.html",
"systems/mgt2/templates/roll-prompt.html",
"systems/mgt2/templates/chat/roll.html",
//"systems/mgt2/templates/chat/roll-characteristic.html",
@@ -26,10 +27,10 @@ export const preloadHandlebarsTemplates = async function() {
"systems/mgt2/templates/actors/actor-config-characteristic-sheet.html",
"systems/mgt2/templates/actors/trait-sheet.html",
"systems/mgt2/templates/actors/creature-sheet.html",
- "systems/mgt2/templates/actors/creature-roll-prompt.html",
"systems/mgt2/templates/chat/creature-roll.html",
"systems/mgt2/templates/editor-fullview.html"
];
- return loadTemplates(templatePaths);
+ const loader = foundry.applications?.handlebars?.loadTemplates ?? loadTemplates;
+ return loader(templatePaths);
};
\ No newline at end of file
diff --git a/src/sass/components/_character.sass b/src/sass/components/_character.sass
index 8b938d0..51db9ca 100644
--- a/src/sass/components/_character.sass
+++ b/src/sass/components/_character.sass
@@ -213,6 +213,7 @@ ul
flex-direction: row
align-content: flex-start
flex-wrap: nowrap
+ min-height: 330px
.tab
width: 100%
@@ -277,3 +278,15 @@ ul
flex-shrink: 0
display: flex
flex-direction: row
+
+
+// ── HTMLField editor min-height in notes/biography/finance tabs ──────────────
+.mgt2.character
+ .tab[data-tab="notes"],
+ .tab[data-tab="biography"],
+ .tab[data-tab="finance"]
+ .editor,
+ .editor-content,
+ prose-mirror
+ min-height: 300px !important
+ height: auto !important
diff --git a/src/sass/components/_chat-sidebar.sass b/src/sass/components/_chat-sidebar.sass
index eb26f0d..fc20451 100644
--- a/src/sass/components/_chat-sidebar.sass
+++ b/src/sass/components/_chat-sidebar.sass
@@ -294,6 +294,41 @@ li.chat-message
color: #EE4050
border-top: 1px solid rgba(238,64,80,0.2)
+ // ── Effect line ──
+ .mgt2-effect
+ text-align: center
+ font-size: 0.72rem
+ font-weight: 600
+ letter-spacing: 1.5px
+ text-transform: uppercase
+ padding: 2px 10px 4px 10px
+ border-bottom: 2px solid transparent
+
+ .mgt2-effect-value
+ font-size: 1rem
+ font-weight: 900
+ margin-left: 4px
+
+ .mgt2-healing-amount
+ font-size: 0.75rem
+ font-weight: 600
+ margin-left: 6px
+ opacity: 0.85
+
+ &.is-success
+ color: #1a8840
+ border-bottom-color: rgba(26,136,64,0.25)
+
+ .mgt2-effect-value
+ color: #1a8840
+
+ &.is-failure
+ color: #EE4050
+ border-bottom-color: rgba(238,64,80,0.25)
+
+ .mgt2-effect-value
+ color: #EE4050
+
// ── Action buttons ──
.mgt2-buttons
display: flex
diff --git a/src/sass/components/_creature.sass b/src/sass/components/_creature.sass
index c67c846..9c0890e 100644
--- a/src/sass/components/_creature.sass
+++ b/src/sass/components/_creature.sass
@@ -105,15 +105,19 @@
flex-direction: row
align-items: center
gap: 0.5rem
- flex-wrap: wrap
+ flex-wrap: nowrap
label
+ flex: 0 0 auto
font-size: 0.75rem
text-transform: uppercase
color: var(--mgt2-color-primary)
font-weight: 700
+ white-space: nowrap
.behavior-select
+ flex: 1 1 auto
+ min-width: 0
background: var(--mgt2-bgcolor-form)
color: var(--mgt2-color-form)
border: 1px solid var(--mgt2-color-primary)
@@ -122,24 +126,29 @@
padding: 1px 4px
.behavior-sep
+ flex: 0 0 auto
color: var(--mgt2-color-form)
opacity: 0.5
.creature-size-badge
- margin-left: auto
+ flex: 0 0 auto
+ white-space: nowrap
font-size: 0.75rem
font-style: italic
- color: var(--mgt2-color-secondary)
+ color: var(--mgt2-bgcolor-form)
background: var(--mgt2-bgcolor-primary)
- border: 1px solid var(--mgt2-color-secondary)
+ border: 1px solid var(--mgt2-color-primary)
border-radius: 3px
padding: 1px 6px
// ── Body / Tabs ────────────────────────────────────
+ // min-height ensures all 4 sidebar tabs are always visible
+ // (4 tabs × 54px each + 8px padding = 224px)
.creature-body
flex: 1
overflow-y: auto
padding: 0.5rem 0.75rem
+ min-height: 228px
.tab
display: none
@@ -199,3 +208,18 @@
.mgt2-roll-header-text
flex: 1
+
+ // ── Section headers: use shared .header class (same as character sheet) ──────
+
+// ── HTMLField editor min-height in info tab ──────────────────────────────────
+.mgt2.creature
+ // Section headers (skills/attacks/traits) — margin between successive sections
+ .table-container + .header
+ margin-top: 8px
+
+ .tab[data-tab="info"]
+ .editor,
+ .editor-content,
+ prose-mirror
+ min-height: 300px !important
+ height: auto !important
diff --git a/src/sass/components/_dialog.sass b/src/sass/components/_dialog.sass
index d910bcb..874fc71 100644
--- a/src/sass/components/_dialog.sass
+++ b/src/sass/components/_dialog.sass
@@ -31,15 +31,15 @@
.dialog-content, .standard-form
background: #ffffff !important
- padding: 14px 18px 10px !important
+ padding: 8px 14px 6px !important
// Form group rows
.form-group
display: flex !important
align-items: center !important
- gap: 10px !important
- margin-bottom: 8px !important
- padding: 4px 0 !important
+ gap: 8px !important
+ margin-bottom: 3px !important
+ padding: 2px 0 !important
border-bottom: 1px solid #e8e0e0 !important
&:last-child
@@ -61,7 +61,7 @@
border: 1px solid #ccbbbb !important
color: #0A0405 !important
border-radius: 3px !important
- padding: 5px 10px !important
+ padding: 3px 8px !important
font-family: 'Barlow Condensed', sans-serif !important
font-size: 0.9rem !important
transition: border-color 150ms ease !important
@@ -80,8 +80,8 @@
background: #fdf8f8 !important
border: 1px solid #e0c8c8 !important
border-radius: 5px !important
- padding: 10px 14px !important
- margin-bottom: 8px !important
+ padding: 5px 10px !important
+ margin-bottom: 4px !important
legend
color: #EE4050 !important
@@ -112,7 +112,7 @@
.dialog-buttons, .form-footer, footer
background: #f5eeee !important
border-top: 2px solid #EE4050 !important
- padding: 10px 14px !important
+ padding: 7px 14px !important
display: flex !important
gap: 8px !important
justify-content: center !important
@@ -124,7 +124,7 @@
border: 1px solid #ccbbbb !important
color: #3a2020 !important
border-radius: 4px !important
- padding: 7px 14px !important
+ padding: 5px 12px !important
font-family: 'Barlow Condensed', sans-serif !important
font-size: 0.82rem !important
font-weight: 700 !important
diff --git a/src/sass/components/_item.sass b/src/sass/components/_item.sass
index f61d34b..d23e43f 100644
--- a/src/sass/components/_item.sass
+++ b/src/sass/components/_item.sass
@@ -343,3 +343,76 @@
.itemsheet-panel
display: contents !important
+
+// ── Details tab: 2-column grid layout ────────────────────────────────────────
+.itemsheet
+ .item-details-grid
+ display: grid !important
+ grid-template-columns: 1fr 1fr !important
+ gap: 4px 16px !important
+ align-items: start !important
+
+ // Traits table spans full width
+ .table-container
+ grid-column: 1 / -1 !important
+ margin-top: 10px !important
+
+// ── Field row: label + input on the same line ─────────────────────────────────
+.itemsheet
+ .field-row
+ display: flex !important
+ align-items: center !important
+ gap: 8px !important
+ min-height: 28px !important
+
+ label
+ flex: 0 0 100px !important
+ min-width: 0 !important
+ margin-bottom: 0 !important
+ white-space: nowrap !important
+ overflow: hidden !important
+ text-overflow: ellipsis !important
+
+ input[type="text"],
+ input[type="number"],
+ select
+ flex: 1 !important
+ width: auto !important
+ height: 24px !important
+ padding: 2px 6px !important
+
+ input.short
+ flex: 0 0 56px !important
+ width: 56px !important
+
+ .range-inputs
+ display: flex !important
+ gap: 4px !important
+ flex: 1 !important
+
+ input
+ flex: 0 0 52px !important
+ width: 52px !important
+
+ select
+ flex: 1 !important
+
+ // Full-width row (e.g. storage)
+ &.full
+ grid-column: 1 / -1 !important
+
+ // Checkbox row variant
+ .field-row--check
+ label
+ flex: unset !important
+ display: flex !important
+ align-items: center !important
+ gap: 6px !important
+ cursor: pointer !important
+
+// ── Description tab: editor min-height ───────────────────────────────────────
+.itemsheet
+ .tab[data-tab="tab1"]
+ .editor,
+ .editor-container
+ min-height: 200px !important
diff --git a/src/sass/components/_tab-sidebar.sass b/src/sass/components/_tab-sidebar.sass
index 8bd56e2..c562c36 100644
--- a/src/sass/components/_tab-sidebar.sass
+++ b/src/sass/components/_tab-sidebar.sass
@@ -3,7 +3,7 @@
// nav (left: 100% of character-body) can extend to the right of the window border.
// Layered !important beats Foundry's unlayered overflow:hidden per CSS cascade spec.
-.mgt2.character, .mgt2.creature
+.mgt2.character, .mgt2.creature, .mgt2.vehicule
overflow: visible !important
> .window-content
overflow: visible !important
@@ -18,13 +18,16 @@
position: relative !important
overflow: visible !important
+.mgt2.vehicule .vehicule-content
+ position: relative !important
+ overflow: visible !important
+
// ── Vertical sidebar tab navigation (outside window, right side) ──
.mgt2
nav.sheet-sidebar.tabs
position: absolute !important
left: 100% !important
top: 0 !important
- bottom: 0 !important
width: 62px !important
flex: none !important
display: flex !important
diff --git a/src/sass/components/_vehicule.sass b/src/sass/components/_vehicule.sass
new file mode 100644
index 0000000..693dcd5
--- /dev/null
+++ b/src/sass/components/_vehicule.sass
@@ -0,0 +1,203 @@
+// ─────────────────────────────────────────────────
+// Vehicule Sheet Styles
+// ─────────────────────────────────────────────────
+
+.vehicule-sheet
+
+ // ── Header ────────────────────────────────────────
+ .vehicule-header
+ display: flex
+ flex-direction: row
+ align-items: flex-start
+ gap: 0.75rem
+ padding: 0.5rem 0.75rem
+ background: var(--mgt2-bgcolor-form)
+ border-bottom: 2px solid var(--mgt2-color-primary)
+ flex-shrink: 0
+
+ .vehicule-header-img
+ flex: 0 0 90px
+ img.profile
+ width: 90px
+ height: 90px
+ object-fit: cover
+ border: 2px solid var(--mgt2-color-primary)
+ border-radius: 4px
+ cursor: pointer
+
+ .vehicule-header-body
+ flex: 1
+ display: flex
+ flex-direction: column
+ gap: 0.4rem
+ min-width: 0
+
+ .vehicule-name
+ font-family: "Barlow Condensed", sans-serif
+ font-size: 1.6rem
+ font-weight: 700
+ font-style: italic
+ color: var(--mgt2-color-form)
+ background: transparent
+ border: none
+ border-bottom: 1px solid var(--mgt2-color-primary)
+ width: 100%
+ padding: 0
+ &:focus
+ outline: none
+ border-bottom-color: var(--mgt2-color-secondary)
+
+ .vehicule-header-stats
+ display: flex
+ flex-direction: row
+ align-items: flex-start
+ gap: 0.75rem
+ flex-wrap: wrap
+
+ // ── Stat boxes (hull, armor) ────────────────────────
+ .vehicule-stat-box
+ display: flex
+ flex-direction: column
+ align-items: center
+ background: var(--mgt2-bgcolor-primary)
+ border: 1px solid var(--mgt2-color-primary)
+ border-radius: 4px
+ padding: 3px 8px
+ min-width: 4rem
+
+ label
+ font-family: "Barlow Condensed", sans-serif
+ font-size: 0.65rem
+ font-weight: 700
+ text-transform: uppercase
+ color: var(--mgt2-color-primary)
+ line-height: 1.2
+ white-space: nowrap
+
+ .vehicule-stat-value
+ display: flex
+ align-items: center
+ gap: 2px
+
+ span
+ color: var(--mgt2-color-primary)
+ font-weight: 700
+
+ input[type="number"]
+ width: 2.8rem
+ text-align: center
+ background: transparent
+ border: none
+ color: var(--mgt2-color-form)
+ font-family: "Rubik", monospace
+ font-size: 1rem
+ font-weight: 600
+ padding: 0
+ &:focus
+ outline: none
+ border-bottom: 1px solid var(--mgt2-color-secondary)
+
+ .vehicule-hull
+ min-width: 6rem
+ .vehicule-stat-value input[type="number"]
+ width: 2.5rem
+
+ // ── Armor group ────────────────────────────────────
+ .vehicule-armor-group
+ display: flex
+ flex-direction: column
+ gap: 2px
+
+ .vehicule-armor-label
+ font-family: "Barlow Condensed", sans-serif
+ font-size: 0.65rem
+ font-weight: 700
+ text-transform: uppercase
+ color: var(--mgt2-color-primary)
+ text-align: center
+
+ .vehicule-armor-row
+ display: flex
+ flex-direction: row
+ gap: 4px
+
+ .vehicule-armor-box
+ min-width: 3.5rem
+
+ // ── Body wrapper (contains tabs + sidebar nav) ─────
+ // min-height ensures both tabs in the sidebar are always visible
+ // (2 tabs × 54px each + 8px padding = 116px)
+ .vehicule-content
+ flex: 1
+ display: flex
+ flex-direction: column
+ overflow: hidden
+ min-height: 320px
+
+ // ── Tab panels ─────────────────────────────────────
+ .vehicule-tab
+ flex: 1
+ overflow-y: auto
+ padding: 0.75rem
+ display: none
+
+ &.active
+ display: block
+
+ // ── Stats grid ─────────────────────────────────────
+ .vehicule-stats-grid
+ display: grid
+ grid-template-columns: 1fr 1fr
+ gap: 4px 12px
+
+ .vehicule-field
+ display: flex
+ flex-direction: row
+ align-items: center
+ gap: 8px
+ padding: 3px 0
+ border-bottom: 1px solid rgba(0,0,0,0.08)
+
+ &:last-child
+ border-bottom: none
+
+ label
+ font-family: "Barlow Condensed", sans-serif
+ font-size: 0.72rem
+ font-weight: 700
+ text-transform: uppercase
+ color: var(--mgt2-color-primary)
+ flex: 0 0 120px
+ white-space: nowrap
+
+ input[type="number"],
+ select
+ flex: 1
+ background: transparent
+ border: 1px solid transparent
+ border-radius: 3px
+ color: var(--mgt2-color-form)
+ font-family: "Barlow Condensed", sans-serif
+ font-size: 0.9rem
+ padding: 2px 4px
+ &:focus
+ outline: none
+ border-color: var(--mgt2-color-primary)
+ background: rgba(255,255,255,0.1)
+
+ input[type="number"]
+ text-align: center
+ width: 4rem
+
+ select
+ cursor: pointer
+
+
+// ── HTMLField editor min-height in description tab ──────────────────────────
+.mgt2.vehicule
+ .vehicule-tab[data-tab="description"]
+ .editor,
+ .editor-content,
+ prose-mirror
+ min-height: 300px !important
+ height: auto !important
diff --git a/src/sass/mgt2.sass b/src/sass/mgt2.sass
index b865123..ccedc25 100644
--- a/src/sass/mgt2.sass
+++ b/src/sass/mgt2.sass
@@ -13,4 +13,5 @@
@import 'components/_tabs'
@import 'components/_tab-sidebar'
@import 'components/_tables'
-@import 'components/_creature'
\ No newline at end of file
+@import 'components/_creature'
+@import 'components/_vehicule'
\ No newline at end of file
diff --git a/styles/mgt2.min.css b/styles/mgt2.min.css
index 96d7018..d0e1a82 100644
--- a/styles/mgt2.min.css
+++ b/styles/mgt2.min.css
@@ -1 +1 @@
-@import"https://fonts.googleapis.com/css2?family=Barlow+Condensed:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap";@import"https://fonts.googleapis.com/css2?family=Rubik:ital,wght@0,300..900;1,300..900&display=swap";@import"https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&display=swap";.black-and-red{--mgt2-color-form: #0A0405;--mgt2-bgcolor-form: #fff;--mgt2-color-primary: #EE4050;--mgt2-color-primary-active: #AF2F3C;--mgt2-bgcolor-primary: #0A0405;--mgt2-color-primary-light: #4b4a44;--mgt2-color-warning: #EE4050;--mgt2-color-dm: #fff;--mgt2-bgcolor-dm: #0A0405;--mgt2-color-software: #fff;--mgt2-bgcolor-software: #0A0405;--mgt2-input-color: #0A0405;--mgt2-input-bgcolor: #fff;--mgt2-editor-border: #C6C6C6;--mgt2-row-hover: #F2F2F2;--mgt2-subrow-color: #727272;--mgt2-row-inactive-icon: #b5b3a4;--mgt2-encumbrance-normal: #D94826;--mgt2-encumbrance-heavy: #D82727}.mwamba{--mgt2-color-form: #0A0405;--mgt2-bgcolor-form: #fff;--mgt2-color-primary: #2A9932;--mgt2-color-primary-active: #40ED4E;--mgt2-bgcolor-primary: #0A0405;--mgt2-color-primary-light: #4b4a44;--mgt2-color-warning: #EE4050;--mgt2-color-dm: #fff;--mgt2-bgcolor-dm: #0A0405;--mgt2-color-software: #fff;--mgt2-bgcolor-software: #0A0405;--mgt2-input-color: #0A0405;--mgt2-input-bgcolor: #fff;--mgt2-editor-border: #C6C6C6;--mgt2-row-hover: #F2F2F2;--mgt2-subrow-color: #727272;--mgt2-row-inactive-icon: #b5b3a4}.blue{--mgt2-color-form: #0A0405;--mgt2-bgcolor-form: #fff;--mgt2-color-primary: #91AAC8;--mgt2-color-primary-active: #BCDCFF;--mgt2-bgcolor-primary: #0A0405;--mgt2-color-primary-light: #4b4a44;--mgt2-color-warning: #EE4050;--mgt2-color-dm: #fff;--mgt2-bgcolor-dm: #0A0405;--mgt2-color-software: #fff;--mgt2-bgcolor-software: #0A0405;--mgt2-input-color: #0A0405;--mgt2-input-bgcolor: #fff;--mgt2-editor-border: #C6C6C6;--mgt2-row-hover: #F2F2F2;--mgt2-subrow-color: #727272;--mgt2-row-inactive-icon: #b5b3a4}.upcase{text-transform:uppercase}.w1-10{width:10%}.w2-10{width:20%}.w3-10{width:30%}.w4-10{width:40%}.w5-10{width:50%}.h100{height:100%}.w100{width:100%}.mgt2 a:hover{text-shadow:none}.mgt2 .w-100{width:100%}.mgt2 .mb-1{margin-bottom:8px}.mgt2 .mt-1,.mgt2 .mt-05{margin-top:8px}.mgt2 .mt-2{margin-top:14px}.mgt2.sheet header.window-header{color:var(--mgt2-color-primary);background-color:var(--mgt2-bgcolor-primary)}.mgt2.sheet h4.window-title{font-weight:bold;text-transform:uppercase}.mgt2.sheet .window-content{background:var(--mgt2-bgcolor-form);color:var(--mgt2-color-form);padding:0}.nopad .window-content{padding:0}.mgt2 .flex-fix{flex-grow:0 !important;flex-shrink:0 !important}.mgt2 .flex-basis-10{flex-basis:10%}.mgt2 .flex-basis-20{flex-basis:20%}.mgt2 .flex-basis-30{flex-basis:30%}.mgt2 .flex-basis-40{flex-basis:40%}.mgt2 .flex-basis-50{flex-basis:50%}.mgt2 .flex-basis-60{flex-basis:60%}.mgt2 .flex-basis-70{flex-basis:70%}.mgt2.sheet textarea{color:var(--mgt2-input-color);background-color:var(--mgt2-input-bgcolor);font-family:"Roboto",sans-serif;font-size:13px;font-stretch:100%}.mgt2 input:focus,.mgt2 textarea:focus,.mgt2 select:focus{outline:none;box-shadow:none}.mgt2 .checkbox-small{flex:none !important;width:auto !important;height:auto !important;margin:0 !important}.mgt2 .header{color:var(--mgt2-color-primary);background:var(--mgt2-bgcolor-primary);font-size:14px;font-family:"Roboto Condensed",sans-serif;font-weight:bold;padding-left:5px;margin-bottom:4px;line-height:30px;text-transform:uppercase}.mgt2 .field-groups{display:flex;flex-direction:row;flex-wrap:nowrap;align-items:center;justify-content:space-between}.mgt2 .field-group label{text-transform:uppercase;font-weight:700;font-size:14px;font-family:"Roboto Condensed",sans-serif;font-optical-sizing:auto}.mgt2 input.field{background-color:var(--mgt2-input-bgcolor);font-size:13px}.mgt2 input.field-name{background-color:var(--mgt2-input-bgcolor);color:var(--mgt2-color-primary);font-size:2rem;border:none;font-weight:700;font-family:"Roboto Condensed",sans-serif;margin-bottom:.5rem;padding:0}.mgt2 input.field-item-name{background-color:var(--mgt2-input-bgcolor);color:var(--mgt2-color-primary);height:auto;font-size:2rem;font-weight:700;font-family:"Roboto Condensed",sans-serif}.mgt2 .fields{display:flex}.mgt2 .editor{min-height:3rem;border:1px solid var(--mgt2-editor-border);height:100%}.mgt2 .sheet-body{margin-left:140px;padding-bottom:1.5rem}.mgt2 label.mgt2-checkbox{display:flex;flex-direction:row;align-items:center}.mgt2 label.mgt2-checkbox input{margin:0 .3rem 0 0}.mgt2 .dialog-button{color:var(--mgt2-color-primary);background-color:var(--mgt2-bgcolor-primary) !important}.mgt2-roll-dialog{background:#fff !important;border:1px solid #cbb !important;box-shadow:0 8px 32px rgba(0,0,0,.35) !important;border-radius:6px !important;overflow:hidden !important}.mgt2-roll-dialog .window-header{background:#0a0405 !important;border-bottom:3px solid #ee4050 !important;padding:10px 14px !important;position:relative !important}.mgt2-roll-dialog .window-header .window-title{color:#fff !important;font-family:"Barlow Condensed",sans-serif !important;font-weight:700 !important;font-size:1rem !important;text-transform:uppercase !important;letter-spacing:2px !important}.mgt2-roll-dialog .window-content{background:#fff !important;color:#0a0405 !important;padding:0 !important}.mgt2-roll-dialog .window-content .dialog-content,.mgt2-roll-dialog .window-content .standard-form{background:#fff !important;padding:14px 18px 10px !important}.mgt2-roll-dialog .window-content .form-group{display:flex !important;align-items:center !important;gap:10px !important;margin-bottom:8px !important;padding:4px 0 !important;border-bottom:1px solid #e8e0e0 !important}.mgt2-roll-dialog .window-content .form-group:last-child{border-bottom:none !important}.mgt2-roll-dialog .window-content .form-group label{color:#0a0405 !important;font-family:"Barlow Condensed",sans-serif !important;font-weight:700 !important;font-size:.72rem !important;text-transform:uppercase !important;letter-spacing:1.2px !important;flex:0 0 110px !important;line-height:1.2 !important}.mgt2-roll-dialog .window-content .form-group select,.mgt2-roll-dialog .window-content .form-group input[type=number],.mgt2-roll-dialog .window-content .form-group input[type=text]{flex:1 !important;background:#fff !important;border:1px solid #cbb !important;color:#0a0405 !important;border-radius:3px !important;padding:5px 10px !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.9rem !important;transition:border-color 150ms ease !important}.mgt2-roll-dialog .window-content .form-group select:focus,.mgt2-roll-dialog .window-content .form-group input[type=number]:focus,.mgt2-roll-dialog .window-content .form-group input[type=text]:focus{border-color:#ee4050 !important;outline:none !important;background:rgba(238,64,80,.04) !important}.mgt2-roll-dialog .window-content .form-group select option,.mgt2-roll-dialog .window-content .form-group input[type=number] option,.mgt2-roll-dialog .window-content .form-group input[type=text] option{background:#fff !important;color:#0a0405 !important}.mgt2-roll-dialog .window-content fieldset,.mgt2-roll-dialog .window-content .form-fields{background:#fdf8f8 !important;border:1px solid #e0c8c8 !important;border-radius:5px !important;padding:10px 14px !important;margin-bottom:8px !important}.mgt2-roll-dialog .window-content fieldset legend,.mgt2-roll-dialog .window-content .form-fields legend{color:#ee4050 !important;font-family:"Barlow Condensed",sans-serif !important;font-weight:700 !important;font-size:.72rem !important;text-transform:uppercase !important;letter-spacing:2px !important;padding:0 8px !important;background:#fff !important}.mgt2-roll-dialog .window-content fieldset .form-group,.mgt2-roll-dialog .window-content .form-fields .form-group{border-bottom:none !important;margin-bottom:4px !important;padding:2px 0 !important}.mgt2-roll-dialog .window-content fieldset label,.mgt2-roll-dialog .window-content .form-fields label{color:#3a2020 !important;flex:1 !important}.mgt2-roll-dialog .window-content fieldset input[type=checkbox],.mgt2-roll-dialog .window-content .form-fields input[type=checkbox]{accent-color:#ee4050 !important;width:14px !important;height:14px !important}.mgt2-roll-dialog .dialog-buttons,.mgt2-roll-dialog .form-footer,.mgt2-roll-dialog footer{background:#f5eeee !important;border-top:2px solid #ee4050 !important;padding:10px 14px !important;display:flex !important;gap:8px !important;justify-content:center !important}.mgt2-roll-dialog .dialog-buttons button,.mgt2-roll-dialog .form-footer button,.mgt2-roll-dialog footer button{flex:1 !important;max-width:140px !important;background:#fff !important;border:1px solid #cbb !important;color:#3a2020 !important;border-radius:4px !important;padding:7px 14px !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.82rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1.5px !important;cursor:pointer !important;transition:all 150ms ease !important}.mgt2-roll-dialog .dialog-buttons button:hover,.mgt2-roll-dialog .form-footer button:hover,.mgt2-roll-dialog footer button:hover{background:#fdf0f0 !important;border-color:#ee4050 !important;color:#ee4050 !important}.mgt2-roll-dialog .dialog-buttons button.default,.mgt2-roll-dialog .dialog-buttons button[data-action=submit],.mgt2-roll-dialog .dialog-buttons button[autofocus],.mgt2-roll-dialog .form-footer button.default,.mgt2-roll-dialog .form-footer button[data-action=submit],.mgt2-roll-dialog .form-footer button[autofocus],.mgt2-roll-dialog footer button.default,.mgt2-roll-dialog footer button[data-action=submit],.mgt2-roll-dialog footer button[autofocus]{background:#ee4050 !important;border-color:#ee4050 !important;color:#fff !important;box-shadow:0 2px 12px rgba(238,64,80,.3) !important}.mgt2-roll-dialog .dialog-buttons button.default:hover,.mgt2-roll-dialog .dialog-buttons button[data-action=submit]:hover,.mgt2-roll-dialog .dialog-buttons button[autofocus]:hover,.mgt2-roll-dialog .form-footer button.default:hover,.mgt2-roll-dialog .form-footer button[data-action=submit]:hover,.mgt2-roll-dialog .form-footer button[autofocus]:hover,.mgt2-roll-dialog footer button.default:hover,.mgt2-roll-dialog footer button[data-action=submit]:hover,.mgt2-roll-dialog footer button[autofocus]:hover{background:#ff5060 !important;box-shadow:0 4px 18px rgba(238,64,80,.45) !important}.characteristics-panel .tab{padding:4px}.species{font-size:13px;margin:4px 1rem 0 1rem;text-align:justify}.species a{margin-right:1rem}.mgt2 .characteristics{flex-basis:138px;flex-grow:0;flex-shrink:0;position:relative}.mgt2 .characteristics-header{color:var(--mgt2-color-primary);background:var(--mgt2-bgcolor-primary);font-family:"Rubik",monospace;font-style:normal;font-size:1rem;line-height:2rem;text-transform:uppercase}.mgt2 .characteristic-row{display:flex;flex-direction:row;align-items:center;justify-content:center;position:relative}.mgt2 .characteristic-minmax{display:flex;flex-direction:row;align-items:center;justify-content:center;flex-wrap:nowrap}.mgt2 .characteristic-dm span.label{font-size:.8rem;font-weight:600}.mgt2 .characteristic-label{font-family:"Barlow Condensed",sans-serif;font-size:1.2rem;font-weight:600;font-style:italic;text-align:center;color:var(--mgt2-color-form);position:relative}.mgt2 .characteristic-label>a.roll{color:#000;position:absolute;left:0}.mgt2 .characteristic-label a.cfg-characteristic{display:none;font-size:12px;position:absolute;right:0;top:0}.mgt2 .characteristic-label:hover a.cfg-characteristic{display:block}.mgt2 .characteristic-input{color:var(--mgt2-bgcolor-primary);text-align:center;font-size:1.5rem;font-weight:500;width:2.4rem;height:2rem;box-sizing:border-box;border:none;outline:none;background:linear-gradient(45deg, rgba(0, 0, 0, 0) 5.66px, #000 0 7.66px, rgba(0, 0, 0, 0) 0 calc(100% - 5.66px - 2px), #000 0 calc(100% - 5.66px), rgba(0, 0, 0, 0) 0),linear-gradient(-45deg, rgba(0, 0, 0, 0) 5.66px, #000 0 7.66px, rgba(0, 0, 0, 0) 0 calc(100% - 5.66px - 2px), #000 0 calc(100% - 5.66px), rgba(0, 0, 0, 0) 0),linear-gradient(90deg, #000 4px, rgba(0, 0, 0, 0) 0) -2px 50%/100% calc(100% - 16px) repeat-x,linear-gradient(#000 4px, rgba(0, 0, 0, 0) 0) 50% -2px/calc(100% - 16px) 100% repeat-y}.mgt2 .characteristic-dm{color:var(--mgt2-color-dm);background-color:rgba(0,0,0,0);text-align:center;font-size:1rem;width:1.5rem;height:1.4rem;padding:0;outline:none;border:none;margin:0;position:absolute;right:0;background-color:var(--mgt2-bgcolor-dm);border-radius:9px;margin-right:2px}.mgt2 .characteristic-dm:focus{outline:none;box-shadow:none}.mgt2 .characteristic-dm-minmax:focus{outline:none;box-shadow:none}.mgt2 .minmaxwrapper{display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:center;justify-content:center;align-items:center;margin:0 .5rem;box-sizing:border-box;background:linear-gradient(45deg, rgba(0, 0, 0, 0) 7.07px, #000 0 9.07px, rgba(0, 0, 0, 0) 0 calc(100% - 7.07px - 2px), #000 0 calc(100% - 7.07px), rgba(0, 0, 0, 0) 0),linear-gradient(-45deg, rgba(0, 0, 0, 0) 7.07px, #000 0 9.07px, rgba(0, 0, 0, 0) 0 calc(100% - 7.07px - 2px), #000 0 calc(100% - 7.07px), rgba(0, 0, 0, 0) 0),linear-gradient(90deg, #000 4px, rgba(0, 0, 0, 0) 0) -2px 50%/100% calc(100% - 20px) repeat-x,linear-gradient(#000 4px, rgba(0, 0, 0, 0) 0) 50% -2px/calc(100% - 20px) 100% repeat-y}.mgt2 .minmaxwrapper input{display:inline-block;color:#000;background-color:rgba(0,0,0,0);text-align:center;font-size:1.5rem;width:3rem;height:2rem;border:none;outline:none}.mgt2 .minmaxwrapper input:focus{outline:none;box-shadow:none}.mgt2 .minmaxwrapper input:first-child{margin-left:5px}.mgt2 .minmaxwrapper input:last-child{margin-right:5px}.mgt2 .minmaxwrapper span{font-size:1.5rem;font-weight:500}.computer-overload,.computer-overload i{color:var(--mgt2-color-warning) !important}ul.softwares{list-style:none;margin:0;padding:0}ul.softwares li{display:inline-block;color:var(--mgt2-color-software);background-color:var(--mgt2-bgcolor-software);padding:3px 7px;border-radius:8px}ul.softwares li a{display:none}ul.softwares li a:first-child{margin:0 .5rem}ul.softwares li:hover a{display:inline-block}.character-header{display:flex;margin-top:8px;margin-right:8px;flex-direction:row;flex-wrap:nowrap;flex-grow:0;flex-shrink:0;justify-content:flex-start;align-items:flex-start}.character-header-img{flex-basis:138px;flex-grow:0;flex-shrink:0;text-align:center}.character-summary{flex:0 0 100%;margin:0;padding:0;list-style:none;border-top:5px double var(--mgt2-bgcolor-primary)}.character-summary li{float:left;margin:0;padding:0;color:var(--mgt2-color-form)}.character-summary input{display:block;border:none;font-weight:bold;font-family:"Roboto Condensed",sans-serif;background-color:#fff;color:var(--mgt2-color-form);font-size:.8rem;border:1px solid #fff}.character-summary input:hover{border:1px solid #111}.character-header-body{display:flex;flex-direction:column;flex-wrap:nowrap;justify-content:flex-start}.character-header-body legend{font-size:.7rem;text-transform:uppercase;text-wrap:nowrap;color:var(--mgt2-color-form)}.character-header-body legend i{margin-right:.25rem}.character-body{display:flex;flex-direction:row;align-content:flex-start;flex-wrap:nowrap}.character-body .tab{width:100%}.lifes{height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center}.lifes div{font-size:2rem}.character-states{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;justify-content:flex-start;align-items:flex-start;width:100%;float:right}.character-states li{display:flex;margin:0;padding:0;color:var(--mgt2-color-form);justify-content:space-between;align-items:center;width:100%;font-size:.7rem;line-height:1.1rem}.encumbrance-normal{color:var(--mgt2-encumbrance-normal) !important}.encumbrance-heavy{color:var(--mgt2-encumbrance-heavy) !important;font-weight:bold}.character-body{height:100%;overflow:hidden;display:flex;flex-direction:row;width:100%;justify-content:flex-start;align-items:flex-start;border-top:3px solid #000}.actor-footer{bottom:0;color:var(--mgt2-color-primary);background-color:var(--mgt2-bgcolor-primary);width:100%;margin:0 -8px;height:1.5rem;justify-content:space-between;align-items:center;padding:0 1rem;flex-grow:0;flex-shrink:0;display:flex;flex-direction:row}.itemsheet{display:flex !important;flex-direction:column !important;height:100% !important;background:#fff !important;overflow:hidden !important}.item-type-bar{background:#0a0405 !important;border-bottom:3px solid #ee4050 !important;padding:4px 12px !important;display:flex !important;align-items:center !important;gap:8px !important;min-height:0 !important;flex-shrink:0 !important}.item-type-bar .item-type-label{color:#ee4050 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.65rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:2px !important}.item-sheet-header{background:#0a0405 !important;padding:10px 14px !important;display:flex !important;align-items:center !important;gap:12px !important;flex-shrink:0 !important}.item-sheet-header .item-header-img{width:64px !important;height:64px !important;object-fit:cover !important;border:2px solid #ee4050 !important;border-radius:4px !important;cursor:pointer !important;flex-shrink:0 !important}.item-sheet-header .item-header-name{flex:1 !important;background:rgba(0,0,0,0) !important;border:none !important;border-bottom:1px solid rgba(238,64,80,.4) !important;color:#fff !important;font-family:"Barlow Condensed",sans-serif !important;font-size:1.6rem !important;font-weight:800 !important;text-transform:uppercase !important;letter-spacing:1px !important;padding:2px 0 !important;line-height:1.1 !important;width:100% !important}.item-sheet-header .item-header-name:focus{outline:none !important;border-bottom-color:#ee4050 !important}.item-sheet-header .item-header-name::placeholder{color:hsla(0,0%,100%,.35) !important}.item-stats-bar{background:#f5eeee !important;border-bottom:1px solid #ddc8c8 !important;padding:6px 14px !important;display:flex !important;flex-wrap:wrap !important;gap:6px !important;flex-shrink:0 !important}.item-stat-pill{display:flex !important;flex-direction:column !important;align-items:center !important;background:#fff !important;border:1px solid #ddc8c8 !important;border-radius:4px !important;padding:3px 10px !important;min-width:56px !important}.item-stat-pill .stat-label{color:#644 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.6rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1.5px !important;line-height:1.2 !important}.item-stat-pill .stat-value{color:#0a0405 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:1rem !important;font-weight:800 !important;line-height:1.1 !important}.item-stat-pill input,.item-stat-pill select{color:#0a0405 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:1rem !important;font-weight:800 !important;background:rgba(0,0,0,0) !important;border:none !important;text-align:center !important;width:100% !important;padding:0 !important;line-height:1.1 !important}.item-stat-pill input:focus,.item-stat-pill select:focus{outline:none !important;border-bottom:1px solid #ee4050 !important}.item-stat-pill-checkbox{display:flex !important;flex-direction:row !important;align-items:center !important;gap:5px !important;background:#fff !important;border:1px solid #ddc8c8 !important;border-radius:4px !important;padding:4px 10px !important}.item-stat-pill-checkbox input[type=checkbox]{margin:0 !important;width:14px !important;height:14px !important;accent-color:#ee4050 !important}.item-stat-pill-checkbox label{color:#644 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.65rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1px !important;cursor:pointer !important}.itemsheet .horizontal-tabs.tabs{background:#f5eeee !important;border-bottom:2px solid #ddc8c8 !important;display:flex !important;flex-wrap:wrap !important;gap:0 !important;padding:0 10px !important;flex-shrink:0 !important}.itemsheet .horizontal-tabs.tabs .item.tab-select{color:#644 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.72rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1.5px !important;padding:6px 14px !important;border:none !important;border-bottom:2px solid rgba(0,0,0,0) !important;margin-bottom:-2px !important;background:rgba(0,0,0,0) !important;cursor:pointer !important;transition:color .15s,border-color .15s !important}.itemsheet .horizontal-tabs.tabs .item.tab-select:hover{color:#ee4050 !important}.itemsheet .horizontal-tabs.tabs .item.tab-select.active{color:#ee4050 !important;border-bottom-color:#ee4050 !important;background:rgba(0,0,0,0) !important}.itemsheet .tab-content-area{flex:1 !important;overflow-y:auto !important;padding:10px 14px !important;background:#fff !important}.itemsheet .tab[data-group]{display:none !important}.itemsheet .tab[data-group].active{display:block !important}.itemsheet .field-group{margin-bottom:8px !important}.itemsheet .field-group label{display:block !important;color:#644 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.68rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1px !important;margin-bottom:2px !important}.itemsheet .field-groups{display:flex !important;flex-wrap:wrap !important;gap:10px !important;align-items:flex-start !important}.itemsheet .field-groups .field-group{flex:1 !important;min-width:80px !important}.itemsheet input[type=text],.itemsheet input[type=number],.itemsheet select,.itemsheet textarea{background:#fdf8f8 !important;border:1px solid #ddc8c8 !important;border-radius:3px !important;color:#0a0405 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.85rem !important;padding:4px 8px !important;width:100% !important}.itemsheet input[type=text]:focus,.itemsheet input[type=number]:focus,.itemsheet select:focus,.itemsheet textarea:focus{outline:none !important;border-color:#ee4050 !important;box-shadow:0 0 0 2px rgba(238,64,80,.12) !important}.itemsheet textarea{resize:vertical !important;min-height:80px !important}.itemsheet .mgt2-checkbox{display:flex !important;align-items:center !important;gap:6px !important;color:#644 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.72rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1px !important}.itemsheet .mgt2-checkbox input[type=checkbox]{width:14px !important;height:14px !important;margin:0 !important;accent-color:#ee4050 !important}.itemsheet .table-container{border:1px solid #ddc8c8 !important;border-radius:4px !important;overflow:hidden !important;margin-top:8px !important}.itemsheet .table-row{display:flex !important;align-items:stretch !important;border-bottom:1px solid #e8dada !important}.itemsheet .table-row:last-child{border-bottom:none !important}.itemsheet .table-row.heading{background:#0a0405 !important;color:#ee4050 !important}.itemsheet .table-row.heading .row-item{color:#ee4050 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.68rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1px !important;padding:5px 8px !important}.itemsheet .table-row:not(.heading){background:#fff !important}.itemsheet .table-row:not(.heading):nth-child(even){background:#fdf8f8 !important}.itemsheet .table-row:not(.heading) .row-item{padding:4px 6px !important}.itemsheet .table-row:not(.heading) .row-item input,.itemsheet .table-row:not(.heading) .row-item textarea,.itemsheet .table-row:not(.heading) .row-item select{font-size:.8rem !important;padding:2px 6px !important}.itemsheet .row-item{flex:1 !important;border-right:1px solid #e8dada !important}.itemsheet .row-item:last-child{border-right:none !important}.itemsheet .row-item.row-item-left{justify-content:flex-start !important}.itemsheet .row-item.row-item-right{flex:0 0 auto !important;min-width:36px !important;display:flex !important;align-items:center !important;justify-content:center !important}.itemsheet .row-item.row-item-30{flex:0 0 30% !important}.itemsheet .item-controls{display:flex !important;align-items:center !important;justify-content:center !important;gap:6px !important}.itemsheet .item-controls a{color:#888 !important;cursor:pointer !important}.itemsheet .item-controls a:hover{color:#ee4050 !important}.itemsheet-header{display:none !important}.itemsheet-maincol{display:none !important}.itemsheet-panel{display:contents !important}li.chat-message{background:#fff !important;border:1px solid #cbb !important;box-shadow:0 2px 8px rgba(0,0,0,.18) !important;color:#0a0405;padding:0 !important}li.chat-message .message-header{background:#0a0405;border-bottom:3px solid #ee4050;padding:4px 10px}li.chat-message .message-header .message-sender{color:#ee4050;font-family:"Barlow Condensed",sans-serif;font-weight:700;font-size:.75rem;text-transform:uppercase;letter-spacing:1.5px;margin:0}li.chat-message .message-header .message-timestamp{color:#888;font-size:.68rem}li.chat-message .message-header .message-delete i{color:#888}li.chat-message .message-header:hover .message-delete i{color:#ee4050}li.chat-message .message-content>.dice-roll{background:#fdf8f8;padding:6px 12px}li.chat-message .message-content>.dice-roll .dice-formula{background:#f5eeee;border:1px solid #ddc8c8;border-radius:3px;color:#644;font-size:.78rem;padding:2px 10px;text-align:center;font-family:"Barlow Condensed",sans-serif;display:inline-block;margin:0 auto 4px auto}li.chat-message .message-content>.dice-roll .dice-result{display:flex;flex-direction:column;align-items:center;gap:3px}li.chat-message .message-content>.dice-roll h4.dice-total{font-family:"Barlow Condensed",sans-serif;font-size:2.2rem !important;font-weight:900;color:#0a0405 !important;margin:2px 0;line-height:1;text-align:center;background:rgba(0,0,0,0) !important;width:100% !important;display:block !important}li.chat-message .message-content>.dice-roll .dice-tooltip .part-header{background:#f5eeee;padding:2px 8px;display:flex;justify-content:space-between}li.chat-message .message-content>.dice-roll .dice-tooltip .part-header .part-formula,li.chat-message .message-content>.dice-roll .dice-tooltip .part-header .part-total{color:#ee4050;font-weight:700;font-size:.78rem}li.chat-message .message-content>.dice-roll .dice-tooltip .dice-rolls{display:flex;flex-wrap:wrap;justify-content:center;gap:4px;padding:6px 8px;list-style:none;margin:0}li.chat-message .message-content>.dice-roll .dice-tooltip .roll.die{display:flex;align-items:center;justify-content:center;width:26px;height:26px;background:#f5eeee;border:1.5px solid #ddc8c8;border-radius:4px;color:#3a2020;font-weight:700;font-size:.9rem}.mgt2-chat-roll{font-family:"Barlow Condensed",sans-serif}.mgt2-chat-roll .mgt2-roll-header{background:#0a0405 !important;border-left:4px solid #ee4050 !important;padding:5px 10px 4px 10px !important}.mgt2-chat-roll .mgt2-roll-header .mgt2-roll-char-name{display:block;color:#fff;font-size:1.2rem;font-weight:800;text-transform:uppercase;letter-spacing:1px;line-height:1}.mgt2-chat-roll .mgt2-roll-header .mgt2-roll-meta{display:flex;align-items:center;gap:6px;margin-top:2px}.mgt2-chat-roll .mgt2-roll-header .mgt2-roll-type{color:#ee4050;font-size:.68rem;font-weight:700;text-transform:uppercase;letter-spacing:2px}.mgt2-chat-roll .mgt2-roll-header .mgt2-roll-sep{color:#888}.mgt2-chat-roll .mgt2-roll-header .mgt2-roll-difficulty{color:#bbb;font-size:.68rem;text-transform:uppercase;letter-spacing:1px}.mgt2-chat-roll .mgt2-roll-modifier{background:#f5eeee;border-bottom:1px solid #e8dada;padding:3px 14px;color:#644;font-size:.8rem}.mgt2-chat-roll .mgt2-roll-modifiers{display:flex;gap:6px;flex-wrap:wrap;background:#f5eeee;border-bottom:1px solid #e8dada;padding:3px 14px}.mgt2-chat-roll .mgt2-roll-modifiers .mgt2-roll-mod-tag{color:#644;font-size:.8rem}.mgt2-chat-roll .dice-roll{background:#fdf8f8;padding:4px 10px;cursor:pointer}.mgt2-chat-roll .dice-roll .dice-flavor{color:#888;font-size:.73rem;text-align:center;margin-bottom:3px}.mgt2-chat-roll .dice-roll .dice-result{display:flex;flex-direction:column;align-items:center;gap:3px}.mgt2-chat-roll .dice-roll .dice-formula{background:#f5eeee;border:1px solid #ddc8c8;border-radius:3px;color:#644;font-size:.78rem;padding:2px 14px;font-family:"DM Sans",sans-serif;text-align:center}.mgt2-chat-roll .dice-roll .dice-tooltip{width:100%}.mgt2-chat-roll .dice-roll .dice-tooltip .wrapper{background:rgba(0,0,0,0)}.mgt2-chat-roll .dice-roll .dice-tooltip .tooltip-part{background:#fdf8f8;border:1px solid #e8dada;border-radius:4px;margin-bottom:6px;overflow:hidden}.mgt2-chat-roll .dice-roll .dice-tooltip .part-header{background:#f5eeee;padding:3px 8px}.mgt2-chat-roll .dice-roll .dice-tooltip .part-header .part-formula,.mgt2-chat-roll .dice-roll .dice-tooltip .part-header .part-total{color:#ee4050;font-weight:700;font-size:.8rem}.mgt2-chat-roll .dice-roll .dice-tooltip .dice-rolls{display:flex;flex-wrap:wrap;justify-content:center;gap:5px;padding:8px 10px;list-style:none;margin:0}.mgt2-chat-roll .dice-roll .dice-tooltip .roll.die{display:flex;align-items:center;justify-content:center;width:30px;height:30px;background:#f5eeee;border:1.5px solid #ddc8c8;border-radius:5px;color:#3a2020;font-weight:700;font-size:1rem;font-family:"Barlow Condensed",sans-serif}.mgt2-chat-roll .dice-roll .dice-tooltip .roll.die.max{border-color:#ee4050;color:#ee4050;background:#fde8ea;box-shadow:0 0 8px rgba(238,64,80,.2)}.mgt2-chat-roll .dice-roll .dice-tooltip .roll.die.min{border-color:#cbb;color:#999}.mgt2-chat-roll .dice-roll h4.dice-total{font-size:1.6rem !important;font-weight:900;color:#0a0405 !important;margin:3px 0 2px 0;line-height:1;font-family:"Barlow Condensed",sans-serif;text-align:center;text-shadow:none;background:#f5eeee !important;border:1px solid #ddc8c8 !important;border-radius:4px !important;padding:2px 14px !important;width:auto !important;display:inline-block !important;min-width:60px}.mgt2-chat-roll .dice-roll h4.dice-total.success{color:#1a8840 !important;background:rgba(82,232,122,.1) !important;border-color:rgba(26,136,64,.35) !important}.mgt2-chat-roll .dice-roll h4.dice-total.failure{color:#ee4050 !important;background:rgba(238,64,80,.07) !important;border-color:rgba(238,64,80,.3) !important}.mgt2-chat-roll .mgt2-outcome{text-align:center;font-size:.75rem;font-weight:700;text-transform:uppercase;letter-spacing:2px;padding:3px 10px}.mgt2-chat-roll .mgt2-outcome i{margin-right:5px}.mgt2-chat-roll .mgt2-outcome.is-success{background:rgba(26,136,64,.08);color:#1a8840;border-top:1px solid rgba(26,136,64,.2)}.mgt2-chat-roll .mgt2-outcome.is-failure{background:rgba(238,64,80,.07);color:#ee4050;border-top:1px solid rgba(238,64,80,.2)}.mgt2-chat-roll .mgt2-buttons{display:flex;justify-content:center;flex-wrap:wrap;gap:4px;padding:5px 10px;background:#f5eeee;border-top:1px solid #ddc8c8}.mgt2-chat-roll .mgt2-buttons button{background:#fff;border:1px solid #cbb;color:#3a2020;border-radius:3px;padding:4px 14px;font-family:"Barlow Condensed",sans-serif;font-size:.78rem;font-weight:700;text-transform:uppercase;letter-spacing:1px;cursor:pointer;transition:background .15s ease,box-shadow .15s ease;box-shadow:none}.mgt2-chat-roll .mgt2-buttons button i{font-size:1rem;padding:0;margin:0}.mgt2-chat-roll .mgt2-buttons button:hover{background:#ee4050;border-color:#ee4050;color:#fff;box-shadow:0 0 8px rgba(238,64,80,.25)}.mgt2 nav.horizontal-tabs{color:var(--mgt2-color-primary);background:var(--mgt2-bgcolor-primary);font-style:normal;font-weight:700;font-size:14px;line-height:30px;text-transform:uppercase;justify-content:space-around;align-items:center;font-family:"Roboto Condensed",sans-serif}.mgt2 nav.horizontal-tabs a.item{position:relative;flex:1 1 auto}.mgt2 nav.horizontal-tabs a.item i{margin-right:.5rem}.mgt2 nav.horizontal-tabs>a.item::after{content:"";position:absolute;inset:.25rem .25rem .25rem .25rem;border:1px solid var(--mgt2-color-primary-active);pointer-events:none}.mgt2 nav.horizontal-tabs>a.item.active::after{border-bottom:none;border-top:2px solid var(--mgt2-color-primary-active);border-left:2px solid var(--mgt2-color-primary-active);border-right:2px solid var(--mgt2-color-primary-active);inset:.25rem .25rem 0 .25rem}.mgt2 nav.horizontal-tabs .active{color:var(--mgt2-color-primary);text-decoration:none;text-shadow:none;border-bottom:none}.tab[data-tab].fullsize{height:calc(100% - 3rem)}.subTab{flex-flow:column;height:100%;display:flex;justify-content:flex-start;align-items:stretch}.tab-scroll{overflow-y:auto;height:100%}.subTabs{height:100%;flex-direction:column}.subTabs.active{display:flex !important}.mgt2.character,.mgt2.creature{overflow:visible !important}.mgt2.character>.window-content,.mgt2.creature>.window-content{overflow:visible !important}.mgt2.character .editable,.mgt2.character .locked,.mgt2.creature .editable,.mgt2.creature .locked{overflow:visible !important}.mgt2.character .character-body{position:relative !important;overflow:visible !important}.mgt2.creature .creature-body{position:relative !important;overflow:visible !important}.mgt2 nav.sheet-sidebar.tabs{position:absolute !important;left:100% !important;top:0 !important;bottom:0 !important;width:62px !important;flex:none !important;display:flex !important;flex-direction:column;background:linear-gradient(180deg, #1e0507 0%, #110304 40%, #0a0202 100%);border-top:1px solid rgba(238,64,80,.35);border-right:1px solid rgba(238,64,80,.25);border-bottom:1px solid rgba(238,64,80,.2);border-left:3px solid var(--mgt2-color-primary);border-radius:0 10px 10px 0;box-shadow:6px 0 24px rgba(0,0,0,.75),0 0 0 0 rgba(0,0,0,0),inset 1px 0 16px rgba(238,64,80,.05);z-index:10;overflow:hidden !important;padding:2px 0}.mgt2 nav.sheet-sidebar.tabs>.item{position:relative;display:flex !important;flex-direction:column !important;justify-content:center !important;align-items:center !important;gap:4px !important;min-height:54px;padding:8px 4px;color:rgba(238,64,80,.45);border-bottom:1px solid rgba(238,64,80,.07);cursor:pointer;transition:background 180ms ease,color 180ms ease,box-shadow 180ms ease;user-select:none;text-decoration:none !important}.mgt2 nav.sheet-sidebar.tabs>.item::before{content:"";position:absolute;left:-3px;top:18%;bottom:18%;width:3px;background:rgba(0,0,0,0);border-radius:0 3px 3px 0;transition:background 180ms ease,top 180ms ease,bottom 180ms ease,box-shadow 180ms ease}.mgt2 nav.sheet-sidebar.tabs>.item:hover{color:var(--mgt2-color-primary);background:rgba(238,64,80,.07)}.mgt2 nav.sheet-sidebar.tabs>.item:hover::before{background:rgba(238,64,80,.5)}.mgt2 nav.sheet-sidebar.tabs>.item:hover .tab-label{color:rgba(238,64,80,.7)}.mgt2 nav.sheet-sidebar.tabs>.item.active{color:var(--mgt2-color-primary);background:linear-gradient(90deg, rgba(238, 64, 80, 0.16) 0%, rgba(238, 64, 80, 0.03) 100%);box-shadow:inset 0 1px 0 rgba(238,64,80,.12),inset 0 -1px 0 rgba(238,64,80,.08)}.mgt2 nav.sheet-sidebar.tabs>.item.active::before{background:var(--mgt2-color-primary);top:10%;bottom:10%;box-shadow:0 0 10px rgba(238,64,80,.7),0 0 20px rgba(238,64,80,.3)}.mgt2 nav.sheet-sidebar.tabs>.item.active i{filter:drop-shadow(0 0 5px rgba(238, 64, 80, 0.55))}.mgt2 nav.sheet-sidebar.tabs>.item.active .tab-label{color:rgba(238,64,80,.85)}.mgt2 nav.sheet-sidebar.tabs>.item i{font-size:1.15rem;pointer-events:none;line-height:1}.mgt2 nav.sheet-sidebar.tabs>.item .tab-label{font-family:"Barlow Condensed",sans-serif;font-size:.52rem;font-weight:700;text-transform:uppercase;letter-spacing:.8px;color:rgba(238,64,80,.3);line-height:1;pointer-events:none;transition:color 180ms ease}.container-controls{display:inline-block;margin-left:1rem}.container-controls a:not(:last-child){margin-right:.5rem}.table-container{display:flex;flex-flow:column nowrap;width:100%;margin:0 auto}.table-row{display:flex;flex-flow:row nowrap;width:100%;position:relative;align-items:flex-start}.table-row.heading{background-color:var(--mgt2-bgcolor-primary);align-items:center}.table-row.heading .row-item{text-transform:uppercase;font-size:12px}.table-row.heading .row-item:first-child{font-weight:bold;font-size:13px;letter-spacing:3px}.table-row.heading .row-item:first-child i{margin-right:.5rem}.table-row.heading.color-1 .row-item{background-color:var(--mgt2-bgcolor-primary);color:var(--mgt2-color-primary)}.table-row.heading.color-2 .row-item{background-color:var(--mgt2-bgcolor-form);color:var(--mgt2-bgcolor-primary)}.table-row.heading div.row-item{padding-left:5px}.table-row.heading div.row-item:last-child{padding-right:5px}.table-row:hover:not(.heading){background-color:var(--mgt2-row-hover)}.table-row-mb-4{margin-bottom:4px}.row-item{display:flex;flex-grow:1;font-size:14px;line-height:25px;align-items:center;transition:all .15s ease-in-out;overflow:hidden !important;text-overflow:ellipsis;text-wrap:nowrap}.row-item.item-controls{justify-content:right;padding-right:4px}.row-item.item-controls a:not(:last-child){margin-right:.4rem}.row-item i{color:var(--mgt2-color-form)}.row-item a[data-roll]{margin-right:.5rem}.heading.color-1 .row-item i{color:var(--mgt2-color-primary) !important}.heading.color-2 .row-item i{color:var(--mgt2-bgcolor-primary) !important}.table-subrow{border-left:2px var(--mgt2-subrow-color) dashed;color:var(--mgt2-subrow-color)}.table-subrow .row-item{font-size:.8em;line-height:20px}.table-subrow .row-item:first-child{padding-left:1rem}.table-subrow .row-item>i{margin-right:4px}.row-item-center{justify-content:center;text-align:center}.row-item-left{justify-content:left}.row-item-right{justify-content:right}.row-item-space-between{justify-content:space-between}.row-item-2{flex-basis:4rem}.row-item-5{flex-basis:5%}.row-item-10{flex-basis:10%}.row-item-12{flex-basis:4rem}.row-item-15{flex-basis:5rem}.row-item-20{flex-basis:20%}.row-item-25{flex-basis:25%}.row-item-30{flex-basis:30%}.row-item-35{flex-basis:35%}.row-item-40{flex-basis:40%}.row-item-45{flex-basis:45%}.row-item-50{flex-basis:50%}.row-item-65{flex-basis:50%}.row-item-85{flex-basis:50%}.row-item-storage{flex-wrap:wrap;flex-grow:0;flex-basis:20%;font-size:.7rem;line-height:.8rem}.item-control.item-equip i{color:var(--mgt2-row-inactive-icon)}.item-control.item-equip.active i{color:var(--mgt2-color-form)}.row-description{flex-basis:100%;font-size:14px;padding:4px 0;justify-content:left;transition:all .15s ease-in-out}.row-sub-container{display:flex;flex-flow:column nowrap;flex:1}.row-sub-container .row-item{padding:8px 0;border-bottom:1px solid var(--mgt2-bgcolor-primary)}.table-row:last-child,.row-sub-container .row-item:last-child{border-bottom:0}.table-container.editable .table-row{margin-top:4px}.table-container.editable .table-row:last-child{margin-bottom:4px}.item-options{position:absolute;top:.7rem;font-size:.7em;left:1.6rem;text-transform:uppercase;font-family:"DM Sans",sans-serif;font-optical-sizing:auto;font-weight:600;font-style:normal;color:var(--mgt2-subrow-color)}.creature-sheet .creature-header{display:flex;flex-direction:row;align-items:flex-start;gap:.75rem;padding:.5rem .75rem .5rem;background:var(--mgt2-bgcolor-form);border-bottom:2px solid var(--mgt2-color-primary)}.creature-sheet .creature-header-img{flex:0 0 80px}.creature-sheet .creature-header-img img.profile{width:80px;height:80px;object-fit:cover;border:2px solid var(--mgt2-color-primary);border-radius:4px;cursor:pointer}.creature-sheet .creature-header-body{flex:1;display:flex;flex-direction:column;gap:.4rem}.creature-sheet .creature-name{font-family:"Barlow Condensed",sans-serif;font-size:1.6rem;font-weight:700;font-style:italic;color:var(--mgt2-color-form);background:rgba(0,0,0,0);border:none;border-bottom:1px solid var(--mgt2-color-primary);width:100%;padding:0}.creature-sheet .creature-name:focus{outline:none;border-bottom-color:var(--mgt2-color-secondary)}.creature-sheet .creature-stats-row{display:flex;flex-direction:row;flex-wrap:wrap;gap:.5rem}.creature-sheet .creature-stat{display:flex;flex-direction:column;align-items:center;background:var(--mgt2-bgcolor-primary);border:1px solid var(--mgt2-color-primary);border-radius:4px;padding:2px 6px;min-width:4rem}.creature-sheet .creature-stat label{font-family:"Barlow Condensed",sans-serif;font-size:.7rem;font-weight:700;text-transform:uppercase;color:var(--mgt2-color-primary);line-height:1.2}.creature-sheet .creature-stat .creature-stat-value{display:flex;align-items:center;gap:2px}.creature-sheet .creature-stat .creature-stat-value input{width:2.5rem;text-align:center;background:rgba(0,0,0,0);border:none;color:var(--mgt2-bgcolor-form);font-size:1rem;font-weight:700;padding:0}.creature-sheet .creature-stat .creature-stat-value input:focus{outline:none;border-bottom:1px solid var(--mgt2-color-primary)}.creature-sheet .creature-stat .creature-stat-value .stat-max{width:2.5rem}.creature-sheet .creature-stat .creature-stat-value .stat-unit{font-size:.7rem;color:var(--mgt2-bgcolor-form);opacity:.7}.creature-sheet .creature-stat .creature-stat-value .stat-readonly{font-size:1rem;font-weight:700;color:var(--mgt2-bgcolor-form);min-width:2.5rem;text-align:center}.creature-sheet .creature-behavior-row{display:flex;flex-direction:row;align-items:center;gap:.5rem;flex-wrap:wrap}.creature-sheet .creature-behavior-row label{font-size:.75rem;text-transform:uppercase;color:var(--mgt2-color-primary);font-weight:700}.creature-sheet .creature-behavior-row .behavior-select{background:var(--mgt2-bgcolor-form);color:var(--mgt2-color-form);border:1px solid var(--mgt2-color-primary);border-radius:3px;font-size:.85rem;padding:1px 4px}.creature-sheet .creature-behavior-row .behavior-sep{color:var(--mgt2-color-form);opacity:.5}.creature-sheet .creature-size-badge{margin-left:auto;font-size:.75rem;font-style:italic;color:var(--mgt2-color-secondary);background:var(--mgt2-bgcolor-primary);border:1px solid var(--mgt2-color-secondary);border-radius:3px;padding:1px 6px}.creature-sheet .creature-body{flex:1;overflow-y:auto;padding:.5rem .75rem}.creature-sheet .creature-body .tab{display:none}.creature-sheet .creature-body .tab.active{display:block}.creature-sheet .creature-info-tab{display:flex;flex-direction:column;gap:.5rem}.creature-sheet .creature-description{width:100%;background:var(--mgt2-bgcolor-form);color:var(--mgt2-color-form);border:1px solid var(--mgt2-color-primary);border-radius:3px;padding:4px;resize:vertical;font-size:.9rem}.creature-sheet .creature-damage .damage-formula{font-family:"Barlow Condensed",sans-serif;font-weight:700;color:var(--mgt2-color-primary);font-size:1rem}.creature-sheet .trait-name{font-weight:600;color:var(--mgt2-color-form)}.creature-sheet .trait-value{font-style:italic;color:var(--mgt2-color-secondary)}.mgt2-creature-roll .mgt2-roll-header{display:flex;flex-direction:row;align-items:center;gap:.6rem}.mgt2-creature-roll .creature-chat-img{width:36px;height:36px;object-fit:cover;border:1px solid var(--mgt2-color-primary);border-radius:3px;flex:0 0 36px}.mgt2-creature-roll .mgt2-roll-header-text{flex:1}/*# sourceMappingURL=mgt2.min.css.map */
+@import"https://fonts.googleapis.com/css2?family=Barlow+Condensed:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap";@import"https://fonts.googleapis.com/css2?family=Rubik:ital,wght@0,300..900;1,300..900&display=swap";@import"https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&display=swap";.black-and-red{--mgt2-color-form: #0A0405;--mgt2-bgcolor-form: #fff;--mgt2-color-primary: #EE4050;--mgt2-color-primary-active: #AF2F3C;--mgt2-bgcolor-primary: #0A0405;--mgt2-color-primary-light: #4b4a44;--mgt2-color-warning: #EE4050;--mgt2-color-dm: #fff;--mgt2-bgcolor-dm: #0A0405;--mgt2-color-software: #fff;--mgt2-bgcolor-software: #0A0405;--mgt2-input-color: #0A0405;--mgt2-input-bgcolor: #fff;--mgt2-editor-border: #C6C6C6;--mgt2-row-hover: #F2F2F2;--mgt2-subrow-color: #727272;--mgt2-row-inactive-icon: #b5b3a4;--mgt2-encumbrance-normal: #D94826;--mgt2-encumbrance-heavy: #D82727}.mwamba{--mgt2-color-form: #0A0405;--mgt2-bgcolor-form: #fff;--mgt2-color-primary: #2A9932;--mgt2-color-primary-active: #40ED4E;--mgt2-bgcolor-primary: #0A0405;--mgt2-color-primary-light: #4b4a44;--mgt2-color-warning: #EE4050;--mgt2-color-dm: #fff;--mgt2-bgcolor-dm: #0A0405;--mgt2-color-software: #fff;--mgt2-bgcolor-software: #0A0405;--mgt2-input-color: #0A0405;--mgt2-input-bgcolor: #fff;--mgt2-editor-border: #C6C6C6;--mgt2-row-hover: #F2F2F2;--mgt2-subrow-color: #727272;--mgt2-row-inactive-icon: #b5b3a4}.blue{--mgt2-color-form: #0A0405;--mgt2-bgcolor-form: #fff;--mgt2-color-primary: #91AAC8;--mgt2-color-primary-active: #BCDCFF;--mgt2-bgcolor-primary: #0A0405;--mgt2-color-primary-light: #4b4a44;--mgt2-color-warning: #EE4050;--mgt2-color-dm: #fff;--mgt2-bgcolor-dm: #0A0405;--mgt2-color-software: #fff;--mgt2-bgcolor-software: #0A0405;--mgt2-input-color: #0A0405;--mgt2-input-bgcolor: #fff;--mgt2-editor-border: #C6C6C6;--mgt2-row-hover: #F2F2F2;--mgt2-subrow-color: #727272;--mgt2-row-inactive-icon: #b5b3a4}.upcase{text-transform:uppercase}.w1-10{width:10%}.w2-10{width:20%}.w3-10{width:30%}.w4-10{width:40%}.w5-10{width:50%}.h100{height:100%}.w100{width:100%}.mgt2 a:hover{text-shadow:none}.mgt2 .w-100{width:100%}.mgt2 .mb-1{margin-bottom:8px}.mgt2 .mt-1,.mgt2 .mt-05{margin-top:8px}.mgt2 .mt-2{margin-top:14px}.mgt2.sheet header.window-header{color:var(--mgt2-color-primary);background-color:var(--mgt2-bgcolor-primary)}.mgt2.sheet h4.window-title{font-weight:bold;text-transform:uppercase}.mgt2.sheet .window-content{background:var(--mgt2-bgcolor-form);color:var(--mgt2-color-form);padding:0}.nopad .window-content{padding:0}.mgt2 .flex-fix{flex-grow:0 !important;flex-shrink:0 !important}.mgt2 .flex-basis-10{flex-basis:10%}.mgt2 .flex-basis-20{flex-basis:20%}.mgt2 .flex-basis-30{flex-basis:30%}.mgt2 .flex-basis-40{flex-basis:40%}.mgt2 .flex-basis-50{flex-basis:50%}.mgt2 .flex-basis-60{flex-basis:60%}.mgt2 .flex-basis-70{flex-basis:70%}.mgt2.sheet textarea{color:var(--mgt2-input-color);background-color:var(--mgt2-input-bgcolor);font-family:"Roboto",sans-serif;font-size:13px;font-stretch:100%}.mgt2 input:focus,.mgt2 textarea:focus,.mgt2 select:focus{outline:none;box-shadow:none}.mgt2 .checkbox-small{flex:none !important;width:auto !important;height:auto !important;margin:0 !important}.mgt2 .header{color:var(--mgt2-color-primary);background:var(--mgt2-bgcolor-primary);font-size:14px;font-family:"Roboto Condensed",sans-serif;font-weight:bold;padding-left:5px;margin-bottom:4px;line-height:30px;text-transform:uppercase}.mgt2 .field-groups{display:flex;flex-direction:row;flex-wrap:nowrap;align-items:center;justify-content:space-between}.mgt2 .field-group label{text-transform:uppercase;font-weight:700;font-size:14px;font-family:"Roboto Condensed",sans-serif;font-optical-sizing:auto}.mgt2 input.field{background-color:var(--mgt2-input-bgcolor);font-size:13px}.mgt2 input.field-name{background-color:var(--mgt2-input-bgcolor);color:var(--mgt2-color-primary);font-size:2rem;border:none;font-weight:700;font-family:"Roboto Condensed",sans-serif;margin-bottom:.5rem;padding:0}.mgt2 input.field-item-name{background-color:var(--mgt2-input-bgcolor);color:var(--mgt2-color-primary);height:auto;font-size:2rem;font-weight:700;font-family:"Roboto Condensed",sans-serif}.mgt2 .fields{display:flex}.mgt2 .editor{min-height:3rem;border:1px solid var(--mgt2-editor-border);height:100%}.mgt2 .sheet-body{margin-left:140px;padding-bottom:1.5rem}.mgt2 label.mgt2-checkbox{display:flex;flex-direction:row;align-items:center}.mgt2 label.mgt2-checkbox input{margin:0 .3rem 0 0}.mgt2 .dialog-button{color:var(--mgt2-color-primary);background-color:var(--mgt2-bgcolor-primary) !important}.mgt2-roll-dialog{background:#fff !important;border:1px solid #cbb !important;box-shadow:0 8px 32px rgba(0,0,0,.35) !important;border-radius:6px !important;overflow:hidden !important}.mgt2-roll-dialog .window-header{background:#0a0405 !important;border-bottom:3px solid #ee4050 !important;padding:10px 14px !important;position:relative !important}.mgt2-roll-dialog .window-header .window-title{color:#fff !important;font-family:"Barlow Condensed",sans-serif !important;font-weight:700 !important;font-size:1rem !important;text-transform:uppercase !important;letter-spacing:2px !important}.mgt2-roll-dialog .window-content{background:#fff !important;color:#0a0405 !important;padding:0 !important}.mgt2-roll-dialog .window-content .dialog-content,.mgt2-roll-dialog .window-content .standard-form{background:#fff !important;padding:8px 14px 6px !important}.mgt2-roll-dialog .window-content .form-group{display:flex !important;align-items:center !important;gap:8px !important;margin-bottom:3px !important;padding:2px 0 !important;border-bottom:1px solid #e8e0e0 !important}.mgt2-roll-dialog .window-content .form-group:last-child{border-bottom:none !important}.mgt2-roll-dialog .window-content .form-group label{color:#0a0405 !important;font-family:"Barlow Condensed",sans-serif !important;font-weight:700 !important;font-size:.72rem !important;text-transform:uppercase !important;letter-spacing:1.2px !important;flex:0 0 110px !important;line-height:1.2 !important}.mgt2-roll-dialog .window-content .form-group select,.mgt2-roll-dialog .window-content .form-group input[type=number],.mgt2-roll-dialog .window-content .form-group input[type=text]{flex:1 !important;background:#fff !important;border:1px solid #cbb !important;color:#0a0405 !important;border-radius:3px !important;padding:3px 8px !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.9rem !important;transition:border-color 150ms ease !important}.mgt2-roll-dialog .window-content .form-group select:focus,.mgt2-roll-dialog .window-content .form-group input[type=number]:focus,.mgt2-roll-dialog .window-content .form-group input[type=text]:focus{border-color:#ee4050 !important;outline:none !important;background:rgba(238,64,80,.04) !important}.mgt2-roll-dialog .window-content .form-group select option,.mgt2-roll-dialog .window-content .form-group input[type=number] option,.mgt2-roll-dialog .window-content .form-group input[type=text] option{background:#fff !important;color:#0a0405 !important}.mgt2-roll-dialog .window-content fieldset,.mgt2-roll-dialog .window-content .form-fields{background:#fdf8f8 !important;border:1px solid #e0c8c8 !important;border-radius:5px !important;padding:5px 10px !important;margin-bottom:4px !important}.mgt2-roll-dialog .window-content fieldset legend,.mgt2-roll-dialog .window-content .form-fields legend{color:#ee4050 !important;font-family:"Barlow Condensed",sans-serif !important;font-weight:700 !important;font-size:.72rem !important;text-transform:uppercase !important;letter-spacing:2px !important;padding:0 8px !important;background:#fff !important}.mgt2-roll-dialog .window-content fieldset .form-group,.mgt2-roll-dialog .window-content .form-fields .form-group{border-bottom:none !important;margin-bottom:4px !important;padding:2px 0 !important}.mgt2-roll-dialog .window-content fieldset label,.mgt2-roll-dialog .window-content .form-fields label{color:#3a2020 !important;flex:1 !important}.mgt2-roll-dialog .window-content fieldset input[type=checkbox],.mgt2-roll-dialog .window-content .form-fields input[type=checkbox]{accent-color:#ee4050 !important;width:14px !important;height:14px !important}.mgt2-roll-dialog .dialog-buttons,.mgt2-roll-dialog .form-footer,.mgt2-roll-dialog footer{background:#f5eeee !important;border-top:2px solid #ee4050 !important;padding:7px 14px !important;display:flex !important;gap:8px !important;justify-content:center !important}.mgt2-roll-dialog .dialog-buttons button,.mgt2-roll-dialog .form-footer button,.mgt2-roll-dialog footer button{flex:1 !important;max-width:140px !important;background:#fff !important;border:1px solid #cbb !important;color:#3a2020 !important;border-radius:4px !important;padding:5px 12px !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.82rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1.5px !important;cursor:pointer !important;transition:all 150ms ease !important}.mgt2-roll-dialog .dialog-buttons button:hover,.mgt2-roll-dialog .form-footer button:hover,.mgt2-roll-dialog footer button:hover{background:#fdf0f0 !important;border-color:#ee4050 !important;color:#ee4050 !important}.mgt2-roll-dialog .dialog-buttons button.default,.mgt2-roll-dialog .dialog-buttons button[data-action=submit],.mgt2-roll-dialog .dialog-buttons button[autofocus],.mgt2-roll-dialog .form-footer button.default,.mgt2-roll-dialog .form-footer button[data-action=submit],.mgt2-roll-dialog .form-footer button[autofocus],.mgt2-roll-dialog footer button.default,.mgt2-roll-dialog footer button[data-action=submit],.mgt2-roll-dialog footer button[autofocus]{background:#ee4050 !important;border-color:#ee4050 !important;color:#fff !important;box-shadow:0 2px 12px rgba(238,64,80,.3) !important}.mgt2-roll-dialog .dialog-buttons button.default:hover,.mgt2-roll-dialog .dialog-buttons button[data-action=submit]:hover,.mgt2-roll-dialog .dialog-buttons button[autofocus]:hover,.mgt2-roll-dialog .form-footer button.default:hover,.mgt2-roll-dialog .form-footer button[data-action=submit]:hover,.mgt2-roll-dialog .form-footer button[autofocus]:hover,.mgt2-roll-dialog footer button.default:hover,.mgt2-roll-dialog footer button[data-action=submit]:hover,.mgt2-roll-dialog footer button[autofocus]:hover{background:#ff5060 !important;box-shadow:0 4px 18px rgba(238,64,80,.45) !important}.characteristics-panel .tab{padding:4px}.species{font-size:13px;margin:4px 1rem 0 1rem;text-align:justify}.species a{margin-right:1rem}.mgt2 .characteristics{flex-basis:138px;flex-grow:0;flex-shrink:0;position:relative}.mgt2 .characteristics-header{color:var(--mgt2-color-primary);background:var(--mgt2-bgcolor-primary);font-family:"Rubik",monospace;font-style:normal;font-size:1rem;line-height:2rem;text-transform:uppercase}.mgt2 .characteristic-row{display:flex;flex-direction:row;align-items:center;justify-content:center;position:relative}.mgt2 .characteristic-minmax{display:flex;flex-direction:row;align-items:center;justify-content:center;flex-wrap:nowrap}.mgt2 .characteristic-dm span.label{font-size:.8rem;font-weight:600}.mgt2 .characteristic-label{font-family:"Barlow Condensed",sans-serif;font-size:1.2rem;font-weight:600;font-style:italic;text-align:center;color:var(--mgt2-color-form);position:relative}.mgt2 .characteristic-label>a.roll{color:#000;position:absolute;left:0}.mgt2 .characteristic-label a.cfg-characteristic{display:none;font-size:12px;position:absolute;right:0;top:0}.mgt2 .characteristic-label:hover a.cfg-characteristic{display:block}.mgt2 .characteristic-input{color:var(--mgt2-bgcolor-primary);text-align:center;font-size:1.5rem;font-weight:500;width:2.4rem;height:2rem;box-sizing:border-box;border:none;outline:none;background:linear-gradient(45deg, rgba(0, 0, 0, 0) 5.66px, #000 0 7.66px, rgba(0, 0, 0, 0) 0 calc(100% - 5.66px - 2px), #000 0 calc(100% - 5.66px), rgba(0, 0, 0, 0) 0),linear-gradient(-45deg, rgba(0, 0, 0, 0) 5.66px, #000 0 7.66px, rgba(0, 0, 0, 0) 0 calc(100% - 5.66px - 2px), #000 0 calc(100% - 5.66px), rgba(0, 0, 0, 0) 0),linear-gradient(90deg, #000 4px, rgba(0, 0, 0, 0) 0) -2px 50%/100% calc(100% - 16px) repeat-x,linear-gradient(#000 4px, rgba(0, 0, 0, 0) 0) 50% -2px/calc(100% - 16px) 100% repeat-y}.mgt2 .characteristic-dm{color:var(--mgt2-color-dm);background-color:rgba(0,0,0,0);text-align:center;font-size:1rem;width:1.5rem;height:1.4rem;padding:0;outline:none;border:none;margin:0;position:absolute;right:0;background-color:var(--mgt2-bgcolor-dm);border-radius:9px;margin-right:2px}.mgt2 .characteristic-dm:focus{outline:none;box-shadow:none}.mgt2 .characteristic-dm-minmax:focus{outline:none;box-shadow:none}.mgt2 .minmaxwrapper{display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:center;justify-content:center;align-items:center;margin:0 .5rem;box-sizing:border-box;background:linear-gradient(45deg, rgba(0, 0, 0, 0) 7.07px, #000 0 9.07px, rgba(0, 0, 0, 0) 0 calc(100% - 7.07px - 2px), #000 0 calc(100% - 7.07px), rgba(0, 0, 0, 0) 0),linear-gradient(-45deg, rgba(0, 0, 0, 0) 7.07px, #000 0 9.07px, rgba(0, 0, 0, 0) 0 calc(100% - 7.07px - 2px), #000 0 calc(100% - 7.07px), rgba(0, 0, 0, 0) 0),linear-gradient(90deg, #000 4px, rgba(0, 0, 0, 0) 0) -2px 50%/100% calc(100% - 20px) repeat-x,linear-gradient(#000 4px, rgba(0, 0, 0, 0) 0) 50% -2px/calc(100% - 20px) 100% repeat-y}.mgt2 .minmaxwrapper input{display:inline-block;color:#000;background-color:rgba(0,0,0,0);text-align:center;font-size:1.5rem;width:3rem;height:2rem;border:none;outline:none}.mgt2 .minmaxwrapper input:focus{outline:none;box-shadow:none}.mgt2 .minmaxwrapper input:first-child{margin-left:5px}.mgt2 .minmaxwrapper input:last-child{margin-right:5px}.mgt2 .minmaxwrapper span{font-size:1.5rem;font-weight:500}.computer-overload,.computer-overload i{color:var(--mgt2-color-warning) !important}ul.softwares{list-style:none;margin:0;padding:0}ul.softwares li{display:inline-block;color:var(--mgt2-color-software);background-color:var(--mgt2-bgcolor-software);padding:3px 7px;border-radius:8px}ul.softwares li a{display:none}ul.softwares li a:first-child{margin:0 .5rem}ul.softwares li:hover a{display:inline-block}.character-header{display:flex;margin-top:8px;margin-right:8px;flex-direction:row;flex-wrap:nowrap;flex-grow:0;flex-shrink:0;justify-content:flex-start;align-items:flex-start}.character-header-img{flex-basis:138px;flex-grow:0;flex-shrink:0;text-align:center}.character-summary{flex:0 0 100%;margin:0;padding:0;list-style:none;border-top:5px double var(--mgt2-bgcolor-primary)}.character-summary li{float:left;margin:0;padding:0;color:var(--mgt2-color-form)}.character-summary input{display:block;border:none;font-weight:bold;font-family:"Roboto Condensed",sans-serif;background-color:#fff;color:var(--mgt2-color-form);font-size:.8rem;border:1px solid #fff}.character-summary input:hover{border:1px solid #111}.character-header-body{display:flex;flex-direction:column;flex-wrap:nowrap;justify-content:flex-start}.character-header-body legend{font-size:.7rem;text-transform:uppercase;text-wrap:nowrap;color:var(--mgt2-color-form)}.character-header-body legend i{margin-right:.25rem}.character-body{display:flex;flex-direction:row;align-content:flex-start;flex-wrap:nowrap;min-height:330px}.character-body .tab{width:100%}.lifes{height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center}.lifes div{font-size:2rem}.character-states{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;justify-content:flex-start;align-items:flex-start;width:100%;float:right}.character-states li{display:flex;margin:0;padding:0;color:var(--mgt2-color-form);justify-content:space-between;align-items:center;width:100%;font-size:.7rem;line-height:1.1rem}.encumbrance-normal{color:var(--mgt2-encumbrance-normal) !important}.encumbrance-heavy{color:var(--mgt2-encumbrance-heavy) !important;font-weight:bold}.character-body{height:100%;overflow:hidden;display:flex;flex-direction:row;width:100%;justify-content:flex-start;align-items:flex-start;border-top:3px solid #000}.actor-footer{bottom:0;color:var(--mgt2-color-primary);background-color:var(--mgt2-bgcolor-primary);width:100%;margin:0 -8px;height:1.5rem;justify-content:space-between;align-items:center;padding:0 1rem;flex-grow:0;flex-shrink:0;display:flex;flex-direction:row}.mgt2.character .tab[data-tab=notes] .editor,.mgt2.character .tab[data-tab=notes] .editor-content,.mgt2.character .tab[data-tab=notes] prose-mirror,.mgt2.character .tab[data-tab=biography] .editor,.mgt2.character .tab[data-tab=biography] .editor-content,.mgt2.character .tab[data-tab=biography] prose-mirror,.mgt2.character .tab[data-tab=finance] .editor,.mgt2.character .tab[data-tab=finance] .editor-content,.mgt2.character .tab[data-tab=finance] prose-mirror{min-height:300px !important;height:auto !important}.itemsheet{display:flex !important;flex-direction:column !important;height:100% !important;background:#fff !important;overflow:hidden !important}.item-type-bar{background:#0a0405 !important;border-bottom:3px solid #ee4050 !important;padding:4px 12px !important;display:flex !important;align-items:center !important;gap:8px !important;min-height:0 !important;flex-shrink:0 !important}.item-type-bar .item-type-label{color:#ee4050 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.65rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:2px !important}.item-sheet-header{background:#0a0405 !important;padding:10px 14px !important;display:flex !important;align-items:center !important;gap:12px !important;flex-shrink:0 !important}.item-sheet-header .item-header-img{width:64px !important;height:64px !important;object-fit:cover !important;border:2px solid #ee4050 !important;border-radius:4px !important;cursor:pointer !important;flex-shrink:0 !important}.item-sheet-header .item-header-name{flex:1 !important;background:rgba(0,0,0,0) !important;border:none !important;border-bottom:1px solid rgba(238,64,80,.4) !important;color:#fff !important;font-family:"Barlow Condensed",sans-serif !important;font-size:1.6rem !important;font-weight:800 !important;text-transform:uppercase !important;letter-spacing:1px !important;padding:2px 0 !important;line-height:1.1 !important;width:100% !important}.item-sheet-header .item-header-name:focus{outline:none !important;border-bottom-color:#ee4050 !important}.item-sheet-header .item-header-name::placeholder{color:hsla(0,0%,100%,.35) !important}.item-stats-bar{background:#f5eeee !important;border-bottom:1px solid #ddc8c8 !important;padding:6px 14px !important;display:flex !important;flex-wrap:wrap !important;gap:6px !important;flex-shrink:0 !important}.item-stat-pill{display:flex !important;flex-direction:column !important;align-items:center !important;background:#fff !important;border:1px solid #ddc8c8 !important;border-radius:4px !important;padding:3px 10px !important;min-width:56px !important}.item-stat-pill .stat-label{color:#644 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.6rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1.5px !important;line-height:1.2 !important}.item-stat-pill .stat-value{color:#0a0405 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:1rem !important;font-weight:800 !important;line-height:1.1 !important}.item-stat-pill input,.item-stat-pill select{color:#0a0405 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:1rem !important;font-weight:800 !important;background:rgba(0,0,0,0) !important;border:none !important;text-align:center !important;width:100% !important;padding:0 !important;line-height:1.1 !important}.item-stat-pill input:focus,.item-stat-pill select:focus{outline:none !important;border-bottom:1px solid #ee4050 !important}.item-stat-pill-checkbox{display:flex !important;flex-direction:row !important;align-items:center !important;gap:5px !important;background:#fff !important;border:1px solid #ddc8c8 !important;border-radius:4px !important;padding:4px 10px !important}.item-stat-pill-checkbox input[type=checkbox]{margin:0 !important;width:14px !important;height:14px !important;accent-color:#ee4050 !important}.item-stat-pill-checkbox label{color:#644 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.65rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1px !important;cursor:pointer !important}.itemsheet .horizontal-tabs.tabs{background:#f5eeee !important;border-bottom:2px solid #ddc8c8 !important;display:flex !important;flex-wrap:wrap !important;gap:0 !important;padding:0 10px !important;flex-shrink:0 !important}.itemsheet .horizontal-tabs.tabs .item.tab-select{color:#644 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.72rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1.5px !important;padding:6px 14px !important;border:none !important;border-bottom:2px solid rgba(0,0,0,0) !important;margin-bottom:-2px !important;background:rgba(0,0,0,0) !important;cursor:pointer !important;transition:color .15s,border-color .15s !important}.itemsheet .horizontal-tabs.tabs .item.tab-select:hover{color:#ee4050 !important}.itemsheet .horizontal-tabs.tabs .item.tab-select.active{color:#ee4050 !important;border-bottom-color:#ee4050 !important;background:rgba(0,0,0,0) !important}.itemsheet .tab-content-area{flex:1 !important;overflow-y:auto !important;padding:10px 14px !important;background:#fff !important}.itemsheet .tab[data-group]{display:none !important}.itemsheet .tab[data-group].active{display:block !important}.itemsheet .field-group{margin-bottom:8px !important}.itemsheet .field-group label{display:block !important;color:#644 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.68rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1px !important;margin-bottom:2px !important}.itemsheet .field-groups{display:flex !important;flex-wrap:wrap !important;gap:10px !important;align-items:flex-start !important}.itemsheet .field-groups .field-group{flex:1 !important;min-width:80px !important}.itemsheet input[type=text],.itemsheet input[type=number],.itemsheet select,.itemsheet textarea{background:#fdf8f8 !important;border:1px solid #ddc8c8 !important;border-radius:3px !important;color:#0a0405 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.85rem !important;padding:4px 8px !important;width:100% !important}.itemsheet input[type=text]:focus,.itemsheet input[type=number]:focus,.itemsheet select:focus,.itemsheet textarea:focus{outline:none !important;border-color:#ee4050 !important;box-shadow:0 0 0 2px rgba(238,64,80,.12) !important}.itemsheet textarea{resize:vertical !important;min-height:80px !important}.itemsheet .mgt2-checkbox{display:flex !important;align-items:center !important;gap:6px !important;color:#644 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.72rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1px !important}.itemsheet .mgt2-checkbox input[type=checkbox]{width:14px !important;height:14px !important;margin:0 !important;accent-color:#ee4050 !important}.itemsheet .table-container{border:1px solid #ddc8c8 !important;border-radius:4px !important;overflow:hidden !important;margin-top:8px !important}.itemsheet .table-row{display:flex !important;align-items:stretch !important;border-bottom:1px solid #e8dada !important}.itemsheet .table-row:last-child{border-bottom:none !important}.itemsheet .table-row.heading{background:#0a0405 !important;color:#ee4050 !important}.itemsheet .table-row.heading .row-item{color:#ee4050 !important;font-family:"Barlow Condensed",sans-serif !important;font-size:.68rem !important;font-weight:700 !important;text-transform:uppercase !important;letter-spacing:1px !important;padding:5px 8px !important}.itemsheet .table-row:not(.heading){background:#fff !important}.itemsheet .table-row:not(.heading):nth-child(even){background:#fdf8f8 !important}.itemsheet .table-row:not(.heading) .row-item{padding:4px 6px !important}.itemsheet .table-row:not(.heading) .row-item input,.itemsheet .table-row:not(.heading) .row-item textarea,.itemsheet .table-row:not(.heading) .row-item select{font-size:.8rem !important;padding:2px 6px !important}.itemsheet .row-item{flex:1 !important;border-right:1px solid #e8dada !important}.itemsheet .row-item:last-child{border-right:none !important}.itemsheet .row-item.row-item-left{justify-content:flex-start !important}.itemsheet .row-item.row-item-right{flex:0 0 auto !important;min-width:36px !important;display:flex !important;align-items:center !important;justify-content:center !important}.itemsheet .row-item.row-item-30{flex:0 0 30% !important}.itemsheet .item-controls{display:flex !important;align-items:center !important;justify-content:center !important;gap:6px !important}.itemsheet .item-controls a{color:#888 !important;cursor:pointer !important}.itemsheet .item-controls a:hover{color:#ee4050 !important}.itemsheet-header{display:none !important}.itemsheet-maincol{display:none !important}.itemsheet-panel{display:contents !important}.itemsheet .item-details-grid{display:grid !important;grid-template-columns:1fr 1fr !important;gap:4px 16px !important;align-items:start !important}.itemsheet .item-details-grid .table-container{grid-column:1/-1 !important;margin-top:10px !important}.itemsheet .field-row{display:flex !important;align-items:center !important;gap:8px !important;min-height:28px !important}.itemsheet .field-row label{flex:0 0 100px !important;min-width:0 !important;margin-bottom:0 !important;white-space:nowrap !important;overflow:hidden !important;text-overflow:ellipsis !important}.itemsheet .field-row input[type=text],.itemsheet .field-row input[type=number],.itemsheet .field-row select{flex:1 !important;width:auto !important;height:24px !important;padding:2px 6px !important}.itemsheet .field-row input.short{flex:0 0 56px !important;width:56px !important}.itemsheet .field-row .range-inputs{display:flex !important;gap:4px !important;flex:1 !important}.itemsheet .field-row .range-inputs input{flex:0 0 52px !important;width:52px !important}.itemsheet .field-row .range-inputs select{flex:1 !important}.itemsheet .field-row.full{grid-column:1/-1 !important}.itemsheet .field-row--check label{flex:unset !important;display:flex !important;align-items:center !important;gap:6px !important;cursor:pointer !important}.itemsheet .tab[data-tab=tab1] .editor,.itemsheet .tab[data-tab=tab1] .editor-container{min-height:200px !important}li.chat-message{background:#fff !important;border:1px solid #cbb !important;box-shadow:0 2px 8px rgba(0,0,0,.18) !important;color:#0a0405;padding:0 !important}li.chat-message .message-header{background:#0a0405;border-bottom:3px solid #ee4050;padding:4px 10px}li.chat-message .message-header .message-sender{color:#ee4050;font-family:"Barlow Condensed",sans-serif;font-weight:700;font-size:.75rem;text-transform:uppercase;letter-spacing:1.5px;margin:0}li.chat-message .message-header .message-timestamp{color:#888;font-size:.68rem}li.chat-message .message-header .message-delete i{color:#888}li.chat-message .message-header:hover .message-delete i{color:#ee4050}li.chat-message .message-content>.dice-roll{background:#fdf8f8;padding:6px 12px}li.chat-message .message-content>.dice-roll .dice-formula{background:#f5eeee;border:1px solid #ddc8c8;border-radius:3px;color:#644;font-size:.78rem;padding:2px 10px;text-align:center;font-family:"Barlow Condensed",sans-serif;display:inline-block;margin:0 auto 4px auto}li.chat-message .message-content>.dice-roll .dice-result{display:flex;flex-direction:column;align-items:center;gap:3px}li.chat-message .message-content>.dice-roll h4.dice-total{font-family:"Barlow Condensed",sans-serif;font-size:2.2rem !important;font-weight:900;color:#0a0405 !important;margin:2px 0;line-height:1;text-align:center;background:rgba(0,0,0,0) !important;width:100% !important;display:block !important}li.chat-message .message-content>.dice-roll .dice-tooltip .part-header{background:#f5eeee;padding:2px 8px;display:flex;justify-content:space-between}li.chat-message .message-content>.dice-roll .dice-tooltip .part-header .part-formula,li.chat-message .message-content>.dice-roll .dice-tooltip .part-header .part-total{color:#ee4050;font-weight:700;font-size:.78rem}li.chat-message .message-content>.dice-roll .dice-tooltip .dice-rolls{display:flex;flex-wrap:wrap;justify-content:center;gap:4px;padding:6px 8px;list-style:none;margin:0}li.chat-message .message-content>.dice-roll .dice-tooltip .roll.die{display:flex;align-items:center;justify-content:center;width:26px;height:26px;background:#f5eeee;border:1.5px solid #ddc8c8;border-radius:4px;color:#3a2020;font-weight:700;font-size:.9rem}.mgt2-chat-roll{font-family:"Barlow Condensed",sans-serif}.mgt2-chat-roll .mgt2-roll-header{background:#0a0405 !important;border-left:4px solid #ee4050 !important;padding:5px 10px 4px 10px !important}.mgt2-chat-roll .mgt2-roll-header .mgt2-roll-char-name{display:block;color:#fff;font-size:1.2rem;font-weight:800;text-transform:uppercase;letter-spacing:1px;line-height:1}.mgt2-chat-roll .mgt2-roll-header .mgt2-roll-meta{display:flex;align-items:center;gap:6px;margin-top:2px}.mgt2-chat-roll .mgt2-roll-header .mgt2-roll-type{color:#ee4050;font-size:.68rem;font-weight:700;text-transform:uppercase;letter-spacing:2px}.mgt2-chat-roll .mgt2-roll-header .mgt2-roll-sep{color:#888}.mgt2-chat-roll .mgt2-roll-header .mgt2-roll-difficulty{color:#bbb;font-size:.68rem;text-transform:uppercase;letter-spacing:1px}.mgt2-chat-roll .mgt2-roll-modifier{background:#f5eeee;border-bottom:1px solid #e8dada;padding:3px 14px;color:#644;font-size:.8rem}.mgt2-chat-roll .mgt2-roll-modifiers{display:flex;gap:6px;flex-wrap:wrap;background:#f5eeee;border-bottom:1px solid #e8dada;padding:3px 14px}.mgt2-chat-roll .mgt2-roll-modifiers .mgt2-roll-mod-tag{color:#644;font-size:.8rem}.mgt2-chat-roll .dice-roll{background:#fdf8f8;padding:4px 10px;cursor:pointer}.mgt2-chat-roll .dice-roll .dice-flavor{color:#888;font-size:.73rem;text-align:center;margin-bottom:3px}.mgt2-chat-roll .dice-roll .dice-result{display:flex;flex-direction:column;align-items:center;gap:3px}.mgt2-chat-roll .dice-roll .dice-formula{background:#f5eeee;border:1px solid #ddc8c8;border-radius:3px;color:#644;font-size:.78rem;padding:2px 14px;font-family:"DM Sans",sans-serif;text-align:center}.mgt2-chat-roll .dice-roll .dice-tooltip{width:100%}.mgt2-chat-roll .dice-roll .dice-tooltip .wrapper{background:rgba(0,0,0,0)}.mgt2-chat-roll .dice-roll .dice-tooltip .tooltip-part{background:#fdf8f8;border:1px solid #e8dada;border-radius:4px;margin-bottom:6px;overflow:hidden}.mgt2-chat-roll .dice-roll .dice-tooltip .part-header{background:#f5eeee;padding:3px 8px}.mgt2-chat-roll .dice-roll .dice-tooltip .part-header .part-formula,.mgt2-chat-roll .dice-roll .dice-tooltip .part-header .part-total{color:#ee4050;font-weight:700;font-size:.8rem}.mgt2-chat-roll .dice-roll .dice-tooltip .dice-rolls{display:flex;flex-wrap:wrap;justify-content:center;gap:5px;padding:8px 10px;list-style:none;margin:0}.mgt2-chat-roll .dice-roll .dice-tooltip .roll.die{display:flex;align-items:center;justify-content:center;width:30px;height:30px;background:#f5eeee;border:1.5px solid #ddc8c8;border-radius:5px;color:#3a2020;font-weight:700;font-size:1rem;font-family:"Barlow Condensed",sans-serif}.mgt2-chat-roll .dice-roll .dice-tooltip .roll.die.max{border-color:#ee4050;color:#ee4050;background:#fde8ea;box-shadow:0 0 8px rgba(238,64,80,.2)}.mgt2-chat-roll .dice-roll .dice-tooltip .roll.die.min{border-color:#cbb;color:#999}.mgt2-chat-roll .dice-roll h4.dice-total{font-size:1.6rem !important;font-weight:900;color:#0a0405 !important;margin:3px 0 2px 0;line-height:1;font-family:"Barlow Condensed",sans-serif;text-align:center;text-shadow:none;background:#f5eeee !important;border:1px solid #ddc8c8 !important;border-radius:4px !important;padding:2px 14px !important;width:auto !important;display:inline-block !important;min-width:60px}.mgt2-chat-roll .dice-roll h4.dice-total.success{color:#1a8840 !important;background:rgba(82,232,122,.1) !important;border-color:rgba(26,136,64,.35) !important}.mgt2-chat-roll .dice-roll h4.dice-total.failure{color:#ee4050 !important;background:rgba(238,64,80,.07) !important;border-color:rgba(238,64,80,.3) !important}.mgt2-chat-roll .mgt2-outcome{text-align:center;font-size:.75rem;font-weight:700;text-transform:uppercase;letter-spacing:2px;padding:3px 10px}.mgt2-chat-roll .mgt2-outcome i{margin-right:5px}.mgt2-chat-roll .mgt2-outcome.is-success{background:rgba(26,136,64,.08);color:#1a8840;border-top:1px solid rgba(26,136,64,.2)}.mgt2-chat-roll .mgt2-outcome.is-failure{background:rgba(238,64,80,.07);color:#ee4050;border-top:1px solid rgba(238,64,80,.2)}.mgt2-chat-roll .mgt2-effect{text-align:center;font-size:.72rem;font-weight:600;letter-spacing:1.5px;text-transform:uppercase;padding:2px 10px 4px 10px;border-bottom:2px solid rgba(0,0,0,0)}.mgt2-chat-roll .mgt2-effect .mgt2-effect-value{font-size:1rem;font-weight:900;margin-left:4px}.mgt2-chat-roll .mgt2-effect .mgt2-healing-amount{font-size:.75rem;font-weight:600;margin-left:6px;opacity:.85}.mgt2-chat-roll .mgt2-effect.is-success{color:#1a8840;border-bottom-color:rgba(26,136,64,.25)}.mgt2-chat-roll .mgt2-effect.is-success .mgt2-effect-value{color:#1a8840}.mgt2-chat-roll .mgt2-effect.is-failure{color:#ee4050;border-bottom-color:rgba(238,64,80,.25)}.mgt2-chat-roll .mgt2-effect.is-failure .mgt2-effect-value{color:#ee4050}.mgt2-chat-roll .mgt2-buttons{display:flex;justify-content:center;flex-wrap:wrap;gap:4px;padding:5px 10px;background:#f5eeee;border-top:1px solid #ddc8c8}.mgt2-chat-roll .mgt2-buttons button{background:#fff;border:1px solid #cbb;color:#3a2020;border-radius:3px;padding:4px 14px;font-family:"Barlow Condensed",sans-serif;font-size:.78rem;font-weight:700;text-transform:uppercase;letter-spacing:1px;cursor:pointer;transition:background .15s ease,box-shadow .15s ease;box-shadow:none}.mgt2-chat-roll .mgt2-buttons button i{font-size:1rem;padding:0;margin:0}.mgt2-chat-roll .mgt2-buttons button:hover{background:#ee4050;border-color:#ee4050;color:#fff;box-shadow:0 0 8px rgba(238,64,80,.25)}.mgt2 nav.horizontal-tabs{color:var(--mgt2-color-primary);background:var(--mgt2-bgcolor-primary);font-style:normal;font-weight:700;font-size:14px;line-height:30px;text-transform:uppercase;justify-content:space-around;align-items:center;font-family:"Roboto Condensed",sans-serif}.mgt2 nav.horizontal-tabs a.item{position:relative;flex:1 1 auto}.mgt2 nav.horizontal-tabs a.item i{margin-right:.5rem}.mgt2 nav.horizontal-tabs>a.item::after{content:"";position:absolute;inset:.25rem .25rem .25rem .25rem;border:1px solid var(--mgt2-color-primary-active);pointer-events:none}.mgt2 nav.horizontal-tabs>a.item.active::after{border-bottom:none;border-top:2px solid var(--mgt2-color-primary-active);border-left:2px solid var(--mgt2-color-primary-active);border-right:2px solid var(--mgt2-color-primary-active);inset:.25rem .25rem 0 .25rem}.mgt2 nav.horizontal-tabs .active{color:var(--mgt2-color-primary);text-decoration:none;text-shadow:none;border-bottom:none}.tab[data-tab].fullsize{height:calc(100% - 3rem)}.subTab{flex-flow:column;height:100%;display:flex;justify-content:flex-start;align-items:stretch}.tab-scroll{overflow-y:auto;height:100%}.subTabs{height:100%;flex-direction:column}.subTabs.active{display:flex !important}.mgt2.character,.mgt2.creature,.mgt2.vehicule{overflow:visible !important}.mgt2.character>.window-content,.mgt2.creature>.window-content,.mgt2.vehicule>.window-content{overflow:visible !important}.mgt2.character .editable,.mgt2.character .locked,.mgt2.creature .editable,.mgt2.creature .locked,.mgt2.vehicule .editable,.mgt2.vehicule .locked{overflow:visible !important}.mgt2.character .character-body{position:relative !important;overflow:visible !important}.mgt2.creature .creature-body{position:relative !important;overflow:visible !important}.mgt2.vehicule .vehicule-content{position:relative !important;overflow:visible !important}.mgt2 nav.sheet-sidebar.tabs{position:absolute !important;left:100% !important;top:0 !important;width:62px !important;flex:none !important;display:flex !important;flex-direction:column;background:linear-gradient(180deg, #1e0507 0%, #110304 40%, #0a0202 100%);border-top:1px solid rgba(238,64,80,.35);border-right:1px solid rgba(238,64,80,.25);border-bottom:1px solid rgba(238,64,80,.2);border-left:3px solid var(--mgt2-color-primary);border-radius:0 10px 10px 0;box-shadow:6px 0 24px rgba(0,0,0,.75),0 0 0 0 rgba(0,0,0,0),inset 1px 0 16px rgba(238,64,80,.05);z-index:10;overflow:hidden !important;padding:2px 0}.mgt2 nav.sheet-sidebar.tabs>.item{position:relative;display:flex !important;flex-direction:column !important;justify-content:center !important;align-items:center !important;gap:4px !important;min-height:54px;padding:8px 4px;color:rgba(238,64,80,.45);border-bottom:1px solid rgba(238,64,80,.07);cursor:pointer;transition:background 180ms ease,color 180ms ease,box-shadow 180ms ease;user-select:none;text-decoration:none !important}.mgt2 nav.sheet-sidebar.tabs>.item::before{content:"";position:absolute;left:-3px;top:18%;bottom:18%;width:3px;background:rgba(0,0,0,0);border-radius:0 3px 3px 0;transition:background 180ms ease,top 180ms ease,bottom 180ms ease,box-shadow 180ms ease}.mgt2 nav.sheet-sidebar.tabs>.item:hover{color:var(--mgt2-color-primary);background:rgba(238,64,80,.07)}.mgt2 nav.sheet-sidebar.tabs>.item:hover::before{background:rgba(238,64,80,.5)}.mgt2 nav.sheet-sidebar.tabs>.item:hover .tab-label{color:rgba(238,64,80,.7)}.mgt2 nav.sheet-sidebar.tabs>.item.active{color:var(--mgt2-color-primary);background:linear-gradient(90deg, rgba(238, 64, 80, 0.16) 0%, rgba(238, 64, 80, 0.03) 100%);box-shadow:inset 0 1px 0 rgba(238,64,80,.12),inset 0 -1px 0 rgba(238,64,80,.08)}.mgt2 nav.sheet-sidebar.tabs>.item.active::before{background:var(--mgt2-color-primary);top:10%;bottom:10%;box-shadow:0 0 10px rgba(238,64,80,.7),0 0 20px rgba(238,64,80,.3)}.mgt2 nav.sheet-sidebar.tabs>.item.active i{filter:drop-shadow(0 0 5px rgba(238, 64, 80, 0.55))}.mgt2 nav.sheet-sidebar.tabs>.item.active .tab-label{color:rgba(238,64,80,.85)}.mgt2 nav.sheet-sidebar.tabs>.item i{font-size:1.15rem;pointer-events:none;line-height:1}.mgt2 nav.sheet-sidebar.tabs>.item .tab-label{font-family:"Barlow Condensed",sans-serif;font-size:.52rem;font-weight:700;text-transform:uppercase;letter-spacing:.8px;color:rgba(238,64,80,.3);line-height:1;pointer-events:none;transition:color 180ms ease}.container-controls{display:inline-block;margin-left:1rem}.container-controls a:not(:last-child){margin-right:.5rem}.table-container{display:flex;flex-flow:column nowrap;width:100%;margin:0 auto}.table-row{display:flex;flex-flow:row nowrap;width:100%;position:relative;align-items:flex-start}.table-row.heading{background-color:var(--mgt2-bgcolor-primary);align-items:center}.table-row.heading .row-item{text-transform:uppercase;font-size:12px}.table-row.heading .row-item:first-child{font-weight:bold;font-size:13px;letter-spacing:3px}.table-row.heading .row-item:first-child i{margin-right:.5rem}.table-row.heading.color-1 .row-item{background-color:var(--mgt2-bgcolor-primary);color:var(--mgt2-color-primary)}.table-row.heading.color-2 .row-item{background-color:var(--mgt2-bgcolor-form);color:var(--mgt2-bgcolor-primary)}.table-row.heading div.row-item{padding-left:5px}.table-row.heading div.row-item:last-child{padding-right:5px}.table-row:hover:not(.heading){background-color:var(--mgt2-row-hover)}.table-row-mb-4{margin-bottom:4px}.row-item{display:flex;flex-grow:1;font-size:14px;line-height:25px;align-items:center;transition:all .15s ease-in-out;overflow:hidden !important;text-overflow:ellipsis;text-wrap:nowrap}.row-item.item-controls{justify-content:right;padding-right:4px}.row-item.item-controls a:not(:last-child){margin-right:.4rem}.row-item i{color:var(--mgt2-color-form)}.row-item a[data-roll]{margin-right:.5rem}.heading.color-1 .row-item i{color:var(--mgt2-color-primary) !important}.heading.color-2 .row-item i{color:var(--mgt2-bgcolor-primary) !important}.table-subrow{border-left:2px var(--mgt2-subrow-color) dashed;color:var(--mgt2-subrow-color)}.table-subrow .row-item{font-size:.8em;line-height:20px}.table-subrow .row-item:first-child{padding-left:1rem}.table-subrow .row-item>i{margin-right:4px}.row-item-center{justify-content:center;text-align:center}.row-item-left{justify-content:left}.row-item-right{justify-content:right}.row-item-space-between{justify-content:space-between}.row-item-2{flex-basis:4rem}.row-item-5{flex-basis:5%}.row-item-10{flex-basis:10%}.row-item-12{flex-basis:4rem}.row-item-15{flex-basis:5rem}.row-item-20{flex-basis:20%}.row-item-25{flex-basis:25%}.row-item-30{flex-basis:30%}.row-item-35{flex-basis:35%}.row-item-40{flex-basis:40%}.row-item-45{flex-basis:45%}.row-item-50{flex-basis:50%}.row-item-65{flex-basis:50%}.row-item-85{flex-basis:50%}.row-item-storage{flex-wrap:wrap;flex-grow:0;flex-basis:20%;font-size:.7rem;line-height:.8rem}.item-control.item-equip i{color:var(--mgt2-row-inactive-icon)}.item-control.item-equip.active i{color:var(--mgt2-color-form)}.row-description{flex-basis:100%;font-size:14px;padding:4px 0;justify-content:left;transition:all .15s ease-in-out}.row-sub-container{display:flex;flex-flow:column nowrap;flex:1}.row-sub-container .row-item{padding:8px 0;border-bottom:1px solid var(--mgt2-bgcolor-primary)}.table-row:last-child,.row-sub-container .row-item:last-child{border-bottom:0}.table-container.editable .table-row{margin-top:4px}.table-container.editable .table-row:last-child{margin-bottom:4px}.item-options{position:absolute;top:.7rem;font-size:.7em;left:1.6rem;text-transform:uppercase;font-family:"DM Sans",sans-serif;font-optical-sizing:auto;font-weight:600;font-style:normal;color:var(--mgt2-subrow-color)}.creature-sheet .creature-header{display:flex;flex-direction:row;align-items:flex-start;gap:.75rem;padding:.5rem .75rem .5rem;background:var(--mgt2-bgcolor-form);border-bottom:2px solid var(--mgt2-color-primary)}.creature-sheet .creature-header-img{flex:0 0 80px}.creature-sheet .creature-header-img img.profile{width:80px;height:80px;object-fit:cover;border:2px solid var(--mgt2-color-primary);border-radius:4px;cursor:pointer}.creature-sheet .creature-header-body{flex:1;display:flex;flex-direction:column;gap:.4rem}.creature-sheet .creature-name{font-family:"Barlow Condensed",sans-serif;font-size:1.6rem;font-weight:700;font-style:italic;color:var(--mgt2-color-form);background:rgba(0,0,0,0);border:none;border-bottom:1px solid var(--mgt2-color-primary);width:100%;padding:0}.creature-sheet .creature-name:focus{outline:none;border-bottom-color:var(--mgt2-color-secondary)}.creature-sheet .creature-stats-row{display:flex;flex-direction:row;flex-wrap:wrap;gap:.5rem}.creature-sheet .creature-stat{display:flex;flex-direction:column;align-items:center;background:var(--mgt2-bgcolor-primary);border:1px solid var(--mgt2-color-primary);border-radius:4px;padding:2px 6px;min-width:4rem}.creature-sheet .creature-stat label{font-family:"Barlow Condensed",sans-serif;font-size:.7rem;font-weight:700;text-transform:uppercase;color:var(--mgt2-color-primary);line-height:1.2}.creature-sheet .creature-stat .creature-stat-value{display:flex;align-items:center;gap:2px}.creature-sheet .creature-stat .creature-stat-value input{width:2.5rem;text-align:center;background:rgba(0,0,0,0);border:none;color:var(--mgt2-bgcolor-form);font-size:1rem;font-weight:700;padding:0}.creature-sheet .creature-stat .creature-stat-value input:focus{outline:none;border-bottom:1px solid var(--mgt2-color-primary)}.creature-sheet .creature-stat .creature-stat-value .stat-max{width:2.5rem}.creature-sheet .creature-stat .creature-stat-value .stat-unit{font-size:.7rem;color:var(--mgt2-bgcolor-form);opacity:.7}.creature-sheet .creature-stat .creature-stat-value .stat-readonly{font-size:1rem;font-weight:700;color:var(--mgt2-bgcolor-form);min-width:2.5rem;text-align:center}.creature-sheet .creature-behavior-row{display:flex;flex-direction:row;align-items:center;gap:.5rem;flex-wrap:nowrap}.creature-sheet .creature-behavior-row label{flex:0 0 auto;font-size:.75rem;text-transform:uppercase;color:var(--mgt2-color-primary);font-weight:700;white-space:nowrap}.creature-sheet .creature-behavior-row .behavior-select{flex:1 1 auto;min-width:0;background:var(--mgt2-bgcolor-form);color:var(--mgt2-color-form);border:1px solid var(--mgt2-color-primary);border-radius:3px;font-size:.85rem;padding:1px 4px}.creature-sheet .creature-behavior-row .behavior-sep{flex:0 0 auto;color:var(--mgt2-color-form);opacity:.5}.creature-sheet .creature-size-badge{flex:0 0 auto;white-space:nowrap;font-size:.75rem;font-style:italic;color:var(--mgt2-bgcolor-form);background:var(--mgt2-bgcolor-primary);border:1px solid var(--mgt2-color-primary);border-radius:3px;padding:1px 6px}.creature-sheet .creature-body{flex:1;overflow-y:auto;padding:.5rem .75rem;min-height:228px}.creature-sheet .creature-body .tab{display:none}.creature-sheet .creature-body .tab.active{display:block}.creature-sheet .creature-info-tab{display:flex;flex-direction:column;gap:.5rem}.creature-sheet .creature-description{width:100%;background:var(--mgt2-bgcolor-form);color:var(--mgt2-color-form);border:1px solid var(--mgt2-color-primary);border-radius:3px;padding:4px;resize:vertical;font-size:.9rem}.creature-sheet .creature-damage .damage-formula{font-family:"Barlow Condensed",sans-serif;font-weight:700;color:var(--mgt2-color-primary);font-size:1rem}.creature-sheet .trait-name{font-weight:600;color:var(--mgt2-color-form)}.creature-sheet .trait-value{font-style:italic;color:var(--mgt2-color-secondary)}.mgt2-creature-roll .mgt2-roll-header{display:flex;flex-direction:row;align-items:center;gap:.6rem}.mgt2-creature-roll .creature-chat-img{width:36px;height:36px;object-fit:cover;border:1px solid var(--mgt2-color-primary);border-radius:3px;flex:0 0 36px}.mgt2-creature-roll .mgt2-roll-header-text{flex:1}.mgt2.creature .table-container+.header{margin-top:8px}.mgt2.creature .tab[data-tab=info] .editor,.mgt2.creature .tab[data-tab=info] .editor-content,.mgt2.creature .tab[data-tab=info] prose-mirror{min-height:300px !important;height:auto !important}.vehicule-sheet .vehicule-header{display:flex;flex-direction:row;align-items:flex-start;gap:.75rem;padding:.5rem .75rem;background:var(--mgt2-bgcolor-form);border-bottom:2px solid var(--mgt2-color-primary);flex-shrink:0}.vehicule-sheet .vehicule-header-img{flex:0 0 90px}.vehicule-sheet .vehicule-header-img img.profile{width:90px;height:90px;object-fit:cover;border:2px solid var(--mgt2-color-primary);border-radius:4px;cursor:pointer}.vehicule-sheet .vehicule-header-body{flex:1;display:flex;flex-direction:column;gap:.4rem;min-width:0}.vehicule-sheet .vehicule-name{font-family:"Barlow Condensed",sans-serif;font-size:1.6rem;font-weight:700;font-style:italic;color:var(--mgt2-color-form);background:rgba(0,0,0,0);border:none;border-bottom:1px solid var(--mgt2-color-primary);width:100%;padding:0}.vehicule-sheet .vehicule-name:focus{outline:none;border-bottom-color:var(--mgt2-color-secondary)}.vehicule-sheet .vehicule-header-stats{display:flex;flex-direction:row;align-items:flex-start;gap:.75rem;flex-wrap:wrap}.vehicule-sheet .vehicule-stat-box{display:flex;flex-direction:column;align-items:center;background:var(--mgt2-bgcolor-primary);border:1px solid var(--mgt2-color-primary);border-radius:4px;padding:3px 8px;min-width:4rem}.vehicule-sheet .vehicule-stat-box label{font-family:"Barlow Condensed",sans-serif;font-size:.65rem;font-weight:700;text-transform:uppercase;color:var(--mgt2-color-primary);line-height:1.2;white-space:nowrap}.vehicule-sheet .vehicule-stat-value{display:flex;align-items:center;gap:2px}.vehicule-sheet .vehicule-stat-value span{color:var(--mgt2-color-primary);font-weight:700}.vehicule-sheet .vehicule-stat-value input[type=number]{width:2.8rem;text-align:center;background:rgba(0,0,0,0);border:none;color:var(--mgt2-color-form);font-family:"Rubik",monospace;font-size:1rem;font-weight:600;padding:0}.vehicule-sheet .vehicule-stat-value input[type=number]:focus{outline:none;border-bottom:1px solid var(--mgt2-color-secondary)}.vehicule-sheet .vehicule-hull{min-width:6rem}.vehicule-sheet .vehicule-hull .vehicule-stat-value input[type=number]{width:2.5rem}.vehicule-sheet .vehicule-armor-group{display:flex;flex-direction:column;gap:2px}.vehicule-sheet .vehicule-armor-label{font-family:"Barlow Condensed",sans-serif;font-size:.65rem;font-weight:700;text-transform:uppercase;color:var(--mgt2-color-primary);text-align:center}.vehicule-sheet .vehicule-armor-row{display:flex;flex-direction:row;gap:4px}.vehicule-sheet .vehicule-armor-box{min-width:3.5rem}.vehicule-sheet .vehicule-content{flex:1;display:flex;flex-direction:column;overflow:hidden;min-height:320px}.vehicule-sheet .vehicule-tab{flex:1;overflow-y:auto;padding:.75rem;display:none}.vehicule-sheet .vehicule-tab.active{display:block}.vehicule-sheet .vehicule-stats-grid{display:grid;grid-template-columns:1fr 1fr;gap:4px 12px}.vehicule-sheet .vehicule-field{display:flex;flex-direction:row;align-items:center;gap:8px;padding:3px 0;border-bottom:1px solid rgba(0,0,0,.08)}.vehicule-sheet .vehicule-field:last-child{border-bottom:none}.vehicule-sheet .vehicule-field label{font-family:"Barlow Condensed",sans-serif;font-size:.72rem;font-weight:700;text-transform:uppercase;color:var(--mgt2-color-primary);flex:0 0 120px;white-space:nowrap}.vehicule-sheet .vehicule-field input[type=number],.vehicule-sheet .vehicule-field select{flex:1;background:rgba(0,0,0,0);border:1px solid rgba(0,0,0,0);border-radius:3px;color:var(--mgt2-color-form);font-family:"Barlow Condensed",sans-serif;font-size:.9rem;padding:2px 4px}.vehicule-sheet .vehicule-field input[type=number]:focus,.vehicule-sheet .vehicule-field select:focus{outline:none;border-color:var(--mgt2-color-primary);background:hsla(0,0%,100%,.1)}.vehicule-sheet .vehicule-field input[type=number]{text-align:center;width:4rem}.vehicule-sheet .vehicule-field select{cursor:pointer}.mgt2.vehicule .vehicule-tab[data-tab=description] .editor,.mgt2.vehicule .vehicule-tab[data-tab=description] .editor-content,.mgt2.vehicule .vehicule-tab[data-tab=description] prose-mirror{min-height:300px !important;height:auto !important}
diff --git a/styles/mgt2.min.css.map b/styles/mgt2.min.css.map
index 2096246..2e5cad8 100644
--- a/styles/mgt2.min.css.map
+++ b/styles/mgt2.min.css.map
@@ -1 +1 @@
-{"version":3,"sourceRoot":"","sources":["../src/sass/utils/_typography.sass","../src/sass/utils/_colors.sass","../src/sass/utils/_global.sass","../src/sass/utils/_window.sass","../src/sass/utils/_flex.sass","../src/sass/components/_forms.sass","../src/sass/components/_dialog.sass","../src/sass/components/_character.sass","../src/sass/components/_item.sass","../src/sass/components/_chat-sidebar.sass","../src/sass/components/_tabs.sass","../src/sass/components/_tab-sidebar.sass","../src/sass/components/_tables.sass","../src/sass/components/_creature.sass"],"names":[],"mappings":"AAAQ,sMACA,qGACA,0HCGR,eACI,2BACA,0BACA,8BACA,qCACA,gCACA,oCACA,8BACA,sBACA,2BACA,4BACA,iCACA,4BACA,2BACA,8BACA,0BACA,6BACA,kCACA,mCACA,kCAEJ,QACI,2BACA,0BACA,8BACA,qCACA,gCACA,oCACA,8BACA,sBACA,2BACA,4BACA,iCACA,4BACA,2BACA,8BACA,0BACA,6BACA,kCAEJ,MACI,2BACA,0BACA,8BACA,qCACA,gCACA,oCACA,8BACA,sBACA,2BACA,4BACA,iCACA,4BACA,2BACA,8BACA,0BACA,6BACA,kCC9DJ,QACC,yBAED,OACC,UAED,OACC,UAED,OACC,UAED,OACC,UAED,OACC,UAED,MACC,YAED,MACC,WAGA,cACC,iBAED,aACC,WAED,YACC,kBAED,yBACC,eAED,YACC,gBCnCC,iCACC,gCACA,6CAED,4BACC,iBACA,yBAEF,4BACC,oCACA,6BACA,UAGF,uBACC,UCjBD,gBACC,uBACA,yBACD,qBACC,eACD,qBACC,eACD,qBACC,eACD,qBACC,eACD,qBACC,eACD,qBACC,eACD,qBACC,eCfA,qBACC,8BACA,2CACA,gCACA,eACA,kBAEF,0DAGC,aACA,gBAED,sBACC,qBACA,sBACA,uBACA,oBAED,cACC,gCACA,uCACA,eACA,0CACA,iBACA,iBACA,kBACA,iBACA,yBAED,oBACC,aACA,mBACA,iBACA,mBACA,8BAGA,yBACC,yBACA,gBACA,eACA,0CACA,yBAED,kBACC,2CACA,eACD,uBACC,2CACA,gCACA,eACA,YACA,gBACA,0CACA,oBACA,UACD,4BACC,2CACA,gCACA,YACA,eACA,gBACA,0CAEF,cACC,aAED,cACC,gBACA,2CACA,YAED,kBACC,kBACA,sBAGA,0BACC,aACA,mBACA,mBACA,gCACC,mBCpFA,qBACI,gCACA,wDAGR,kBACI,2BACA,iCACA,iDACA,6BACA,2BAEA,iCACI,8BACA,2CACA,6BACA,6BACA,+CACI,sBACA,qDACA,2BACA,0BACA,oCACA,8BAER,kCACI,2BACA,yBACA,qBAEA,mGACI,2BACA,kCAGJ,8CACI,wBACA,8BACA,oBACA,6BACA,yBACA,2CAEA,yDACI,8BAEJ,oDACI,yBACA,qDACA,2BACA,4BACA,oCACA,gCACA,0BACA,2BAEJ,qLACI,kBACA,2BACA,iCACA,yBACA,6BACA,4BACA,qDACA,2BACA,8CAEA,uMACI,gCACA,wBACA,0CAEJ,0MACI,2BACA,yBAGZ,0FACI,8BACA,oCACA,6BACA,6BACA,6BAEA,wGACI,yBACA,qDACA,2BACA,4BACA,oCACA,8BACA,yBACA,2BAGJ,kHACI,8BACA,6BACA,yBAEJ,sGACI,yBACA,kBAEJ,oIACI,gCACA,sBACA,uBAGZ,0FACI,8BACA,wCACA,6BACA,wBACA,mBACA,kCAEA,+GACI,kBACA,2BACA,2BACA,iCACA,yBACA,6BACA,4BACA,qDACA,4BACA,2BACA,oCACA,gCACA,0BACA,qCAEA,iIACI,8BACA,gCACA,yBAGJ,kcACI,8BACA,gCACA,sBACA,oDAEA,wfACI,8BACA,qDCpJnB,4BACC,YAEF,SACC,eACA,uBACA,mBACA,WACC,kBAGD,uBACC,iBACA,YACA,cACA,kBAED,8BACC,gCACA,uCACA,8BACA,kBACA,eACA,iBACA,yBAED,0BACC,aACA,mBACA,mBACA,uBACA,kBAED,6BACC,aACA,mBACA,mBACA,uBACA,iBAIC,oCACC,gBACA,gBAEH,4BACC,0CACA,iBACA,gBACA,kBACA,kBACA,6BACA,kBAEC,mCACC,WACA,kBACA,OAED,iDACC,aACA,eACA,kBACA,QACA,MAGA,uDACC,cAEJ,4BACC,kCACA,kBACA,iBACA,gBACA,aACA,YACA,sBACA,YACA,aACA,2fAED,yBACC,2BACA,+BACA,kBACA,eACA,aACA,cACA,UACA,aACA,YACA,SACA,kBACA,QACA,wCACA,kBACA,iBACA,+BACC,aACA,gBAGD,sCACC,aACA,gBAEF,qBACC,aACA,mBACA,iBACA,uBACA,uBACA,mBACA,eACA,sBACA,2fACA,2BACC,qBACA,WACA,+BACA,kBACA,iBACA,WACA,YACA,YACA,aACA,iCACC,aACA,gBACD,uCACC,gBACD,sCACC,iBACF,0BACC,iBACA,gBACH,wCAEC,2CAEA,aACC,gBACA,SACA,UACA,gBACC,qBACA,iCACA,8CACA,gBACA,kBACA,kBACC,aACA,8BACC,eAED,wBACC,qBAEL,kBACC,aACA,eACA,iBACA,mBACA,iBACA,YACA,cACA,2BACA,uBACD,sBACC,iBACA,YACA,cACA,kBACD,mBACC,cACA,SACA,UACA,gBACA,kDACA,sBACC,WACA,SACA,UACA,6BACD,yBACC,cACA,YACA,iBACA,0CACA,sBACA,6BACA,gBACA,sBACA,+BACC,sBACH,uBACC,aACA,sBACA,iBACA,2BACA,8BACC,gBACA,yBACA,iBACA,6BACA,gCACC,oBACH,gBACC,aACA,mBACA,yBACA,iBACA,qBACC,WAGF,OACC,YACA,aACA,mBACA,uBACA,mBACA,WACC,eACF,kBACC,SACA,UACA,gBACA,aACA,sBACA,2BACA,uBACA,WACA,YACA,qBACC,aACA,SACA,UACA,6BACA,8BACA,mBACA,WACA,gBACA,mBAEF,oBACC,gDAED,mBACC,+CACA,iBAED,gBACC,YACA,gBACA,aACA,mBACA,WACA,2BACA,uBACA,0BAED,cACC,SACA,gCACA,6CACA,WACA,cACA,cACA,8BACA,mBACA,eACA,YACA,cACA,aACA,mBClRD,WACI,wBACA,iCACA,uBACA,2BACA,2BAGJ,eACI,8BACA,2CACA,4BACA,wBACA,8BACA,mBACA,wBACA,yBAEA,gCACI,yBACA,qDACA,4BACA,2BACA,oCACA,8BAGR,mBACI,8BACA,6BACA,wBACA,8BACA,oBACA,yBAEA,oCACI,sBACA,uBACA,4BACA,oCACA,6BACA,0BACA,yBAEJ,qCACI,kBACA,oCACA,uBACA,sDACA,sBACA,qDACA,4BACA,2BACA,oCACA,8BACA,yBACA,2BACA,sBAEA,2CACI,wBACA,uCAEJ,kDACI,qCAGZ,gBACI,8BACA,2CACA,4BACA,wBACA,0BACA,mBACA,yBAEJ,gBACI,wBACA,iCACA,8BACA,2BACA,oCACA,6BACA,4BACA,0BAEA,4BACI,sBACA,qDACA,2BACA,2BACA,oCACA,gCACA,2BAEJ,4BACI,yBACA,qDACA,0BACA,2BACA,2BAEJ,6CACI,yBACA,qDACA,0BACA,2BACA,oCACA,uBACA,6BACA,sBACA,qBACA,2BAEA,yDACI,wBACA,2CAEZ,yBACI,wBACA,8BACA,8BACA,mBACA,2BACA,oCACA,6BACA,4BAEA,8CACI,oBACA,sBACA,uBACA,gCAEJ,+BACI,sBACA,qDACA,4BACA,2BACA,oCACA,8BACA,0BAIJ,iCACI,8BACA,2CACA,wBACA,0BACA,iBACA,0BACA,yBAEA,kDACI,sBACA,qDACA,4BACA,2BACA,oCACA,gCACA,4BACA,uBACA,iDACA,8BACA,oCACA,0BACA,mDAEA,wDACI,yBAEJ,yDACI,yBACA,uCACA,oCAIZ,6BACI,kBACA,2BACA,6BACA,2BAEJ,4BACI,wBAEA,mCACI,yBAIR,wBACI,6BAEA,8BACI,yBACA,sBACA,qDACA,4BACA,2BACA,oCACA,8BACA,6BAER,yBACI,wBACA,0BACA,oBACA,kCAEA,sCACI,kBACA,0BAER,gGAII,8BACA,oCACA,6BACA,yBACA,qDACA,4BACA,2BACA,sBAEA,wHACI,wBACA,gCACA,oDAER,oBACI,2BACA,2BAEJ,0BACI,wBACA,8BACA,mBACA,sBACA,qDACA,4BACA,2BACA,oCACA,8BAEA,+CACI,sBACA,uBACA,oBACA,gCAIR,4BACI,oCACA,6BACA,2BACA,0BAEJ,sBACI,wBACA,+BACA,2CAEA,iCACI,8BAEJ,8BACI,8BACA,yBAEA,wCACI,yBACA,qDACA,4BACA,2BACA,oCACA,8BACA,2BAER,oCACI,2BAEA,oDACI,8BAEJ,8CACI,2BAEA,gKACI,2BACA,2BAEhB,qBACI,kBACA,0CAEA,gCACI,6BAEJ,mCACI,sCAEJ,oCACI,yBACA,0BACA,wBACA,8BACA,kCAEJ,iCACI,wBAER,0BACI,wBACA,8BACA,kCACA,mBAEA,4BACI,sBACA,0BAEA,kCACI,yBAIhB,kBACI,wBAEJ,mBACI,wBAEJ,iBACI,4BCpVJ,gBACI,2BACA,iCACA,gDACA,cACA,qBAEA,gCACI,mBACA,gCACA,iBAEA,gDACI,cACA,0CACA,gBACA,iBACA,yBACA,qBACA,SAEJ,mDACI,WACA,iBAEJ,kDACI,WAEJ,wDACI,cAGR,4CACI,mBACA,iBAEA,0DACI,mBACA,yBACA,kBACA,WACA,iBACA,iBACA,kBACA,0CACA,qBACA,uBAEJ,yDACI,aACA,sBACA,mBACA,QAEJ,0DACI,0CACA,4BACA,gBACA,yBACA,aACA,cACA,kBACA,oCACA,sBACA,yBAGA,uEACI,mBACA,gBACA,aACA,8BACA,wKACI,cACA,gBACA,iBACR,sEACI,aACA,eACA,uBACA,QACA,gBACA,gBACA,SACJ,oEACI,aACA,mBACA,uBACA,WACA,YACA,mBACA,2BACA,kBACA,cACA,gBACA,gBAIhB,gBACI,0CAGA,kCACI,8BACA,yCACA,qCAEA,uDACI,cACA,WACA,iBACA,gBACA,yBACA,mBACA,cAEJ,kDACI,aACA,mBACA,QACA,eAEJ,kDACI,cACA,iBACA,gBACA,yBACA,mBAEJ,iDACI,WAEJ,wDACI,WACA,iBACA,yBACA,mBAGR,oCACI,mBACA,gCACA,iBACA,WACA,gBAEJ,qCACI,aACA,QACA,eACA,mBACA,gCACA,iBAEA,wDACI,WACA,gBAGR,2BACI,mBACA,iBACA,eAEA,wCACI,WACA,iBACA,kBACA,kBAEJ,wCACI,aACA,sBACA,mBACA,QAEJ,yCACI,mBACA,yBACA,kBACA,WACA,iBACA,iBACA,iCACA,kBAGJ,yCACI,WAEA,kDACI,yBAEJ,uDACI,mBACA,yBACA,kBACA,kBACA,gBAEJ,sDACI,mBACA,gBAEA,sIACI,cACA,gBACA,gBAER,qDACI,aACA,eACA,uBACA,QACA,iBACA,gBACA,SAEJ,mDACI,aACA,mBACA,uBACA,WACA,YACA,mBACA,2BACA,kBACA,cACA,gBACA,eACA,0CAEA,uDACI,qBACA,cACA,mBACA,sCAEJ,uDACI,kBACA,WAGZ,yCACI,4BACA,gBACA,yBACA,mBACA,cACA,0CACA,kBACA,iBACA,8BACA,oCACA,6BACA,4BACA,sBACA,gCACA,eAEA,iDACI,yBACA,0CACA,4CAEJ,iDACI,yBACA,0CACA,2CAGZ,8BACI,kBACA,iBACA,gBACA,yBACA,mBACA,iBAEA,gCACI,iBAEJ,yCACI,+BACA,cACA,wCAEJ,yCACI,+BACA,cACA,wCAGR,8BACI,aACA,uBACA,eACA,QACA,iBACA,mBACA,6BAEA,qCACI,gBACA,sBACA,cACA,kBACA,iBACA,0CACA,iBACA,gBACA,yBACA,mBACA,eACA,qDACA,gBAEA,uCACI,eACA,UACA,SAEJ,2CACI,mBACA,qBACA,WACA,uCCxUd,0BACC,gCACA,uCACA,kBACA,gBACA,eACA,iBACA,yBACA,6BACA,mBACA,0CAEC,iCACC,kBACA,cACA,mCACC,mBAGD,wCACC,WACA,kBACA,kCACA,kDACA,oBAEA,+CACC,mBACA,sDACA,uDACA,wDACA,6BACJ,kCACC,gCACA,qBACA,iBACA,mBAGJ,wBACC,yBAED,QACC,iBACA,YACA,aACA,2BACA,oBACD,YACC,gBACA,YACD,SACC,YACA,sBACA,gBACC,wBCpDF,+BACI,4BACA,+DACI,4BACJ,kGACI,4BAER,gCACI,6BACA,4BAEJ,8BACI,6BACA,4BAIA,6BACI,6BACA,qBACA,iBACA,oBACA,sBACA,qBACA,wBACA,sBAEA,0EACA,yCACA,2CACA,2CACA,gDACA,4BACA,iGACA,WACA,2BACA,cAEA,mCACI,kBACA,wBACA,iCACA,kCACA,8BACA,mBACA,gBACA,gBACA,0BACA,4CACA,eACA,wEACA,iBACA,gCAGA,2CACI,WACA,kBACA,UACA,QACA,WACA,UACA,yBACA,0BACA,wFAEJ,yCACI,gCACA,+BACA,iDACI,8BACJ,oDACI,yBAER,0CACI,gCACA,4FACA,gFACA,kDACI,qCACA,QACA,WACA,mEACJ,4CACI,oDACJ,qDACI,0BAER,qCACI,kBACA,oBACA,cAEJ,8CACI,0CACA,iBACA,gBACA,yBACA,oBACA,yBACA,cACA,oBACA,4BC3GhB,oBACC,qBACA,iBAEC,uCACC,mBAEH,iBACC,aACA,wBACA,WACA,cACD,WACC,aACA,qBACA,WACA,kBACA,uBACA,mBACC,6CACA,mBACA,6BACC,yBACA,eACA,yCACC,iBACA,eACA,mBACA,2CACC,mBAEF,qCACC,6CACA,gCAED,qCACC,0CACA,kCAED,gCACC,iBACA,2CACC,kBAEH,+BACC,uCACH,gBACC,kBACD,UACC,aACA,YACA,eACA,iBACA,mBACA,gCACA,2BACA,uBACA,iBACA,wBACC,sBACA,kBAEC,2CACC,mBACH,YACC,6BACD,uBACC,mBAIC,6BACC,2CAGD,6BACC,6CACJ,cACC,gDACA,+BACA,wBACC,eACA,iBACA,oCACC,kBACD,0BACC,iBACH,iBACC,uBACA,kBACD,eACC,qBACD,gBACC,sBACD,wBACC,8BACD,YACC,gBACD,YACC,cACD,aACC,eACD,aACC,gBACD,aACC,gBACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,kBACC,eACA,YACA,eACA,gBACA,kBAGC,2BACC,oCAEA,kCACC,6BACJ,iBACC,gBACA,eACA,cACA,qBACA,gCACD,mBACC,aACA,wBACA,OACA,6BACC,cACA,oDACF,8DAEC,gBAGC,qCACC,eAGD,gDACC,kBACH,cACC,kBACA,UACA,eACA,YACA,yBACA,iCACA,yBACA,gBACA,kBACA,+BCpKC,iCACE,aACA,mBACA,uBACA,WACA,2BACA,oCACA,kDAEF,qCACE,cACA,iDACE,WACA,YACA,iBACA,2CACA,kBACA,eAEJ,sCACE,OACA,aACA,sBACA,UAEF,+BACE,0CACA,iBACA,gBACA,kBACA,6BACA,yBACA,YACA,kDACA,WACA,UACA,qCACE,aACA,gDAGJ,oCACE,aACA,mBACA,eACA,UAEF,+BACE,aACA,sBACA,mBACA,uCACA,2CACA,kBACA,gBACA,eAEA,qCACE,0CACA,gBACA,gBACA,yBACA,gCACA,gBAEF,oDACE,aACA,mBACA,QACA,0DACE,aACA,kBACA,yBACA,YACA,+BACA,eACA,gBACA,UACA,gEACE,aACA,kDACJ,8DACE,aACF,+DACE,gBACA,+BACA,WACF,mEACE,eACA,gBACA,+BACA,iBACA,kBAGN,uCACE,aACA,mBACA,mBACA,UACA,eAEA,6CACE,iBACA,yBACA,gCACA,gBAEF,wDACE,oCACA,6BACA,2CACA,kBACA,iBACA,gBAEF,qDACE,6BACA,WAEJ,qCACE,iBACA,iBACA,kBACA,kCACA,uCACA,6CACA,kBACA,gBAGF,+BACE,OACA,gBACA,qBAEA,oCACE,aACA,2CACE,cAGN,mCACE,aACA,sBACA,UAEF,sCACE,WACA,oCACA,6BACA,2CACA,kBACA,YACA,gBACA,gBAIA,iDACE,0CACA,gBACA,gCACA,eAEJ,4BACE,gBACA,6BAEF,6BACE,kBACA,kCAOF,sCACE,aACA,mBACA,mBACA,UAEF,uCACE,WACA,YACA,iBACA,2CACA,kBACA,cAEF,2CACE","file":"mgt2.min.css"}
\ No newline at end of file
+{"version":3,"sourceRoot":"","sources":["../src/sass/utils/_typography.sass","../src/sass/utils/_colors.sass","../src/sass/utils/_global.sass","../src/sass/utils/_window.sass","../src/sass/utils/_flex.sass","../src/sass/components/_forms.sass","../src/sass/components/_dialog.sass","../src/sass/components/_character.sass","../src/sass/components/_item.sass","../src/sass/components/_chat-sidebar.sass","../src/sass/components/_tabs.sass","../src/sass/components/_tab-sidebar.sass","../src/sass/components/_tables.sass","../src/sass/components/_creature.sass","../src/sass/components/_vehicule.sass"],"names":[],"mappings":"AAAQ,sMACA,qGACA,0HCGR,eACI,2BACA,0BACA,8BACA,qCACA,gCACA,oCACA,8BACA,sBACA,2BACA,4BACA,iCACA,4BACA,2BACA,8BACA,0BACA,6BACA,kCACA,mCACA,kCAEJ,QACI,2BACA,0BACA,8BACA,qCACA,gCACA,oCACA,8BACA,sBACA,2BACA,4BACA,iCACA,4BACA,2BACA,8BACA,0BACA,6BACA,kCAEJ,MACI,2BACA,0BACA,8BACA,qCACA,gCACA,oCACA,8BACA,sBACA,2BACA,4BACA,iCACA,4BACA,2BACA,8BACA,0BACA,6BACA,kCC9DJ,QACC,yBAED,OACC,UAED,OACC,UAED,OACC,UAED,OACC,UAED,OACC,UAED,MACC,YAED,MACC,WAGA,cACC,iBAED,aACC,WAED,YACC,kBAED,yBACC,eAED,YACC,gBCnCC,iCACC,gCACA,6CAED,4BACC,iBACA,yBAEF,4BACC,oCACA,6BACA,UAGF,uBACC,UCjBD,gBACC,uBACA,yBACD,qBACC,eACD,qBACC,eACD,qBACC,eACD,qBACC,eACD,qBACC,eACD,qBACC,eACD,qBACC,eCfA,qBACC,8BACA,2CACA,gCACA,eACA,kBAEF,0DAGC,aACA,gBAED,sBACC,qBACA,sBACA,uBACA,oBAED,cACC,gCACA,uCACA,eACA,0CACA,iBACA,iBACA,kBACA,iBACA,yBAED,oBACC,aACA,mBACA,iBACA,mBACA,8BAGA,yBACC,yBACA,gBACA,eACA,0CACA,yBAED,kBACC,2CACA,eACD,uBACC,2CACA,gCACA,eACA,YACA,gBACA,0CACA,oBACA,UACD,4BACC,2CACA,gCACA,YACA,eACA,gBACA,0CAEF,cACC,aAED,cACC,gBACA,2CACA,YAED,kBACC,kBACA,sBAGA,0BACC,aACA,mBACA,mBACA,gCACC,mBCpFA,qBACI,gCACA,wDAGR,kBACI,2BACA,iCACA,iDACA,6BACA,2BAEA,iCACI,8BACA,2CACA,6BACA,6BACA,+CACI,sBACA,qDACA,2BACA,0BACA,oCACA,8BAER,kCACI,2BACA,yBACA,qBAEA,mGACI,2BACA,gCAGJ,8CACI,wBACA,8BACA,mBACA,6BACA,yBACA,2CAEA,yDACI,8BAEJ,oDACI,yBACA,qDACA,2BACA,4BACA,oCACA,gCACA,0BACA,2BAEJ,qLACI,kBACA,2BACA,iCACA,yBACA,6BACA,2BACA,qDACA,2BACA,8CAEA,uMACI,gCACA,wBACA,0CAEJ,0MACI,2BACA,yBAGZ,0FACI,8BACA,oCACA,6BACA,4BACA,6BAEA,wGACI,yBACA,qDACA,2BACA,4BACA,oCACA,8BACA,yBACA,2BAGJ,kHACI,8BACA,6BACA,yBAEJ,sGACI,yBACA,kBAEJ,oIACI,gCACA,sBACA,uBAGZ,0FACI,8BACA,wCACA,4BACA,wBACA,mBACA,kCAEA,+GACI,kBACA,2BACA,2BACA,iCACA,yBACA,6BACA,4BACA,qDACA,4BACA,2BACA,oCACA,gCACA,0BACA,qCAEA,iIACI,8BACA,gCACA,yBAGJ,kcACI,8BACA,gCACA,sBACA,oDAEA,wfACI,8BACA,qDCpJnB,4BACC,YAEF,SACC,eACA,uBACA,mBACA,WACC,kBAGD,uBACC,iBACA,YACA,cACA,kBAED,8BACC,gCACA,uCACA,8BACA,kBACA,eACA,iBACA,yBAED,0BACC,aACA,mBACA,mBACA,uBACA,kBAED,6BACC,aACA,mBACA,mBACA,uBACA,iBAIC,oCACC,gBACA,gBAEH,4BACC,0CACA,iBACA,gBACA,kBACA,kBACA,6BACA,kBAEC,mCACC,WACA,kBACA,OAED,iDACC,aACA,eACA,kBACA,QACA,MAGA,uDACC,cAEJ,4BACC,kCACA,kBACA,iBACA,gBACA,aACA,YACA,sBACA,YACA,aACA,2fAED,yBACC,2BACA,+BACA,kBACA,eACA,aACA,cACA,UACA,aACA,YACA,SACA,kBACA,QACA,wCACA,kBACA,iBACA,+BACC,aACA,gBAGD,sCACC,aACA,gBAEF,qBACC,aACA,mBACA,iBACA,uBACA,uBACA,mBACA,eACA,sBACA,2fACA,2BACC,qBACA,WACA,+BACA,kBACA,iBACA,WACA,YACA,YACA,aACA,iCACC,aACA,gBACD,uCACC,gBACD,sCACC,iBACF,0BACC,iBACA,gBACH,wCAEC,2CAEA,aACC,gBACA,SACA,UACA,gBACC,qBACA,iCACA,8CACA,gBACA,kBACA,kBACC,aACA,8BACC,eAED,wBACC,qBAEL,kBACC,aACA,eACA,iBACA,mBACA,iBACA,YACA,cACA,2BACA,uBACD,sBACC,iBACA,YACA,cACA,kBACD,mBACC,cACA,SACA,UACA,gBACA,kDACA,sBACC,WACA,SACA,UACA,6BACD,yBACC,cACA,YACA,iBACA,0CACA,sBACA,6BACA,gBACA,sBACA,+BACC,sBACH,uBACC,aACA,sBACA,iBACA,2BACA,8BACC,gBACA,yBACA,iBACA,6BACA,gCACC,oBACH,gBACC,aACA,mBACA,yBACA,iBACA,qBACC,WAGF,OACC,YACA,aACA,mBACA,uBACA,mBACA,WACC,eACF,kBACC,SACA,UACA,gBACA,aACA,sBACA,2BACA,uBACA,WACA,YACA,qBACC,aACA,SACA,UACA,6BACA,8BACA,mBACA,WACA,gBACA,mBAEF,oBACC,gDAED,mBACC,+CACA,iBAED,gBACC,YACA,gBACA,aACA,mBACA,WACA,2BACA,uBACA,0BAED,cACC,SACA,gCACA,6CACA,WACA,cACA,cACA,8BACA,mBACA,eACA,YACA,cACA,aACA,mBAQC,8cAGC,4BACA,uBC9RH,WACI,wBACA,iCACA,uBACA,2BACA,2BAGJ,eACI,8BACA,2CACA,4BACA,wBACA,8BACA,mBACA,wBACA,yBAEA,gCACI,yBACA,qDACA,4BACA,2BACA,oCACA,8BAGR,mBACI,8BACA,6BACA,wBACA,8BACA,oBACA,yBAEA,oCACI,sBACA,uBACA,4BACA,oCACA,6BACA,0BACA,yBAEJ,qCACI,kBACA,oCACA,uBACA,sDACA,sBACA,qDACA,4BACA,2BACA,oCACA,8BACA,yBACA,2BACA,sBAEA,2CACI,wBACA,uCAEJ,kDACI,qCAGZ,gBACI,8BACA,2CACA,4BACA,wBACA,0BACA,mBACA,yBAEJ,gBACI,wBACA,iCACA,8BACA,2BACA,oCACA,6BACA,4BACA,0BAEA,4BACI,sBACA,qDACA,2BACA,2BACA,oCACA,gCACA,2BAEJ,4BACI,yBACA,qDACA,0BACA,2BACA,2BAEJ,6CACI,yBACA,qDACA,0BACA,2BACA,oCACA,uBACA,6BACA,sBACA,qBACA,2BAEA,yDACI,wBACA,2CAEZ,yBACI,wBACA,8BACA,8BACA,mBACA,2BACA,oCACA,6BACA,4BAEA,8CACI,oBACA,sBACA,uBACA,gCAEJ,+BACI,sBACA,qDACA,4BACA,2BACA,oCACA,8BACA,0BAIJ,iCACI,8BACA,2CACA,wBACA,0BACA,iBACA,0BACA,yBAEA,kDACI,sBACA,qDACA,4BACA,2BACA,oCACA,gCACA,4BACA,uBACA,iDACA,8BACA,oCACA,0BACA,mDAEA,wDACI,yBAEJ,yDACI,yBACA,uCACA,oCAIZ,6BACI,kBACA,2BACA,6BACA,2BAEJ,4BACI,wBAEA,mCACI,yBAIR,wBACI,6BAEA,8BACI,yBACA,sBACA,qDACA,4BACA,2BACA,oCACA,8BACA,6BAER,yBACI,wBACA,0BACA,oBACA,kCAEA,sCACI,kBACA,0BAER,gGAII,8BACA,oCACA,6BACA,yBACA,qDACA,4BACA,2BACA,sBAEA,wHACI,wBACA,gCACA,oDAER,oBACI,2BACA,2BAEJ,0BACI,wBACA,8BACA,mBACA,sBACA,qDACA,4BACA,2BACA,oCACA,8BAEA,+CACI,sBACA,uBACA,oBACA,gCAIR,4BACI,oCACA,6BACA,2BACA,0BAEJ,sBACI,wBACA,+BACA,2CAEA,iCACI,8BAEJ,8BACI,8BACA,yBAEA,wCACI,yBACA,qDACA,4BACA,2BACA,oCACA,8BACA,2BAER,oCACI,2BAEA,oDACI,8BAEJ,8CACI,2BAEA,gKACI,2BACA,2BAEhB,qBACI,kBACA,0CAEA,gCACI,6BAEJ,mCACI,sCAEJ,oCACI,yBACA,0BACA,wBACA,8BACA,kCAEJ,iCACI,wBAER,0BACI,wBACA,8BACA,kCACA,mBAEA,4BACI,sBACA,0BAEA,kCACI,yBAIhB,kBACI,wBAEJ,mBACI,wBAEJ,iBACI,4BAKA,8BACI,wBACA,yCACA,wBACA,6BAGA,+CACI,4BACA,2BAIR,sBACI,wBACA,8BACA,mBACA,2BAEA,4BACI,0BACA,uBACA,2BACA,8BACA,2BACA,kCAEJ,6GAGI,kBACA,sBACA,uBACA,2BAEJ,kCACI,yBACA,sBAEJ,oCACI,wBACA,mBACA,kBAEA,0CACI,yBACA,sBAEJ,2CACI,kBAGR,2BACI,4BAIJ,mCACI,sBACA,wBACA,8BACA,mBACA,0BAKJ,wFAEI,4BC9ZZ,gBACI,2BACA,iCACA,gDACA,cACA,qBAEA,gCACI,mBACA,gCACA,iBAEA,gDACI,cACA,0CACA,gBACA,iBACA,yBACA,qBACA,SAEJ,mDACI,WACA,iBAEJ,kDACI,WAEJ,wDACI,cAGR,4CACI,mBACA,iBAEA,0DACI,mBACA,yBACA,kBACA,WACA,iBACA,iBACA,kBACA,0CACA,qBACA,uBAEJ,yDACI,aACA,sBACA,mBACA,QAEJ,0DACI,0CACA,4BACA,gBACA,yBACA,aACA,cACA,kBACA,oCACA,sBACA,yBAGA,uEACI,mBACA,gBACA,aACA,8BACA,wKACI,cACA,gBACA,iBACR,sEACI,aACA,eACA,uBACA,QACA,gBACA,gBACA,SACJ,oEACI,aACA,mBACA,uBACA,WACA,YACA,mBACA,2BACA,kBACA,cACA,gBACA,gBAIhB,gBACI,0CAGA,kCACI,8BACA,yCACA,qCAEA,uDACI,cACA,WACA,iBACA,gBACA,yBACA,mBACA,cAEJ,kDACI,aACA,mBACA,QACA,eAEJ,kDACI,cACA,iBACA,gBACA,yBACA,mBAEJ,iDACI,WAEJ,wDACI,WACA,iBACA,yBACA,mBAGR,oCACI,mBACA,gCACA,iBACA,WACA,gBAEJ,qCACI,aACA,QACA,eACA,mBACA,gCACA,iBAEA,wDACI,WACA,gBAGR,2BACI,mBACA,iBACA,eAEA,wCACI,WACA,iBACA,kBACA,kBAEJ,wCACI,aACA,sBACA,mBACA,QAEJ,yCACI,mBACA,yBACA,kBACA,WACA,iBACA,iBACA,iCACA,kBAGJ,yCACI,WAEA,kDACI,yBAEJ,uDACI,mBACA,yBACA,kBACA,kBACA,gBAEJ,sDACI,mBACA,gBAEA,sIACI,cACA,gBACA,gBAER,qDACI,aACA,eACA,uBACA,QACA,iBACA,gBACA,SAEJ,mDACI,aACA,mBACA,uBACA,WACA,YACA,mBACA,2BACA,kBACA,cACA,gBACA,eACA,0CAEA,uDACI,qBACA,cACA,mBACA,sCAEJ,uDACI,kBACA,WAGZ,yCACI,4BACA,gBACA,yBACA,mBACA,cACA,0CACA,kBACA,iBACA,8BACA,oCACA,6BACA,4BACA,sBACA,gCACA,eAEA,iDACI,yBACA,0CACA,4CAEJ,iDACI,yBACA,0CACA,2CAGZ,8BACI,kBACA,iBACA,gBACA,yBACA,mBACA,iBAEA,gCACI,iBAEJ,yCACI,+BACA,cACA,wCAEJ,yCACI,+BACA,cACA,wCAGR,6BACI,kBACA,iBACA,gBACA,qBACA,yBACA,0BACA,sCAEA,gDACI,eACA,gBACA,gBAEJ,wCACI,cACA,wCAEA,2DACI,cAER,wCACI,cACA,wCAEA,2DACI,cAGZ,8BACI,aACA,uBACA,eACA,QACA,iBACA,mBACA,6BAEA,qCACI,gBACA,sBACA,cACA,kBACA,iBACA,0CACA,iBACA,gBACA,yBACA,mBACA,eACA,qDACA,gBAEA,uCACI,eACA,UACA,SAEJ,2CACI,mBACA,qBACA,WACA,uCCrWd,0BACC,gCACA,uCACA,kBACA,gBACA,eACA,iBACA,yBACA,6BACA,mBACA,0CAEC,iCACC,kBACA,cACA,mCACC,mBAGD,wCACC,WACA,kBACA,kCACA,kDACA,oBAEA,+CACC,mBACA,sDACA,uDACA,wDACA,6BACJ,kCACC,gCACA,qBACA,iBACA,mBAGJ,wBACC,yBAED,QACC,iBACA,YACA,aACA,2BACA,oBACD,YACC,gBACA,YACD,SACC,YACA,sBACA,gBACC,wBCpDF,8CACI,4BACA,8FACI,4BACJ,kJACI,4BAER,gCACI,6BACA,4BAEJ,8BACI,6BACA,4BAEJ,iCACI,6BACA,4BAIA,6BACI,6BACA,qBACA,iBACA,oBACA,sBACA,qBACA,wBACA,sBAEA,0EACA,yCACA,2CACA,2CACA,gDACA,4BACA,iGACA,WACA,2BACA,cAEA,mCACI,kBACA,wBACA,iCACA,kCACA,8BACA,mBACA,gBACA,gBACA,0BACA,4CACA,eACA,wEACA,iBACA,gCAGA,2CACI,WACA,kBACA,UACA,QACA,WACA,UACA,yBACA,0BACA,wFAEJ,yCACI,gCACA,+BACA,iDACI,8BACJ,oDACI,yBAER,0CACI,gCACA,4FACA,gFACA,kDACI,qCACA,QACA,WACA,mEACJ,4CACI,oDACJ,qDACI,0BAER,qCACI,kBACA,oBACA,cAEJ,8CACI,0CACA,iBACA,gBACA,yBACA,oBACA,yBACA,cACA,oBACA,4BC/GhB,oBACC,qBACA,iBAEC,uCACC,mBAEH,iBACC,aACA,wBACA,WACA,cACD,WACC,aACA,qBACA,WACA,kBACA,uBACA,mBACC,6CACA,mBACA,6BACC,yBACA,eACA,yCACC,iBACA,eACA,mBACA,2CACC,mBAEF,qCACC,6CACA,gCAED,qCACC,0CACA,kCAED,gCACC,iBACA,2CACC,kBAEH,+BACC,uCACH,gBACC,kBACD,UACC,aACA,YACA,eACA,iBACA,mBACA,gCACA,2BACA,uBACA,iBACA,wBACC,sBACA,kBAEC,2CACC,mBACH,YACC,6BACD,uBACC,mBAIC,6BACC,2CAGD,6BACC,6CACJ,cACC,gDACA,+BACA,wBACC,eACA,iBACA,oCACC,kBACD,0BACC,iBACH,iBACC,uBACA,kBACD,eACC,qBACD,gBACC,sBACD,wBACC,8BACD,YACC,gBACD,YACC,cACD,aACC,eACD,aACC,gBACD,aACC,gBACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,aACC,eACD,kBACC,eACA,YACA,eACA,gBACA,kBAGC,2BACC,oCAEA,kCACC,6BACJ,iBACC,gBACA,eACA,cACA,qBACA,gCACD,mBACC,aACA,wBACA,OACA,6BACC,cACA,oDACF,8DAEC,gBAGC,qCACC,eAGD,gDACC,kBACH,cACC,kBACA,UACA,eACA,YACA,yBACA,iCACA,yBACA,gBACA,kBACA,+BCpKC,iCACE,aACA,mBACA,uBACA,WACA,2BACA,oCACA,kDAEF,qCACE,cACA,iDACE,WACA,YACA,iBACA,2CACA,kBACA,eAEJ,sCACE,OACA,aACA,sBACA,UAEF,+BACE,0CACA,iBACA,gBACA,kBACA,6BACA,yBACA,YACA,kDACA,WACA,UACA,qCACE,aACA,gDAGJ,oCACE,aACA,mBACA,eACA,UAEF,+BACE,aACA,sBACA,mBACA,uCACA,2CACA,kBACA,gBACA,eAEA,qCACE,0CACA,gBACA,gBACA,yBACA,gCACA,gBAEF,oDACE,aACA,mBACA,QACA,0DACE,aACA,kBACA,yBACA,YACA,+BACA,eACA,gBACA,UACA,gEACE,aACA,kDACJ,8DACE,aACF,+DACE,gBACA,+BACA,WACF,mEACE,eACA,gBACA,+BACA,iBACA,kBAGN,uCACE,aACA,mBACA,mBACA,UACA,iBAEA,6CACE,cACA,iBACA,yBACA,gCACA,gBACA,mBAEF,wDACE,cACA,YACA,oCACA,6BACA,2CACA,kBACA,iBACA,gBAEF,qDACE,cACA,6BACA,WAEJ,qCACE,cACA,mBACA,iBACA,kBACA,+BACA,uCACA,2CACA,kBACA,gBAKF,+BACE,OACA,gBACA,qBACA,iBAEA,oCACE,aACA,2CACE,cAGN,mCACE,aACA,sBACA,UAEF,sCACE,WACA,oCACA,6BACA,2CACA,kBACA,YACA,gBACA,gBAIA,iDACE,0CACA,gBACA,gCACA,eAEJ,4BACE,gBACA,6BAEF,6BACE,kBACA,kCAOF,sCACE,aACA,mBACA,mBACA,UAEF,uCACE,WACA,YACA,iBACA,2CACA,kBACA,cAEF,2CACE,OAGF,6CACE,aACA,mBACA,8BACA,gBACA,eACA,uCACA,+CACA,2CAEA,kDACE,0CACA,iBACA,gBACA,gCACA,mBAEF,+CACE,gCACA,WACA,qDACE,UAMJ,8IAGE,4BACA,uBC5OJ,iCACE,aACA,mBACA,uBACA,WACA,qBACA,oCACA,kDACA,cAEF,qCACE,cACA,iDACE,WACA,YACA,iBACA,2CACA,kBACA,eAEJ,sCACE,OACA,aACA,sBACA,UACA,YAEF,+BACE,0CACA,iBACA,gBACA,kBACA,6BACA,yBACA,YACA,kDACA,WACA,UACA,qCACE,aACA,gDAEJ,uCACE,aACA,mBACA,uBACA,WACA,eAGF,mCACE,aACA,sBACA,mBACA,uCACA,2CACA,kBACA,gBACA,eAEA,yCACE,0CACA,iBACA,gBACA,yBACA,gCACA,gBACA,mBAEJ,qCACE,aACA,mBACA,QAEA,0CACE,gCACA,gBAEF,wDACE,aACA,kBACA,yBACA,YACA,6BACA,8BACA,eACA,gBACA,UACA,8DACE,aACA,oDAEN,+BACE,eACA,uEACE,aAGJ,sCACE,aACA,sBACA,QAEF,sCACE,0CACA,iBACA,gBACA,yBACA,gCACA,kBAEF,oCACE,aACA,mBACA,QAEF,oCACE,iBAKF,kCACE,OACA,aACA,sBACA,gBACA,iBAGF,8BACE,OACA,gBACA,eACA,aAEA,qCACE,cAGJ,qCACE,aACA,8BACA,aAEF,gCACE,aACA,mBACA,mBACA,QACA,cACA,wCAEA,2CACE,mBAEF,sCACE,0CACA,iBACA,gBACA,yBACA,gCACA,eACA,mBAEF,0FAEE,OACA,yBACA,+BACA,kBACA,6BACA,0CACA,gBACA,gBACA,sGACE,aACA,uCACA,8BAEJ,mDACE,kBACA,WAEF,uCACE,eAMF,8LAGE,4BACA","file":"mgt2.min.css"}
\ No newline at end of file
diff --git a/system.json b/system.json
index 24b5727..0746ffb 100644
--- a/system.json
+++ b/system.json
@@ -1,47 +1,47 @@
{
- "id": "mgt2",
- "version": "0.1.4",
- "title": "MGT2 - Mongoose Traveller (Unofficial)",
- "description": "An unofficial implementation of Mongoose Publishing Traveller (VO/VF). Traveller is the property of Mongoose Publishing, and can be purchased at https://www.mongoosepublishing.com",
- "background": "systems/mgt2/assets/screens/rosette-nebula-ngc2239-hoo.webp",
- "url": "https://github.com/JDR-Ninja/foundryvtt-mgt2",
- "manifest": "https://github.com/JDR-Ninja/foundryvtt-mgt2/releases/latest/download/system.json",
- "readme": "https://raw.githubusercontent.com/JDR-Ninja/foundryvtt-mgt2/main/README.md",
- "download": "https://github.com/JDR-Ninja/foundryvtt-mgt2/releases/download/v0.1.4/mgt2.zip",
- "changelog": "https://raw.githubusercontent.com/JDR-Ninja/foundryvtt-mgt2/main/CHANGELOG.md",
- "authors": [
- {
- "name": "JdR Ninja",
- "url": "https://www.jdr.ninja/",
- "discord": "jdr.ninja"
- }
- ],
- "esmodules": [
- "mgt2.bundle.js"
- ],
- "styles": [
- "styles/mgt2.min.css"
- ],
- "packs": [],
- "languages": [
- {
- "lang": "en",
- "name": "English",
- "path": "lang/en.json"
- },
- {
- "lang": "fr",
- "name": "Français",
- "path": "lang/fr.json"
- }
- ],
- "compatibility": {
- "minimum": "11",
- "verified": "12.324"
- },
- "grid": {
- "distance": 1.5,
- "units": "m"
- },
- "primaryTokenAttribute": "life"
+ "id": "mgt2",
+ "version": "0.1.4",
+ "title": "MGT2 - Mongoose Traveller (Unofficial)",
+ "description": "An unofficial implementation of Mongoose Publishing Traveller (VO/VF). Traveller is the property of Mongoose Publishing, and can be purchased at https://www.mongoosepublishing.com",
+ "background": "systems/mgt2/assets/screens/rosette-nebula-ngc2239-hoo.webp",
+ "url": "https://github.com/JDR-Ninja/foundryvtt-mgt2",
+ "manifest": "https://github.com/JDR-Ninja/foundryvtt-mgt2/releases/latest/download/system.json",
+ "readme": "https://raw.githubusercontent.com/JDR-Ninja/foundryvtt-mgt2/main/README.md",
+ "download": "https://github.com/JDR-Ninja/foundryvtt-mgt2/releases/download/v0.1.4/mgt2.zip",
+ "changelog": "https://raw.githubusercontent.com/JDR-Ninja/foundryvtt-mgt2/main/CHANGELOG.md",
+ "authors": [
+ {
+ "name": "JdR Ninja",
+ "url": "https://www.jdr.ninja/",
+ "discord": "jdr.ninja"
+ }
+ ],
+ "esmodules": [
+ "mgt2.bundle.js"
+ ],
+ "styles": [
+ "styles/mgt2.min.css"
+ ],
+ "packs": [],
+ "languages": [
+ {
+ "lang": "en",
+ "name": "English",
+ "path": "lang/en.json"
+ },
+ {
+ "lang": "fr",
+ "name": "Français",
+ "path": "lang/fr.json"
+ }
+ ],
+ "compatibility": {
+ "minimum": "11",
+ "verified": "12.324"
+ },
+ "grid": {
+ "distance": 1.5,
+ "units": "m"
+ },
+ "primaryTokenAttribute": "life"
}
\ No newline at end of file
diff --git a/template.json b/template.json
index 4ec120d..c726495 100644
--- a/template.json
+++ b/template.json
@@ -5,7 +5,7 @@
"vehicule",
"creature"
],
- "htmlFields": ["notes"],
+ "htmlFields": ["notes", "biography"],
"character": {},
"vehicule": {},
"creature": {}
diff --git a/templates/actors/actor-config-sheet.html b/templates/actors/actor-config-sheet.html
index 8944c31..b8cebae 100644
--- a/templates/actors/actor-config-sheet.html
+++ b/templates/actors/actor-config-sheet.html
@@ -1,6 +1,6 @@