Première release testée
This commit is contained in:
@@ -320,7 +320,7 @@ export class CharacterGenerator {
|
||||
}
|
||||
|
||||
// Img (only if system defaults)
|
||||
const folder = "systems/l5r5e/assets/icons/actors";
|
||||
const folder = "systems/l5rx-chiaroscuro/assets/icons/actors";
|
||||
const newImg = [
|
||||
`${folder}/npc.svg`,
|
||||
`${folder}/traditional-japanese-man.svg`,
|
||||
|
||||
@@ -28,7 +28,7 @@ export class ItemCompendiumL5r5e extends Compendium {
|
||||
* changes their index-partial.hbs, this file will need updating to match.
|
||||
* @override
|
||||
*/
|
||||
static _entryPartial = "systems/l5r5e/templates/" + "compendium/l5r5e-index-partial.html";
|
||||
static _entryPartial = "systems/l5rx-chiaroscuro/templates/" + "compendium/l5r5e-index-partial.html";
|
||||
|
||||
/**
|
||||
* Sources present in this specific compendium, populated during _prepareContext.
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
export const L5R5E = {
|
||||
namespace: "l5r5e",
|
||||
paths: {
|
||||
assets: "systems/l5r5e/assets/",
|
||||
templates: "systems/l5r5e/templates/",
|
||||
assets: "systems/l5rx-chiaroscuro/assets/",
|
||||
templates: "systems/l5rx-chiaroscuro/templates/",
|
||||
},
|
||||
money: [50, 10],
|
||||
stances: ["earth", "air", "water", "fire", "void"],
|
||||
@@ -62,177 +62,177 @@ export const L5R5E = {
|
||||
conditions: [{
|
||||
id: "lightly_wounded_fire",
|
||||
name: "l5r5e.conditions.lightly_wounded_fire",
|
||||
img: "systems/l5r5e/assets/icons/conditions/lightly_wounded_fire.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/lightly_wounded_fire.webp",
|
||||
system: { id: "L5RCoreCon000016" }
|
||||
},{
|
||||
id: "lightly_wounded_water",
|
||||
name: "l5r5e.conditions.lightly_wounded_water",
|
||||
img: "systems/l5r5e/assets/icons/conditions/lightly_wounded_water.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/lightly_wounded_water.webp",
|
||||
system: { id: "L5RCoreCon000016" }
|
||||
},{
|
||||
id: "lightly_wounded_air",
|
||||
name: "l5r5e.conditions.lightly_wounded_air",
|
||||
img: "systems/l5r5e/assets/icons/conditions/lightly_wounded_air.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/lightly_wounded_air.webp",
|
||||
system: { id: "L5RCoreCon000016" }
|
||||
},{
|
||||
id: "lightly_wounded_earth",
|
||||
name: "l5r5e.conditions.lightly_wounded_earth",
|
||||
img: "systems/l5r5e/assets/icons/conditions/lightly_wounded_earth.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/lightly_wounded_earth.webp",
|
||||
system: { id: "L5RCoreCon000016" }
|
||||
},{
|
||||
id: "lightly_wounded_void",
|
||||
name: "l5r5e.conditions.lightly_wounded_void",
|
||||
img: "systems/l5r5e/assets/icons/conditions/lightly_wounded_void.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/lightly_wounded_void.webp",
|
||||
system: { id: "L5RCoreCon000016" }
|
||||
},{
|
||||
id: "severely_wounded_fire",
|
||||
name: "l5r5e.conditions.severely_wounded_fire",
|
||||
img: "systems/l5r5e/assets/icons/conditions/heavily_wounded_fire.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/heavily_wounded_fire.webp",
|
||||
system: { id: "L5RCoreCon000016" }
|
||||
},{
|
||||
id: "severely_wounded_water",
|
||||
name: "l5r5e.conditions.severely_wounded_water",
|
||||
img: "systems/l5r5e/assets/icons/conditions/heavily_wounded_water.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/heavily_wounded_water.webp",
|
||||
system: { id: "L5RCoreCon000016" }
|
||||
},{
|
||||
id: "severely_wounded_air",
|
||||
name: "l5r5e.conditions.severely_wounded_air",
|
||||
img: "systems/l5r5e/assets/icons/conditions/heavily_wounded_air.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/heavily_wounded_air.webp",
|
||||
system: { id: "L5RCoreCon000016" }
|
||||
},{
|
||||
id: "severely_wounded_earth",
|
||||
name: "l5r5e.conditions.severely_wounded_earth",
|
||||
img: "systems/l5r5e/assets/icons/conditions/heavily_wounded_earth.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/heavily_wounded_earth.webp",
|
||||
system: { id: "L5RCoreCon000016" }
|
||||
},{
|
||||
id: "severely_wounded_void",
|
||||
name: "l5r5e.conditions.severely_wounded_void",
|
||||
img: "systems/l5r5e/assets/icons/conditions/heavily_wounded_void.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/heavily_wounded_void.webp",
|
||||
system: { id: "L5RCoreCon000016" }
|
||||
},{
|
||||
id: "afflicted",
|
||||
name: "l5r5e.conditions.afflicted",
|
||||
img: "systems/l5r5e/assets/icons/conditions/afflicted.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/afflicted.webp",
|
||||
system: { id: "L5RCoreCon000001" }
|
||||
},{
|
||||
id: "bleeding",
|
||||
name: "l5r5e.conditions.bleeding",
|
||||
img: "systems/l5r5e/assets/icons/conditions/bleeding.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/bleeding.webp",
|
||||
system: { id: "L5RCoreCon000002" }
|
||||
},{
|
||||
id: "burning",
|
||||
name: "l5r5e.conditions.burning",
|
||||
img: "systems/l5r5e/assets/icons/conditions/burning.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/burning.webp",
|
||||
system: { id: "L5RCoreCon000003" }
|
||||
},{
|
||||
id: "centered",
|
||||
name: "l5r5e.conditions.centered",
|
||||
img: "systems/l5r5e/assets/icons/conditions/centered.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/centered.webp",
|
||||
system: { id: "L5RCoreCon000022" }
|
||||
},{
|
||||
id: "compromised",
|
||||
name: "l5r5e.conditions.compromised",
|
||||
img: "systems/l5r5e/assets/icons/conditions/compromised.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/compromised.webp",
|
||||
system: { id: "L5RCoreCon000004" }
|
||||
},{
|
||||
id: "dazed",
|
||||
name: "l5r5e.conditions.dazed",
|
||||
img: "systems/l5r5e/assets/icons/conditions/dazed.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/dazed.webp",
|
||||
system: { id: "L5RCoreCon000005" }
|
||||
},{
|
||||
id: "disoriented",
|
||||
name: "l5r5e.conditions.disoriented",
|
||||
img: "systems/l5r5e/assets/icons/conditions/disoriented.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/disoriented.webp",
|
||||
system: { id: "L5RCoreCon000006" }
|
||||
},{
|
||||
id: "dying",
|
||||
name: "l5r5e.conditions.dying",
|
||||
img: "systems/l5r5e/assets/icons/conditions/dying_1.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/dying_1.webp",
|
||||
system: { id: "L5RCoreCon000007" }
|
||||
},{
|
||||
id: "emboldened",
|
||||
name: "l5r5e.conditions.emboldened",
|
||||
img: "systems/l5r5e/assets/icons/conditions/emboldened.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/emboldened.webp",
|
||||
system: { id: "L5RCoreCon000023" }
|
||||
},{
|
||||
id: "enraged",
|
||||
name: "l5r5e.conditions.enraged",
|
||||
img: "systems/l5r5e/assets/icons/conditions/enraged.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/enraged.webp",
|
||||
system: { id: "L5RCoreCon000008" }
|
||||
},{
|
||||
id: "exhausted",
|
||||
name: "l5r5e.conditions.exhausted",
|
||||
img: "systems/l5r5e/assets/icons/conditions/exhausted.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/exhausted.webp",
|
||||
system: { id: "L5RCoreCon000009" }
|
||||
},{
|
||||
id: "illness_coughing_illness",
|
||||
name: "l5r5e.conditions.illness_coughing_illness",
|
||||
img: "systems/l5r5e/assets/icons/conditions/illness_coughing_illness.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/illness_coughing_illness.webp",
|
||||
system: { id: "L5RCoreCon000019" }
|
||||
},{
|
||||
id: "illness_fire_rash",
|
||||
name: "l5r5e.conditions.illness_fire_rash",
|
||||
img: "systems/l5r5e/assets/icons/conditions/illness_fire_rash.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/illness_fire_rash.webp",
|
||||
system: { id: "L5RCoreCon000021" }
|
||||
},{
|
||||
id: "illness_gut_sickness",
|
||||
name: "l5r5e.conditions.illness_gut_sickness",
|
||||
img: "systems/l5r5e/assets/icons/conditions/illness_gut_sickness.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/illness_gut_sickness.webp",
|
||||
system: { id: "L5RCoreCon000018" }
|
||||
},{
|
||||
id: "illness_oozing_sore_disease",
|
||||
name: "l5r5e.conditions.illness_oozing_sore_disease",
|
||||
img: "systems/l5r5e/assets/icons/conditions/illness_oozing_sore_disease.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/illness_oozing_sore_disease.webp",
|
||||
system: { id: "L5RCoreCon000017" }
|
||||
},{
|
||||
id: "illness_unsteady_illness",
|
||||
name: "l5r5e.conditions.illness_unsteady_illness",
|
||||
img: "systems/l5r5e/assets/icons/conditions/illness_unsteady_illness.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/illness_unsteady_illness.webp",
|
||||
system: { id: "L5RCoreCon000020" }
|
||||
},{
|
||||
id: "immobilized",
|
||||
name: "l5r5e.conditions.immobilized",
|
||||
img: "systems/l5r5e/assets/icons/conditions/immobilized.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/immobilized.webp",
|
||||
system: { id: "L5RCoreCon000010" }
|
||||
},{
|
||||
id: "incapacitated",
|
||||
name: "l5r5e.conditions.incapacitated",
|
||||
img: "systems/l5r5e/assets/icons/conditions/incapacitated.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/incapacitated.webp",
|
||||
system: { id: "L5RCoreCon000011" }
|
||||
},{
|
||||
id: "intoxicated",
|
||||
name: "l5r5e.conditions.intoxicated",
|
||||
img: "systems/l5r5e/assets/icons/conditions/intoxicated.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/intoxicated.webp",
|
||||
system: { id: "L5RCoreCon000012" }
|
||||
},{
|
||||
id: "possessed",
|
||||
name: "l5r5e.conditions.possessed",
|
||||
img: "systems/l5r5e/assets/icons/conditions/possesed.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/possesed.webp",
|
||||
system: { id: "L5RCoreCon000024" }
|
||||
},{
|
||||
id: "prone",
|
||||
name: "l5r5e.conditions.prone",
|
||||
img: "systems/l5r5e/assets/icons/conditions/prone.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/prone.webp",
|
||||
system: { id: "L5RCoreCon000013" }
|
||||
},{
|
||||
id: "silenced",
|
||||
name: "l5r5e.conditions.silenced",
|
||||
img: "systems/l5r5e/assets/icons/conditions/silenced.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/silenced.webp",
|
||||
system: { id: "L5RCoreCon000014" }
|
||||
},{
|
||||
id: "unconscious",
|
||||
name: "l5r5e.conditions.unconscious",
|
||||
img: "systems/l5r5e/assets/icons/conditions/unconscious.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/unconscious.webp",
|
||||
system: { id: "L5RCoreCon000015" }
|
||||
},{
|
||||
id: "desequilibre_solaire",
|
||||
name: "chiaroscuro.aspects.desequilibre_solaire",
|
||||
img: "systems/l5r5e/assets/icons/conditions/desequilibre_solaire.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/desequilibre_solaire.webp",
|
||||
system: { id: "ChiaCon000001" }
|
||||
},{
|
||||
id: "desequilibre_lunaire",
|
||||
name: "chiaroscuro.aspects.desequilibre_lunaire",
|
||||
img: "systems/l5r5e/assets/icons/conditions/desequilibre_lunaire.webp",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/conditions/desequilibre_lunaire.webp",
|
||||
system: { id: "ChiaCon000002" }
|
||||
}],
|
||||
regex: {
|
||||
|
||||
@@ -178,6 +178,12 @@ export class ChiaroscuroDiceDialog extends FormApplication {
|
||||
this.object.useAssistance = event.target.checked;
|
||||
this.render(false);
|
||||
});
|
||||
|
||||
// Roll button — explicit submit trigger
|
||||
html.find("button[name='roll']").on("click", (event) => {
|
||||
event.preventDefault();
|
||||
this._onSubmit(event);
|
||||
});
|
||||
}
|
||||
|
||||
async _updateObject(event, formData) {
|
||||
@@ -185,7 +191,8 @@ export class ChiaroscuroDiceDialog extends FormApplication {
|
||||
const skillRank = this.object.skill.rank;
|
||||
const skillBonus = this.object.skill.bonus;
|
||||
const flatModifier = this.object.modifier;
|
||||
const difficulty = this.object.difficulty.value;
|
||||
const difficultyObj = this.object.difficulty;
|
||||
const difficultyValue = difficultyObj.value;
|
||||
|
||||
// Roll the dice using FoundryVTT Roll API
|
||||
const roll = await new Roll(`${nbDice}d6`).evaluate();
|
||||
@@ -199,8 +206,8 @@ export class ChiaroscuroDiceDialog extends FormApplication {
|
||||
// Compute total
|
||||
const rawSum = adjustedResults.reduce((a, b) => a + b, 0);
|
||||
const total = rawSum + skillBonus + flatModifier;
|
||||
const success = total >= difficulty;
|
||||
const bonus = success ? total - difficulty : 0;
|
||||
const success = total >= difficultyValue;
|
||||
const bonus = success ? total - difficultyValue : 0;
|
||||
|
||||
// Update aspect gauge after roll
|
||||
if (this._actor && this.object.useAspectPoint) {
|
||||
@@ -218,7 +225,7 @@ export class ChiaroscuroDiceDialog extends FormApplication {
|
||||
total,
|
||||
skillBonus,
|
||||
flatModifier,
|
||||
difficulty,
|
||||
difficulty: difficultyObj,
|
||||
success,
|
||||
bonus,
|
||||
});
|
||||
|
||||
@@ -690,7 +690,7 @@ export class DicePickerDialog extends FormApplication {
|
||||
type: "script",
|
||||
scope: "actor",
|
||||
command,
|
||||
img: this._actor?.img || "systems/l5r5e/assets/dices/default/ring_et.svg",
|
||||
img: this._actor?.img || "systems/l5rx-chiaroscuro/assets/dices/default/ring_et.svg",
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -73,11 +73,11 @@ export class GmMonitor extends HandlebarsApplicationMixin(ApplicationV2) {
|
||||
},
|
||||
character: {
|
||||
id: "character",
|
||||
template: "systems/l5r5e/templates/" + "gm/monitor/character-view.html"
|
||||
template: "systems/l5rx-chiaroscuro/templates/" + "gm/monitor/character-view.html"
|
||||
},
|
||||
army: {
|
||||
if: "army",
|
||||
template: "systems/l5r5e/templates/" + "gm/monitor/army-view.html"
|
||||
template: "systems/l5rx-chiaroscuro/templates/" + "gm/monitor/army-view.html"
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -44,7 +44,7 @@ export class GmToolbox extends HandlebarsApplicationMixin(ApplicationV2) {
|
||||
static PARTS = {
|
||||
main: {
|
||||
id: "gm-tool-content",
|
||||
template: "systems/l5r5e/templates/" + "gm/gm-toolbox.html"
|
||||
template: "systems/l5rx-chiaroscuro/templates/" + "gm/gm-toolbox.html"
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -90,12 +90,12 @@ export class AdvancementSheetL5r5e extends ItemSheetL5r5e {
|
||||
// Modify image to reflect choice
|
||||
if (newChoice.ring) {
|
||||
name = game.i18n.localize(`l5r5e.rings.${newChoice.ring}`) + "+1";
|
||||
img = `systems/l5r5e/assets/icons/rings/${newChoice.ring}.svg`;
|
||||
img = `systems/l5rx-chiaroscuro/assets/icons/rings/${newChoice.ring}.svg`;
|
||||
} else if (newChoice.skill) {
|
||||
name =
|
||||
game.i18n.localize(`l5r5e.skills.${CONFIG.l5r5e.skills.get(newChoice.skill)}.${newChoice.skill}`) +
|
||||
"+1";
|
||||
img = `systems/l5r5e/assets/dices/default/skill_blank.svg`;
|
||||
img = `systems/l5rx-chiaroscuro/assets/dices/default/skill_blank.svg`;
|
||||
}
|
||||
|
||||
// Object embed in actor ?
|
||||
|
||||
@@ -50,7 +50,7 @@ export class ItemSheetL5r5e extends BaseItemSheetL5r5e {
|
||||
id: property.id,
|
||||
name: property.name,
|
||||
type: "property",
|
||||
img: "systems/l5r5e/assets/icons/items/property.svg",
|
||||
img: "systems/l5rx-chiaroscuro/assets/icons/items/property.svg",
|
||||
removed: true,
|
||||
};
|
||||
}));
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
export const PreloadTemplates = async function () {
|
||||
const tpl = CONFIG.l5r5e.paths.templates;
|
||||
return foundry.applications.handlebars.loadTemplates([
|
||||
// Add paths to "systems/l5r5e/templates"
|
||||
// Add paths to "systems/l5rx-chiaroscuro/templates"
|
||||
// *** Actors : PC ***
|
||||
`${tpl}actors/character/advancement-school.html`,
|
||||
`${tpl}actors/character/advancement-others.html`,
|
||||
|
||||
@@ -43,7 +43,7 @@ export class TacticalGridSettingsL5R5E extends HandlebarsApplicationMixin(Applic
|
||||
/** @override */
|
||||
static PARTS = {
|
||||
form: {
|
||||
template: "systems/l5r5e/templates/" + "settings/tactical-grid-settings.html",
|
||||
template: "systems/l5rx-chiaroscuro/templates/" + "settings/tactical-grid-settings.html",
|
||||
scrollable: [""],
|
||||
},
|
||||
footer: {
|
||||
|
||||
@@ -11,7 +11,7 @@ function getRangeband(gridSettings, distance) {
|
||||
|
||||
export class RulerL5r5e extends foundry.canvas.interaction.Ruler {
|
||||
|
||||
static WAYPOINT_LABEL_TEMPLATE = "systems/l5r5e/templates/" + "hud/tactical-grid-ruler.html"
|
||||
static WAYPOINT_LABEL_TEMPLATE = "systems/l5rx-chiaroscuro/templates/" + "hud/tactical-grid-ruler.html"
|
||||
|
||||
/** @override */
|
||||
_getWaypointLabelContext(waypoint, state) {
|
||||
@@ -44,7 +44,7 @@ export class RulerL5r5e extends foundry.canvas.interaction.Ruler {
|
||||
}
|
||||
|
||||
export class TokenRulerL5r5e extends foundry.canvas.placeables.tokens.TokenRuler {
|
||||
static WAYPOINT_LABEL_TEMPLATE = "systems/l5r5e/templates/" + "hud/tactical-grid-ruler.html"
|
||||
static WAYPOINT_LABEL_TEMPLATE = "systems/l5rx-chiaroscuro/templates/" + "hud/tactical-grid-ruler.html"
|
||||
|
||||
/** @override */
|
||||
_getWaypointLabelContext(waypoint, state) {
|
||||
|
||||
Reference in New Issue
Block a user