Fix compteur d'utilisations d'esquive
This commit is contained in:
parent
4b1573ab8b
commit
c76bf912d1
@ -833,7 +833,7 @@ export class RdDCombat {
|
||||
// # utilisation esquive
|
||||
const corpsACorps = this.defender.getCompetence("Corps à corps", { onMessage: it => console.info(it, this.defender) });
|
||||
const esquives = duplicate(this.defender.getCompetences("esquive", { onMessage: it => console.info(it, this.defender) }))
|
||||
esquives.forEach(e => e.usages = e?.id ? this.defender.getItemUse(e.id) : 0);
|
||||
esquives.forEach(e => e.system.nbUsage = e?._id ? this.defender.getItemUse(e._id) : 0);
|
||||
|
||||
const paramChatDefense = {
|
||||
passeArme: attackerRoll.passeArme,
|
||||
|
@ -50,10 +50,11 @@
|
||||
<br>
|
||||
{{/if}}
|
||||
{{#if (ne attaqueCategorie 'tir')}}
|
||||
{{#each esquives as |esq key|}}
|
||||
{{#each esquives as |esquive key|}}
|
||||
<a class='chat-card-button' id='esquiver-button' data-attackerId='{{../attackerId}}' data-defenderTokenId='{{../defenderTokenId}}'
|
||||
data-compid='{{esq._id}}' data-competence='{{esq.name}}'>
|
||||
{{esq.name}} à {{../diffLibre}} {{#if esq.usage}} (Utilisations : {{esq.usage}}){{/if}}
|
||||
data-compid='{{esquive._id}}' data-competence='{{esquive.name}}'>
|
||||
{{log 'esquive' esquive}}
|
||||
{{esquive.name}} à {{../diffLibre}} {{#if esquive.system.nbUsage}} (Utilisations : {{esquive.system.nbUsage}}){{/if}}
|
||||
</a>
|
||||
<br>
|
||||
{{/each}}
|
||||
|
Loading…
Reference in New Issue
Block a user