Merge branch 'dev_1.1' of gitlab.com:LeRatierBretonnien/foundryvtt-reve-de-dragon into dev_1.1
This commit is contained in:
@@ -1630,7 +1630,7 @@ export class RdDActor extends Actor {
|
||||
return 0;
|
||||
}
|
||||
// selon l'heure de naissance...
|
||||
return game.system.rdd.calendrier.getAjustementAstrologique(this.data.data.heure);
|
||||
return game.system.rdd.calendrier.getAjustementAstrologique(this.data.data.heure, this.data.name);
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
checkDesirLancinant( ) {
|
||||
@@ -1914,6 +1914,7 @@ export class RdDActor extends Actor {
|
||||
this.updateEmbeddedEntity("OwnedItem", update);
|
||||
}
|
||||
}
|
||||
protection = Math.max(protection - Misc.toInt(arme.data.penetration), 0);
|
||||
protection += this.getProtectionNaturelle();
|
||||
console.log("Final protect", protection);
|
||||
return protection;
|
||||
@@ -1932,7 +1933,7 @@ export class RdDActor extends Actor {
|
||||
dmg: attackerRoll.dmg.total,
|
||||
armure: armure
|
||||
}).roll();
|
||||
RdDDice.show(rollEncaissement, )
|
||||
RdDDice.show(rollEncaissement);
|
||||
let result = RdDUtility.computeBlessuresSante(rollEncaissement.total, attackerRoll.mortalite, attackerRoll.dmg.loc);
|
||||
result.endurance = Math.max(result.endurance, -Number(this.data.data.sante.endurance.value));
|
||||
await this.santeIncDec("vie", result.vie);
|
||||
|
@@ -264,19 +264,24 @@ export class RdDCalendrier extends Application {
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
getAjustementAstrologique(heureNaissance)
|
||||
getAjustementAstrologique(heureNaissance, name='inconnu')
|
||||
{
|
||||
let hn = heuresDef[heureNaissance].heure;
|
||||
let chiffreAstral = this.getCurrentNombreAstral();
|
||||
let heureCourante = this.calendrier.heureRdD;
|
||||
let ecartChance = (hn + chiffreAstral - heureCourante)%12;
|
||||
console.log("ajustementAstrologique", heureNaissance, hn, chiffreAstral, heureCourante, ecartChance);
|
||||
switch (ecartChance)
|
||||
{
|
||||
case 0: return 4;
|
||||
case 4: case 8: return 2;
|
||||
case 6: return -4;
|
||||
case 3: case 9: return -2;
|
||||
if (heureNaissance && heuresDef[heureNaissance]) {
|
||||
let hn = heuresDef[heureNaissance].heure;
|
||||
let chiffreAstral = this.getCurrentNombreAstral();
|
||||
let heureCourante = this.calendrier.heureRdD;
|
||||
let ecartChance = (hn + chiffreAstral - heureCourante)%12;
|
||||
console.log("ajustementAstrologique", heureNaissance, hn, chiffreAstral, heureCourante, ecartChance);
|
||||
switch (ecartChance)
|
||||
{
|
||||
case 0: return 4;
|
||||
case 4: case 8: return 2;
|
||||
case 6: return -4;
|
||||
case 3: case 9: return -2;
|
||||
}
|
||||
}
|
||||
else {
|
||||
ui.notifications.warn(, this.data.name + " n'a pas d'heure de naissance, ou elle est incorrecte");
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
@@ -396,7 +396,7 @@ export class RdDCombat {
|
||||
console.log("RdDCombat._onParadeEchec >>>", rollData);
|
||||
|
||||
let explications = "<br><strong>Parade échouée, encaissement !</strong> ";
|
||||
explications += this.descriptionSurprise(rollData.surprise);
|
||||
explications += RdDCombat.descriptionSurprise(rollData.surprise);
|
||||
if (rollData.needSignificative) {
|
||||
explications += " Significative nécessaire!";
|
||||
}
|
||||
|
@@ -155,7 +155,7 @@ Hooks.once("init", async function() {
|
||||
"standard": "Standard",
|
||||
"experimental": "Expérimental"
|
||||
},
|
||||
default: "standard"
|
||||
default: "experimental"
|
||||
});
|
||||
|
||||
/* -------------------------------------------- */
|
||||
|
Reference in New Issue
Block a user