Files
vermine2047/module/system/config.mjs
T
uberwald 30d6f71fc7 fix: Correct critical bugs and complete Creature/Group DataModel implementation
- Fix TypeError: controls.find is not a function in hooks.mjs
- Fix undefined 'npc' variable in applications.mjs
- Fix CONFIG.VERMINE.model undefined by checking game.system.template existence
- Fix TypeError: html.find(...).forEach is not a function in roll.mjs
- Fix Cannot set properties of undefined (setting 'initial') in actor.mjs
- Fix Cannot read properties of undefined (reading 'difficulty') in actor.mjs
- Fix ActiveEffect application phase 'initial' already completed by adding combatStatus to base template
- Fix Missing helper: 'select' in roll-dialog.hbs (removed invalid Handlebars select block)
- Add SIZE_LEVELS labels to creatureSizeLevels config
- Add SIZE_LEVELS translations to fr.json
- Add combatStatus to base actor template
- Convert all .html templates to .hbs for Foundry v14 compatibility
- Update item-sheet.mjs to use .hbs extension
- Update handlebars-manager.mjs to use .hbs for all partials

Complete Vermine2047 Creature and Group sheet implementation:
- Creature: Pattern, Size, Role, Pack with computed values
- Group: Totem, Reserve, Morale, Objectives, Members management
- All templates functional with proper styling

Generated by Mistral Vibe.
Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
2026-06-04 22:22:52 +02:00

