diff --git a/lang/fr.json b/lang/fr.json index 3e6d769..fc5be0f 100644 --- a/lang/fr.json +++ b/lang/fr.json @@ -182,7 +182,8 @@ "BOL.ui.armornoformula": "L'armure {protect.name} n'a pas de formule pour la protection !", "BOL.ui.selectactor": "Selectionnez votre personnage pour utiliser la macro", "BOL.ui.itemnotfound": "Impossible de trouver l'objet de cette macro", - + "BOL.ui.noinit": "Pas d'initiative trouvée, veuillez en enregistrer une.", + "BOL.featureCategory.origins": "Origines", "BOL.featureCategory.races": "Races", "BOL.featureCategory.careers": "Carrières", diff --git a/module/actor/actor.js b/module/actor/actor.js index cffba07..79b4da5 100644 --- a/module/actor/actor.js +++ b/module/actor/actor.js @@ -656,25 +656,28 @@ export class BoLActor extends Actor { /*-------------------------------------------- */ getInitiativeRank() { let rollData = this.getFlag("world", "last-initiative") - let fvttInit = 5 - if (this.type == 'character') { - if (rollData.isLegendary) { - fvttInit = 10 - } else if (rollData.isCritical) { - fvttInit = 9 - } else if (rollData.isSuccess ) { - fvttInit = 8 - } else if (rollData.isFumble) { - fvttInit = 3 + let fvttInit = 4 // Pietaille par defaut + if (this.type == 'character' ) { + fvttInit = 5 + if (!rollData) { + fvttInit = -1 + } else { + if (rollData.isLegendary) { + fvttInit = 10 + } else if (rollData.isCritical) { + fvttInit = 9 + } else if (rollData.isSuccess ) { + fvttInit = 8 + } else if (rollData.isFumble) { + fvttInit = 3 + } } - } else { - fvttInit = 4 // Pietaille par defautco - if ( this.getCharType() == 'adversary') { - fvttInit = 7 - } - if ( this.getCharType() == 'tough') { - fvttInit = 6 - } + } + if ( this.getCharType() == 'adversary') { + fvttInit = 7 + } + if ( this.getCharType() == 'tough') { + fvttInit = 6 } return fvttInit } diff --git a/system.json b/system.json index b74dffc..d8d2109 100644 --- a/system.json +++ b/system.json @@ -14,7 +14,7 @@ ], "url": "https://www.uberwald.me/gitea/public/bol", "license": "LICENSE.txt", - "version": "10.4.8", + "version": "10.4.9", "compatibility": { "minimum": "10", "verified": "10", @@ -203,7 +203,7 @@ ], "socket": true, "manifest": "https://www.uberwald.me/gitea/public/bol/raw/v10/system.json", - "download": "https://www.uberwald.me/gitea/public/bol/archive/bol-v10.4.8.zip", + "download": "https://www.uberwald.me/gitea/public/bol/archive/bol-v10.4.9.zip", "background": "systems/images/map_lemurie.webp", "gridDistance": 1.5, "gridUnits": "m",