Add localization of actor and item type labels

This commit is contained in:
Johannes Loher 2021-01-10 02:35:48 +01:00
parent 17d0213e62
commit 0568afc32b
4 changed files with 16 additions and 0 deletions

View file

@ -99,6 +99,8 @@
"DS4.SpellDuration": "Wirkdauer",
"DS4.SpellCooldownDuration": "Abklingzeit",
"DS4.SpellScrollPriceGold": "Schriftrollenpreis (Gold)",
"DS4.ActorTypeCharacter": "Charakter",
"DS4.ActorTypeCreature": "Kreatur",
"DS4.AttributeBody": "Körper",
"DS4.AttributeMobility": "Agilität",
"DS4.AttributeMind": "Geist",

View file

@ -99,6 +99,8 @@
"DS4.SpellDuration": "Duration",
"DS4.SpellCooldownDuration": "Cooldown",
"DS4.SpellScrollPriceGold": "Scroll Price (Gold)",
"DS4.ActorTypeCharacter": "Character",
"DS4.ActorTypeCreature": "Creature",
"DS4.AttributeBody": "Body",
"DS4.AttributeMobility": "Mobility",
"DS4.AttributeMind": "Mind",

View file

@ -120,6 +120,14 @@ export const DS4 = {
electricity: "DS4.SpellCategoryElectricity",
},
/**
* Define the set of actor types
*/
actorTypes: {
character: "DS4.ActorTypeCharacter",
creature: "DS4.ActorTypeCreature",
},
/**
* Define the set of attributes an actor has
*/

View file

@ -22,6 +22,10 @@ Hooks.once("init", async function () {
CONFIG.Actor.entityClass = DS4Actor as typeof Actor;
CONFIG.Item.entityClass = DS4Item as typeof Item;
// Define localized type labels
CONFIG.Actor.typeLabels = DS4.actorTypes;
CONFIG.Item.typeLabels = DS4.itemTypes;
// Configure Dice
CONFIG.Dice.types = [Die, DS4Check];
CONFIG.Dice.terms = {