icon
This commit is contained in:
@@ -110,12 +110,10 @@ export class RollL5r5e extends Roll {
|
|||||||
// Add L5R summary
|
// Add L5R summary
|
||||||
if (this.l5r5e.dicesTypes.l5r) {
|
if (this.l5r5e.dicesTypes.l5r) {
|
||||||
const summary = this.l5r5e.summary;
|
const summary = this.l5r5e.summary;
|
||||||
|
|
||||||
// TODO i18n lang trad or symbols
|
|
||||||
total +=
|
total +=
|
||||||
(this.l5r5e.dicesTypes.std ? " | " : "") +
|
(this.l5r5e.dicesTypes.std ? " | " : "") +
|
||||||
["success", "explosive", "opportunity", "strife"]
|
["success", "explosive", "opportunity", "strife"]
|
||||||
.map((props) => (summary[props] > 0 ? props + ": " + summary[props] : null))
|
.map((props) => (summary[props] > 0 ? `<i class="${props}"></i> ${summary[props]}` : null))
|
||||||
.filter((c) => !!c)
|
.filter((c) => !!c)
|
||||||
.join(" | ");
|
.join(" | ");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -57,6 +57,11 @@ Hooks.once("init", async function () {
|
|||||||
Items.registerSheet("l5r5e", WeaponSheetL5r5e, { types: ["weapon"], makeDefault: true });
|
Items.registerSheet("l5r5e", WeaponSheetL5r5e, { types: ["weapon"], makeDefault: true });
|
||||||
Items.registerSheet("l5r5e", FeatSheetL5r5e, { types: ["feat"], makeDefault: true });
|
Items.registerSheet("l5r5e", FeatSheetL5r5e, { types: ["feat"], makeDefault: true });
|
||||||
|
|
||||||
|
// for debug
|
||||||
|
Handlebars.registerHelper("json", function (object) {
|
||||||
|
return new Handlebars.SafeString(JSON.stringify(object));
|
||||||
|
});
|
||||||
|
|
||||||
Handlebars.registerHelper("localizeSkillCategory", function (skillName) {
|
Handlebars.registerHelper("localizeSkillCategory", function (skillName) {
|
||||||
const key = "L5r5e.Skills." + skillName + ".Title";
|
const key = "L5r5e.Skills." + skillName + ".Title";
|
||||||
return game.i18n.localize(key);
|
return game.i18n.localize(key);
|
||||||
|
|||||||
Reference in New Issue
Block a user