- Ajout de 14 DataModels (10 Items + 3 Acteurs) * Items: equipment, weapon, trait, specialization, maneuver, scar, annency, boheme, contact, confrontation * Acteurs: pc, npc, annency - Corrections d'initialisation * Ordre d'initialisation corrigé (CONFIG.dataModels avant game.system) * Import dynamique des DataModels pour éviter timing issues * Helper functions pour éviter réutilisation de champs - Documentation complète * AUDIT_DATAMODELS.md: Rapport d'audit complet (85+ champs vérifiés) * MIGRATION_DATAMODELS.md: Guide de migration * FIX_INIT_ERROR.md: Résolution des erreurs * BABELE_ERROR_ANALYSIS.md: Analyse erreur Babele * RESUME_MIGRATION.md: Résumé complet * modules/models/README.md: Documentation des DataModels - template.json marqué comme DEPRECATED - changelog.md mis à jour Note: Erreur Babele/LibWrapper non résolue (problème de module externe) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
26 lines
700 B
JavaScript
26 lines
700 B
JavaScript
/**
|
|
* Data model pour les cicatrices
|
|
*/
|
|
export default class EcrymeScarDataModel extends foundry.abstract.TypeDataModel {
|
|
static defineSchema() {
|
|
const fields = foundry.data.fields;
|
|
return {
|
|
description: new fields.HTMLField({ initial: "" }),
|
|
skillcategory: new fields.ArrayField(
|
|
new fields.StringField({
|
|
choices: {
|
|
physical: "Physique",
|
|
mental: "Mental",
|
|
social: "Social",
|
|
cephalie: "Céphalie"
|
|
}
|
|
}),
|
|
{
|
|
initial: ["physical", "mental", "social", "cephalie"]
|
|
}
|
|
),
|
|
scarLevel: new fields.NumberField({ initial: 1, integer: true, min: 1 })
|
|
};
|
|
}
|
|
}
|