Giving up again

This commit is contained in:
Joscha Maier 2024-10-19 23:02:28 +02:00
parent 54798bd300
commit bc71b3d2cc
No known key found for this signature in database
GPG Key ID: 8C4D045D84A30ABA
5 changed files with 39 additions and 8 deletions

View File

@ -15,11 +15,11 @@ Hooks.once("init", async function() {
globalThis.kidsonbrooms = game.system; globalThis.kidsonbrooms = game.system;
game.system.CONST = SYSTEM; game.system.CONST = SYSTEM;
Object.assign(CONFIG.Actor.dataModels, { Actors.unregisterSheet("core", ActorSheet);
PC: models.PlayerCharacter Actors.registerSheet(SYSTEM.id, "core", {types: ["PlayerCharacter"], makeDefault: true});
})
CONFIG.Actor.dataModels = {
playercharacter: models.playerCharacterModel
};
CONFIG.LOCALIZATION_PREFIXES = {
kidsonbrooms: "KidsOnBrooms"
}
}) })

View File

@ -1,2 +1,30 @@
{ {
} "BaseActor": {
"FIELDS": {
"age": "Age",
"pronouns": "Pronouns",
"fear": "Fear",
"grade": "Grade",
"stats": {
"fight": "Fight",
"brains": "Brains",
"charm": "Charm",
"flight": "Flight",
"brawn": "Brawn",
"grit": "Grit"
}
}
},
"PlayerCharacter": {
"FIELDS": {
"description": "Description",
"broom": "Broom",
"wand": "Wand",
"animalFamiliar": "Animal Familiar",
"schoolbag": "Schoolbag",
"strengths": "Strengths",
"adversityTokens": "Adversity Tokens"
}
}
}

View File

@ -23,6 +23,8 @@ export default class ActorGeneral extends foundry.abstract.TypeDataModel
} }
} }
static LOCALISATION_PREFIXES = ["BaseActor"];
prepareDerivedData() { prepareDerivedData() {
super.prepareDerivedData(); super.prepareDerivedData();
} }

View File

@ -21,6 +21,7 @@ export default class PlayerCharacter extends ActorGeneral
} }
} }
static LOCALISATION_PREFIXES = ["PlayerCharacter"];
prepareBaseData() { prepareBaseData() {
super.prepareBaseData(); super.prepareBaseData();
let effectsToApply = this.gatherEffects(); let effectsToApply = this.gatherEffects();

View File

@ -10,7 +10,7 @@
"esmodules": ["kidsonbrooms.mjs"], "esmodules": ["kidsonbrooms.mjs"],
"authors": [{ "authors": [{
"name": "Joscha Maier", "name": "Joscha Maier",
"url": "https://github.com/josmaier" "url": "https://gitlab.com/wintermyst"
}], }],
"documentTypes": { "documentTypes": {
"Actor": { "Actor": {