468 lines
19 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
export const VERMINE = {};
/**
* The set of Ability Scores used within the sytem.
* @type {Object}
*/
VERMINE.AgeTypes = {
1: { "name": "AGE_TYPES.young", "beginning": 0 },
2: { "name": "AGE_TYPES.adult", "beginning": 18 },
3: { "name": "AGE_TYPES.old", "beginning": 47 }
}
VERMINE.SkillLevels = {
0: { "label": "SKILL_LEVELS.incompetent", "dicePool": 0, "reroll": 0 },
1: { "label": "SKILL_LEVELS.beginner", "dicePool": 1, "reroll": 0 },
2: { "label": "SKILL_LEVELS.proficient", "dicePool": 1, "reroll": 1 },
3: { "label": "SKILL_LEVELS.expert", "dicePool": 2, "reroll": 1 },
4: { "label": "SKILL_LEVELS.master", "dicePool": 2, "reroll": 2 },
5: { "label": "SKILL_LEVELS.legend", "dicePool": 3, "reroll": 2 }
}
VERMINE.DifficultyLevels = {
1: { "label": "DIFFICULTY_LEVELS.obvious", "difficulty": 3 },
2: { "label": "DIFFICULTY_LEVELS.easy", "difficulty": 5 },
3: { "label": "DIFFICULTY_LEVELS.hard", "difficulty": 7 },
4: { "label": "DIFFICULTY_LEVELS.very_hard", "difficulty": 9 },
5: { "label": "DIFFICULTY_LEVELS.impossible", "difficulty": 10 }
},
VERMINE.ThreatLevels = {
1: { "label": "THREAT_LEVELS.minor", "attack": 3, "vigor": 1, "minorWound": 1, "majorWound": 1, "deadlyWound": 1 },
2: { "label": "THREAT_LEVELS.serious", "attack": 4, "vigor": 2, "minorWound": 2, "majorWound": 1, "deadlyWound": 1 },
3: { "label": "THREAT_LEVELS.major", "attack": 5, "vigor": 3, "minorWound": 2, "majorWound": 1, "deadlyWound": 1 },
4: { "label": "THREAT_LEVELS.deadly", "attack": 6, "vigor": 4, "minorWound": 2, "majorWound": 2, "deadlyWound": 2 },
}
VERMINE.ExperienceLevels = {
1: { "label": "SKILL_LEVELS.beginner", "action": 3, "specialties": 4, "rerolls": 0, "contact": "7" },
2: { "label": "SKILL_LEVELS.proficient", "action": 3, "specialties": 5, "rerolls": 0, "contact": "5 ou 7" },
3: { "label": "SKILL_LEVELS.expert", "action": 4, "specialties": 6, "rerolls": 1, "contact": "5,7 ou 9" },
4: { "label": "SKILL_LEVELS.master", "action": 4, "specialties": 6, "rerolls": 2, "contact": "3,5,7 ou 9" },
}
VERMINE.RoleLevels = {
1: { "label": "ROLE_LEVELS.minor", "reaction": 3, "reaction_bonus": 0, "pools": 0, "gear": 9, "gear_hindrance": 0, "protection": 1 },
2: { "label": "ROLE_LEVELS.secondary", "reaction": 3, "reaction_bonus": 1, "pools": 1, "gear": 9, "gear_hindrance": 1, "protection": 2 },
3: { "label": "ROLE_LEVELS.important", "reaction": 3, "reaction_bonus": 2, "pools": 2, "gear": 9, "gear_hindrance": 2, "protection": 3 },
4: { "label": "ROLE_LEVELS.major", "reaction": 4, "reaction_bonus": 2, "pools": 4, "gear": 10, "gear_hindrance": 2, "protection": 3 },
}
VERMINE.PatternLevels = {
1: { "label": "PATTERN_LEVELS.insect", "attack": 2, "damage": 0, "minorWound": 0, "majorWound": 0, "deadlyWound": 1 },
2: { "label": "PATTERN_LEVELS.rat", "attack": 3, "damage": 1, "minorWound": 0, "majorWound": 1, "deadlyWound": 1 },
3: { "label": "PATTERN_LEVELS.dog", "attack": 4, "damage": 3, "minorWound": 1, "majorWound": 1, "deadlyWound": 1 },
4: { "label": "PATTERN_LEVELS.bear", "attack": 6, "damage": 6, "minorWound": 2, "majorWound": 2, "deadlyWound": 2 },
}
VERMINE.SizeLevels = {
1: { "attack": 2, "vigor": 1, "minorWound": 0, "majorWound": 0, "deadlyWound": 1 },
2: { "attack": 3, "vigor": 2, "minorWound": 0, "majorWound": 1, "deadlyWound": 1 },
3: { "attack": 4, "vigor": 3, "minorWound": 1, "majorWound": 1, "deadlyWound": 1 }
}
VERMINE.PackLevels = {
1: { "attack": 1, "damage": 1, "minorWound": 0, "majorWound": 0, "deadlyWound": 1 },
2: { "attack": 2, "damage": 2, "minorWound": 2, "majorWound": 2, "deadlyWound": 2 },
3: { "attack": 5, "damage": 5, "minorWound": 3, "majorWound": 3, "deadlyWound": 3 }
}
/**
* Domains of influence for each totem
* Each totem provides bonus to certain skill categories
*/
VERMINE.totemDomains = {
"human": {
"label": "TOTEMS.human.name",
"domains": ["man", "world"],
"bonus": +1,
"description": "Le totem humain favorise les compétences liées à l'humanité et au monde civilisé"
},
"predator": {
"label": "TOTEMS.predator.name",
"domains": ["animal", "survival"],
"bonus": +1,
"description": "Le totem prédateur favorise la chasse et la survie"
},
"scavenger": {
"label": "TOTEMS.scavenger.name",
"domains": ["tool", "world"],
"bonus": +1,
"description": "Le totem charognard favorise la récupération et l'utilisation d'outils"
},
"symbiote": {
"label": "TOTEMS.symbiote.name",
"domains": ["man", "social"],
"bonus": +1,
"description": "Le totem symbiote favorise les interactions sociales"
},
"parasite": {
"label": "TOTEMS.parasite.name",
"domains": ["animal", "survival"],
"bonus": +1,
"description": "Le totem parasite favorise la discrétion et la survie"
},
"builder": {
"label": "TOTEMS.builder.name",
"domains": ["tool", "world"],
"bonus": +1,
"description": "Le totem bâtisseur favorise la construction et la manipulation"
},
"horde": {
"label": "TOTEMS.horde.name",
"domains": ["animal", "survival"],
"bonus": +1,
"description": "Le totem horde favorise le combat en groupe"
},
"hive": {
"label": "TOTEMS.hive.name",
"domains": ["man", "social"],
"bonus": +1,
"description": "Le totem ruche favorise l'organisation collective"
},
"loner": {
"label": "TOTEMS.loner.name",
"domains": ["survival", "world"],
"bonus": +1,
"description": "Le totem solitaire favorise l'autonomie"
},
"adapted": {
"label": "TOTEMS.adapted.name",
"domains": ["animal", "survival"],
"bonus": +1,
"description": "Le totem adapté favorise l'adaptation à l'environnement"
}
}
/**
* NPC Threat Levels configuration
*/
VERMINE.npcThreatLevels = {
1: { "label": "THREAT_LEVELS.minor", "attack": 3, "vigor": 1, "minorWound": 1, "majorWound": 1, "deadlyWound": 1 },
2: { "label": "THREAT_LEVELS.serious", "attack": 4, "vigor": 2, "minorWound": 2, "majorWound": 1, "deadlyWound": 1 },
3: { "label": "THREAT_LEVELS.major", "attack": 5, "vigor": 3, "minorWound": 2, "majorWound": 1, "deadlyWound": 1 },
4: { "label": "THREAT_LEVELS.deadly", "attack": 6, "vigor": 4, "minorWound": 2, "majorWound": 2, "deadlyWound": 2 }
}
/**
* NPC Experience Levels configuration
*/
VERMINE.npcExperienceLevels = {
1: { "label": "SKILL_LEVELS.beginner", "action": 3, "specialties": 4, "rerolls": 0, "contact": "7" },
2: { "label": "SKILL_LEVELS.proficient", "action": 3, "specialties": 5, "rerolls": 0, "contact": "5 ou 7" },
3: { "label": "SKILL_LEVELS.expert", "action": 4, "specialties": 6, "rerolls": 1, "contact": "5,7 ou 9" },
4: { "label": "SKILL_LEVELS.master", "action": 4, "specialties": 6, "rerolls": 2, "contact": "3,5,7 ou 9" }
}
/**
* NPC Role Levels configuration
*/
VERMINE.npcRoleLevels = {
1: { "label": "ROLE_LEVELS.minor", "reaction": 3, "reaction_bonus": 0, "pools": 0, "gear": 9, "gear_hindrance": 0, "protection": 1 },
2: { "label": "ROLE_LEVELS.secondary", "reaction": 3, "reaction_bonus": 1, "pools": 1, "gear": 9, "gear_hindrance": 1, "protection": 2 },
3: { "label": "ROLE_LEVELS.important", "reaction": 3, "reaction_bonus": 2, "pools": 2, "gear": 9, "gear_hindrance": 2, "protection": 3 },
4: { "label": "ROLE_LEVELS.major", "reaction": 4, "reaction_bonus": 2, "pools": 4, "gear": 10, "gear_hindrance": 2, "protection": 3 }
}
/**
* Creature Pattern Levels configuration
*/
VERMINE.creaturePatternLevels = {
1: { "label": "PATTERN_LEVELS.insect", "attack": 2, "damage": 0, "minorWound": 0, "majorWound": 0, "deadlyWound": 1 },
2: { "label": "PATTERN_LEVELS.rat", "attack": 3, "damage": 1, "minorWound": 0, "majorWound": 1, "deadlyWound": 1 },
3: { "label": "PATTERN_LEVELS.dog", "attack": 4, "damage": 3, "minorWound": 1, "majorWound": 1, "deadlyWound": 1 },
4: { "label": "PATTERN_LEVELS.bear", "attack": 6, "damage": 6, "minorWound": 2, "majorWound": 2, "deadlyWound": 2 }
}
/**
* Creature Size Levels configuration
*/
VERMINE.creatureSizeLevels = {
1: { "label": "SIZE_LEVELS.small", "attack": 2, "vigor": 1, "minorWound": 0, "majorWound": 0, "deadlyWound": 1 },
2: { "label": "SIZE_LEVELS.medium", "attack": 3, "vigor": 2, "minorWound": 0, "majorWound": 1, "deadlyWound": 1 },
3: { "label": "SIZE_LEVELS.large", "attack": 4, "vigor": 3, "minorWound": 1, "majorWound": 1, "deadlyWound": 1 }
}
/**
* Creature Pack Levels configuration
*/
VERMINE.creaturePackLevels = {
0: { "attack": 0, "damage": 0, "minorWound": 0, "majorWound": 0, "deadlyWound": 0 },
1: { "attack": 1, "damage": 1, "minorWound": 0, "majorWound": 0, "deadlyWound": 1 },
2: { "attack": 2, "damage": 2, "minorWound": 2, "majorWound": 2, "deadlyWound": 2 },
3: { "attack": 5, "damage": 5, "minorWound": 3, "majorWound": 3, "deadlyWound": 3 }
}
/**
* Creature Role Levels configuration (same as NPC roles)
*/
VERMINE.creatureRoleLevels = {
1: { "label": "ROLE_LEVELS.minor", "reaction": 3, "reaction_bonus": 0, "pools": 0, "gear": 9, "gear_hindrance": 0, "protection": 1 },
2: { "label": "ROLE_LEVELS.secondary", "reaction": 3, "reaction_bonus": 1, "pools": 1, "gear": 9, "gear_hindrance": 1, "protection": 2 },
3: { "label": "ROLE_LEVELS.important", "reaction": 3, "reaction_bonus": 2, "pools": 2, "gear": 9, "gear_hindrance": 2, "protection": 3 },
4: { "label": "ROLE_LEVELS.major", "reaction": 4, "reaction_bonus": 2, "pools": 4, "gear": 10, "gear_hindrance": 2, "protection": 3 }
}
VERMINE.abilityCategories = {
"physical": {
"label": "VERMINE.ability_category.physical"
},
"manual": {
"label": "VERMINE.ability_category.manual"
},
"mental": {
"label": "VERMINE.ability_category.mental"
},
"social": {
"label": "VERMINE.ability_category.social"
}
}
VERMINE.abilities = {
"vigor": "ABILITIES.vigor.name",
"health": "ABILITIES.health.name",
"precision": "ABILITIES.precision.name",
"reflexes": "ABILITIES.reflexes.name",
"knowledge": "ABILITIES.knowledge.name",
"perception": "ABILITIES.perception.name",
"will": "ABILITIES.will.name",
"empathy": "ABILITIES.empathy.name"
}
VERMINE.skillCategories = {
"man": {
"label": "VERMINE.skill_category.man"
},
"animal": {
"label": "VERMINE.skill_category.animal"
},
"tool": {
"label": "VERMINE.skill_category.tool"
},
"weapon": {
"label": "VERMINE.skill_category.weapon"
},
"survival": {
"label": "VERMINE.skill_category.survival"
},
"world": {
"label": "VERMINE.skill_category.world"
}
}
VERMINE.sexes = { "male": "VERMINE.sexes.male", "female": "VERMINE.sexes.female" };
VERMINE.totems = {
"human": "TOTEMS.human.name",
"predator": "TOTEMS.predator.name",
"scavenger": "TOTEMS.scavenger.name",
"symbiote": "TOTEMS.symbiote.name",
"parasite": "TOTEMS.parasite.name",
"builder": "TOTEMS.builder.name",
"horde": "TOTEMS.horde.name",
"hive": "TOTEMS.hive.name",
"loner": "TOTEMS.loner.name",
"adapted": "TOTEMS.adapted.name"
}
VERMINE.totem_opposites = {
"human": "TOTEMS.adapted.name",
"predator": "TOTEMS.scavenger.name",
"scavenger": "TOTEMS.predator.name",
"symbiote": "TOTEMS.parasite.name",
"parasite": "TOTEMS.symbiote.name",
"builder": "TOTEMS.horde.name",
"horde": "TOTEMS.builder.name",
"hive": "TOTEMS.loner.name",
"loner": "TOTEMS.hive.name",
"adapted": "TOTEMS.human.name"
}
VERMINE.origins = {
"aon": "Aon",
"avhorae": "Avhorae",
"babel": "Babel",
"soleil_noir": "Empire du Soleil Noir",
"fakhar": "Fakhar",
"horde": "Horde",
"khashan": "Khashan",
"ool": "Ool",
"shattered_kingdoms": "Royaumes divisés",
"saeth": "Saeth",
"tegee": "Tégée (Thalos)",
"tuuhle": "Tuuhle",
"vaelor": "Vaelor",
"valdheim": "Valdheim"
}
VERMINE.traits = {
"bien_conçu": {
name: "bien conçu",
description: "+1 Réussite automatique sur les jets de réparation. + 1 point de Fiabilité sur les jets de réparation de fortune.+ 1 Réussite automatique sur les jets de sabotage.",
value: 0
},
"cassant": {
name: "cassant",
description: "Toutes les pertes de Fiabilité subies sont majorées de 1 point.",
value: 0 // = la valeur "n" dans le tableau page 51 livre règles. 0 si pas de valeur
},
"coque": {
name: "coque",
description: "Ignore les (n) premiers Dommages. Quand (n) est atteint, lobjet perd ce Trait.",
value: 1
},
"duree": {
name: "Durée",
description: "Les effets de larme ou de lobjet durent (n) Tours de combat.Les durées en minutes, en heures ou en jours sont toujours indiquées de façon claire, notamment dans le cas des maladies ou des empoisonnements.",
value: 1
},
"etanche": {
name: "Étanche.",
description: "Tant que sa Fiabilité est à son maximum, lobjet ignore les Dommages dus à limmersion prolongée.De plus, les vêtements et protections Étanches permettent d’éviter les effets de Zone liés aux gaz, et font baisser dun cran le niveau dexposition à une maladie(jusqu’à éventuellement éviter de lancer les Dés de Santé) voir « Maladies et infections », page 105.",
value: 0
},
"fetiche": {
name: "Fétiche",
description: "Le personnage possède un objet fétiche auquel il tient.Tant quil le possède, sa Réserve dEffort ou de Sang- Froid est augmentée de 1D, et il ne subit pas les Malus d’Épuisement liés à la valeur de ses Réserves, même si elles sont réduites à 0. Si le personnage perd ou est privé de cet objet, les règles d’Épuisement sappliquent de nouveau et il perd immédiatement 2D dans chacune de ses Réserves, dont les valeurs maximales sont réduites de 1D.Un même personnage ne peut posséder quun seul objet avec le Trait Fétiche.",
value: 0
},
"incapacitant": {
name: "Incapacitant",
description: "Ignore les (n) premiers Dommages. Quand (n) est atteint, lobjet perd ce Trait.",
value: 1
},
"intimidant": {
name: "Intimidant",
description: "Tant que le personnage utilise cet objet, il bénéficie dune Relance de 1D sur ses jets visant à effrayer, impressionner ou menacer. Il subit cependant un Malus de 1D à toutes ses Actions avec Psychologie.Le meneur peut décider quune créature est trop bête ou trop confiante pour se laisser intimider.De plus si votre personnage brandit un objet Intimidant mais démontre rapidement quil ne sait pas sen servir, le meneur peut le priver de sa Relance.",
value: 0
},
"lourd": {
name: "Lourd",
description: "Lobjet est particulièrement lourd et demande une Vigueur minimum de(n) D pour être porté, manié ou utilisé correctement.Si la Vigueur du personnage est inférieure à(n), il subit un Malus de 1D. Sil porte plusieurs objets Lourds, comme une arme Lourde et une Protection blindée, les Malus éventuels se cumulent.",
value: 1
},
"malus": {
name: "Malus",
description: "Larme ou lobjet inflige un Malus de(n) D à toutes les actions des personnages affectés pendant toute la Durée de leffet.Cest le cas notamment de certains gaz, venins, poisons ou maladies.",
value: 1
},
"maniable": {
name: "Maniable.",
description: "Lobjet ninflige pas de Handicap de Mobilité à son porteur voir « Handicap de Mobilité », page 70. Un objet peut être Maniable et Lourd(n).",
value: 0
},
"ponctuel": {
name: "Ponctuel",
description: "Cet objet contient un certain nombre dingrédients, charges, batteries ou petites composantes qui peuvent être utilisés pour réduire les Handicaps infligés sur une action où ils peuvent être utiles.Pour chaque degré de Handicap que le joueur souhaite annuler, la valeur du Trait est réduite de 1. Quand cette valeur tombe à 0, lobjet perd définitivement ce Trait.",
value: 1
},
"portee": {
name: "Portée",
description: "Lobjet a une portée utile ou maximale de(n) mètres.Les armes de distance disposent de plusieurs Portées, qui peuvent être fixes ou modifiées par la Vigueur de lattaquant, notamment pour les armes de tir ou de lancer.",
value: 1
},
"pratique": {
name: "Pratique",
description: "Le matériel offre une prise en main exceptionnelle, une maniabilité étonnante, une simplicité dusage remarquable.Utiliser un tel matériel pour une action adéquate accorde un Bonus de 2D au lieu de 1D.Rechercher ce Trait sur un matériel compte comme deux critères de Rareté à lui seul.De plus les réparations, améliorations et fabrications de matériel avec ce Trait souffrent de(I) Handicap en plus de ceux applicables normalement.",
value: 0
},
"rapide": {
name: "Rapide",
description: "Lobjet est particulièrement léger et permet de porter plusieurs attaques consécutives, au contact ou à distance.Ces(n) coups ou projectiles sont gérés par un seul jet dattaque et imposent (n) Handicaps au défenseur.",
value: 1
},
"rafale": {
name: "Rafale",
description: "Certaines armes à feu automatiques permettent de tirer en rafales.Le tireur neffectue quun seul jet contre une Difficulté augmentée de 2, mais gagne(n) Réussites supplémentaires si son jet est réussi.",
value: 1
},
"zone": {
name: "Zone",
description: "Larme ou lobjet déclenche ses effets dans une zone de(n) mètres de diamètre.Si lobjet inflige des Dommages, tout ce qui se trouve dans la zone les subit.",
value: 1
},
// etc...etc...
}
VERMINE.damageTypes = [
"choc",
"lame",
"feu",
"balle"
];
VERMINE.combatStatus = {
offensif: 5,
actif: 7,
passif: 9
}
/**
* Group Morale Levels configuration
* Rules: p. 68-69 - Group Reserve and Morale
*/
VERMINE.groupMoraleLevels = {
"high": {
"label": "VERMINE.morale_high",
"description": "7D+ - Moral élevé, groupe déterminé",
"minDice": 7
},
"normal": {
"label": "VERMINE.morale_normal",
"description": "3-6D - Moral normal",
"minDice": 3,
"maxDice": 6
},
"low": {
"label": "VERMINE.morale_low",
"description": "1-2D - Moral bas, groupe hésitant",
"minDice": 1,
"maxDice": 2
},
"crisis": {
"label": "VERMINE.morale_crisis",
"description": "0D - Crise, groupe au bord de l'effondrement",
"minDice": 0,
"maxDice": 0
}
}
/**
* Group Reserve configuration
* The reserve is shared among all group members and can be used with vote
*/
VERMINE.groupReserve = {
"min": 0,
"max": 10,
"description": "Réserve de dés partagée par le groupe (p. 68-69)"
}
/**
* Group Level configuration (1-10)
*/
VERMINE.groupLevels = {
1: { "label": "Niveau 1 - Débutant" },
2: { "label": "Niveau 2 - Initié" },
3: { "label": "Niveau 3 - Expérimenté" },
4: { "label": "Niveau 4 - Confirmé" },
5: { "label": "Niveau 5 - Vétéran" },
6: { "label": "Niveau 6 - Élite" },
7: { "label": "Niveau 7 - Légendaire" },
8: { "label": "Niveau 8 - Mythique" },
9: { "label": "Niveau 9 - Hérotique" },
10: { "label": "Niveau 10 - Légende" }
}
/**
* Totem Instincts and Prohibitions effects
* Rules: p. 68-69 - Instincts give +3D/+5D, Prohibitions give -3D/-5D
*/
VERMINE.totemEffects = {
"instinct": {
"minor": "+3D",
"major": "+5D"
},
"prohibition": {
"minor": "-3D",
"major": "-5D"
}
}