Added Skill assistance used indicator
This commit is contained in:
@@ -87,6 +87,7 @@
|
|||||||
"difficulty_hidden": "TN ???",
|
"difficulty_hidden": "TN ???",
|
||||||
"dicepicker": "Dice Picker",
|
"dicepicker": "Dice Picker",
|
||||||
"void_point_used": "Void point used",
|
"void_point_used": "Void point used",
|
||||||
|
"assistance_used": "Skill assistance used",
|
||||||
"roll_n_keep": "Roll & Keep",
|
"roll_n_keep": "Roll & Keep",
|
||||||
"initiative_roll": "Initiative roll",
|
"initiative_roll": "Initiative roll",
|
||||||
"success_text": "Success!",
|
"success_text": "Success!",
|
||||||
|
|||||||
@@ -87,6 +87,7 @@
|
|||||||
"difficulty_hidden": "NO ???",
|
"difficulty_hidden": "NO ???",
|
||||||
"dicepicker": "Dice Picker",
|
"dicepicker": "Dice Picker",
|
||||||
"void_point_used": "Punto de vacío utilizado",
|
"void_point_used": "Punto de vacío utilizado",
|
||||||
|
"assistance_used": "Skill assistance used",
|
||||||
"roll_n_keep": "Tirar y guardar",
|
"roll_n_keep": "Tirar y guardar",
|
||||||
"initiative_roll": "Tirada de Iniciativa",
|
"initiative_roll": "Tirada de Iniciativa",
|
||||||
"success_text": "Éxitos!",
|
"success_text": "Éxitos!",
|
||||||
|
|||||||
@@ -87,6 +87,7 @@
|
|||||||
"difficulty_hidden": "ND ???",
|
"difficulty_hidden": "ND ???",
|
||||||
"dicepicker": "Dice Picker",
|
"dicepicker": "Dice Picker",
|
||||||
"void_point_used": "Point de vide utilisé",
|
"void_point_used": "Point de vide utilisé",
|
||||||
|
"assistance_used": "Assistance de compétence utilisée",
|
||||||
"roll_n_keep": "Roll & Keep",
|
"roll_n_keep": "Roll & Keep",
|
||||||
"initiative_roll": "Jet d'initiative",
|
"initiative_roll": "Jet d'initiative",
|
||||||
"success_text": "Succès !",
|
"success_text": "Succès !",
|
||||||
|
|||||||
@@ -211,10 +211,12 @@ export class RollnKeepDialog extends FormApplication {
|
|||||||
this.object.submitDisabled = kept < 1 || kept > this.roll.l5r5e.keepLimit;
|
this.object.submitDisabled = kept < 1 || kept > this.roll.l5r5e.keepLimit;
|
||||||
} else if (!this.object.dicesList[this.object.currentStep]) {
|
} else if (!this.object.dicesList[this.object.currentStep]) {
|
||||||
this.options.editable = false;
|
this.options.editable = false;
|
||||||
|
this.options.classes.push("finalized");
|
||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
...super.getData(options),
|
...super.getData(options),
|
||||||
|
cssClass: this.options.classes.join(" "),
|
||||||
data: this.object,
|
data: this.object,
|
||||||
l5r5e: this.message._roll.l5r5e,
|
l5r5e: this.message._roll.l5r5e,
|
||||||
};
|
};
|
||||||
@@ -508,8 +510,13 @@ export class RollnKeepDialog extends FormApplication {
|
|||||||
async _rebuildRoll() {
|
async _rebuildRoll() {
|
||||||
// Get all kept dices + new (choice null)
|
// Get all kept dices + new (choice null)
|
||||||
const diceList = this.object.dicesList.reduce((acc, step, stepIdx) => {
|
const diceList = this.object.dicesList.reduce((acc, step, stepIdx) => {
|
||||||
|
const haveReroll = stepIdx > 0 && this._haveChoice(stepIdx - 1, RollnKeepDialog.CHOICES.reroll);
|
||||||
step.forEach((die, idx) => {
|
step.forEach((die, idx) => {
|
||||||
if (!!die && [RollnKeepDialog.CHOICES.keep, RollnKeepDialog.CHOICES.nothing].includes(die.choice)) {
|
if (
|
||||||
|
!!die &&
|
||||||
|
(die.choice === RollnKeepDialog.CHOICES.keep ||
|
||||||
|
(haveReroll && die.choice === RollnKeepDialog.CHOICES.nothing))
|
||||||
|
) {
|
||||||
if (!acc[die.type]) {
|
if (!acc[die.type]) {
|
||||||
acc[die.type] = [];
|
acc[die.type] = [];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -26,8 +26,12 @@
|
|||||||
{{else}}
|
{{else}}
|
||||||
{{localize 'l5r5e.chatdices.difficulty'}} {{l5r5e.difficulty}}
|
{{localize 'l5r5e.chatdices.difficulty'}} {{l5r5e.difficulty}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
<br>
|
||||||
{{#if l5r5e.voidPointUsed}}
|
{{#if l5r5e.voidPointUsed}}
|
||||||
<br><i class="i_void" title="{{localize 'l5r5e.chatdices.void_point_used'}}"></i>
|
<i class="i_void" title="{{localize 'l5r5e.chatdices.void_point_used'}}"></i>
|
||||||
|
{{/if}}
|
||||||
|
{{#if l5r5e.skillAssistance}}
|
||||||
|
<i class="i_skill" title="{{l5r5e.skillAssistance}}x {{localize 'l5r5e.chatdices.assistance_used'}}"></i>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</span>
|
</span>
|
||||||
</header>
|
</header>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<form class="l5r5e roll-n-keep-dialog" autocomplete="off">
|
<form class="{{cssClass}}" autocomplete="off">
|
||||||
{{!-- Profil --}}
|
{{!-- Profil --}}
|
||||||
<div class="l5r5e profil">
|
<div class="l5r5e profil">
|
||||||
<header class="part-header flexrow chat-profil">
|
<header class="part-header flexrow chat-profil">
|
||||||
@@ -30,8 +30,12 @@
|
|||||||
{{else}}
|
{{else}}
|
||||||
{{localize 'l5r5e.chatdices.difficulty'}} {{l5r5e.difficulty}}
|
{{localize 'l5r5e.chatdices.difficulty'}} {{l5r5e.difficulty}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
<br>
|
||||||
{{#if l5r5e.voidPointUsed}}
|
{{#if l5r5e.voidPointUsed}}
|
||||||
<br><i class="i_void" title="{{localize 'l5r5e.chatdices.void_point_used'}}"></i>
|
<i class="i_void" title="{{localize 'l5r5e.chatdices.void_point_used'}}"></i>
|
||||||
|
{{/if}}
|
||||||
|
{{#if l5r5e.skillAssistance}}
|
||||||
|
<i class="i_skill" title="{{l5r5e.skillAssistance}}x {{localize 'l5r5e.chatdices.assistance_used'}}"></i>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</span>
|
</span>
|
||||||
</header>
|
</header>
|
||||||
|
|||||||
Reference in New Issue
Block a user