Fix détermination nombre astral
fixé, déplacé dans les savoirs # Conflicts: # module/rdd-calendrier.js # templates/actor-sheet.html
This commit is contained in:
parent
08cf1f49e1
commit
ac8610cd6c
@ -247,21 +247,19 @@ export class RdDCalendrier extends Application {
|
|||||||
console.log(request);
|
console.log(request);
|
||||||
let jourDiff = this.getLectureAstrologieDifficulte(request.date);
|
let jourDiff = this.getLectureAstrologieDifficulte(request.date);
|
||||||
let niveau = Number(request.astrologie.data.niveau) + Number(request.conditions) + Number(jourDiff) + Number(request.etat);
|
let niveau = Number(request.astrologie.data.niveau) + Number(request.conditions) + Number(jourDiff) + Number(request.etat);
|
||||||
let rolled = await RdDResolutionTable.rollData({
|
let rollData= {
|
||||||
caracValue: request.carac_vue,
|
caracValue: request.carac_vue,
|
||||||
finalLevel: niveau,
|
finalLevel: niveau,
|
||||||
showDice: false
|
showDice: false
|
||||||
});
|
};
|
||||||
|
await RdDResolutionTable.rollData(rollData);
|
||||||
let nbAstral = this.getNombreAstral(request.date);
|
let nbAstral = this.getNombreAstral(request.date);
|
||||||
let nbAstralFaux = nbAstral;
|
request.rolled = rollData.rolled;
|
||||||
request.isValid = true;
|
request.isValid = true;
|
||||||
request.rolled = rolled;
|
if (!request.rolled.isSuccess) {
|
||||||
if (!rolled.isSuccess) {
|
|
||||||
request.isValid = false;
|
request.isValid = false;
|
||||||
while (nbAstralFaux == nbAstral) {
|
let nbAstralFaux = new Roll("1d11").evaluate().total;
|
||||||
nbAstralFaux = new Roll("1d12").roll().total;
|
nbAstral = nbAstral==nbAstralFaux ? 12 : nbAstralFaux;
|
||||||
}
|
|
||||||
nbAstral = nbAstralFaux;
|
|
||||||
// Mise à jour des nombres astraux du joueur
|
// Mise à jour des nombres astraux du joueur
|
||||||
let astralData = this.listeNombreAstral.find((nombreAstral, i) => nombreAstral.index == request.date);
|
let astralData = this.listeNombreAstral.find((nombreAstral, i) => nombreAstral.index == request.date);
|
||||||
astralData.valeursFausses.push({ actorId: request.id, nombreAstral: nbAstralFaux });
|
astralData.valeursFausses.push({ actorId: request.id, nombreAstral: nbAstralFaux });
|
||||||
|
@ -461,8 +461,19 @@
|
|||||||
|
|
||||||
{{!-- Connaissances Tab --}}
|
{{!-- Connaissances Tab --}}
|
||||||
<div class="tab connaissances" data-group="primary" data-tab="connaissances">
|
<div class="tab connaissances" data-group="primary" data-tab="connaissances">
|
||||||
<span class="item-name"><a class="creer-une-oeuvre">Créer une oeuvre</a></span>
|
<h3>Tâches</h3><a class='creer-tache'>Créer une nouvelle Tâche</a>
|
||||||
<h3>Oeuvres diverses :</h3>
|
<ul class="item-list alterne-list">
|
||||||
|
{{#each taches as |tache id|}}
|
||||||
|
<li class="item flexrow list-item" data-item-id="{{tache._id}}"><span class="competence-title tache-label"><a>{{tache.name}} ({{tache.data.points_de_tache_courant}}/{{tache.data.points_de_tache}})</a></span>
|
||||||
|
<div class="item-controls">
|
||||||
|
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
|
||||||
|
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
<hr>
|
||||||
|
<h3>Oeuvres diverses :</h3><a class="creer-une-oeuvre">Créer une oeuvre</a>
|
||||||
<ul class="item-list alterne-list">
|
<ul class="item-list alterne-list">
|
||||||
{{#each data.chants as |chant id|}}
|
{{#each data.chants as |chant id|}}
|
||||||
<li class="item flexrow list-item" data-item-id="{{chant._id}}"><span>Chant</span><span class="competence-title chant-label"><a>{{chant.name}} (niveau {{chant.data.niveau}})</a></span>
|
<li class="item flexrow list-item" data-item-id="{{chant._id}}"><span>Chant</span><span class="competence-title chant-label"><a>{{chant.name}} (niveau {{chant.data.niveau}})</a></span>
|
||||||
@ -527,18 +538,9 @@
|
|||||||
</li>
|
</li>
|
||||||
{{/each}}
|
{{/each}}
|
||||||
</ul>
|
</ul>
|
||||||
<h3>Tâches</h3><a class='creer-tache'>Créer une nouvelle Tâche</a>
|
|
||||||
<ul class="item-list alterne-list">
|
|
||||||
{{#each data.taches as |tache id|}}
|
|
||||||
<li class="item flexrow list-item" data-item-id="{{tache._id}}"><span class="competence-title tache-label"><a>{{tache.name}} ({{tache.data.points_de_tache_courant}}/{{tache.data.points_de_tache}})</a></span>
|
|
||||||
<div class="item-controls">
|
|
||||||
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
|
|
||||||
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
|
|
||||||
</div>
|
|
||||||
</li>
|
|
||||||
{{/each}}
|
|
||||||
</ul>
|
|
||||||
<hr>
|
<hr>
|
||||||
|
<h3>Astrologie</h3>
|
||||||
|
<span class="astrologie-label"><a id="jet-astrologie">Astrologie : Nombres Astraux</a></span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{!-- hautreve Tab --}}
|
{{!-- hautreve Tab --}}
|
||||||
@ -576,9 +578,6 @@
|
|||||||
{{/if}}
|
{{/if}}
|
||||||
</span>
|
</span>
|
||||||
</li>
|
</li>
|
||||||
<li class="item flexrow" >
|
|
||||||
<span class="astrologie-label"><a id="jet-astrologie">Astrologie : Nombres Astraux</a></span>
|
|
||||||
</li>
|
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<hr>
|
<hr>
|
||||||
|
Loading…
Reference in New Issue
Block a user