Welcome page and init info message

This commit is contained in:
2022-12-23 16:38:41 +01:00
parent d74f7784bb
commit 7a8cf9f8fd
6 changed files with 25 additions and 5005 deletions

View File

@ -663,15 +663,23 @@ export class BoLActor extends Actor {
}
/*-------------------------------------------- */
getInitiativeRank(rollData = undefined) {
clearInitiative() {
this.unsetFlag("world", "last-initiative" )
}
/*-------------------------------------------- */
getInitiativeRank(rollData = undefined, isCombat = false) {
if (!rollData) {
rollData = this.getFlag("world", "last-initiative")
}
let fvttInit = 4 // Pietaille par defaut
if (this.type == 'character' ) {
fvttInit = 5
if (!rollData) {
if (!rollData) {
fvttInit = -1
if ( isCombat ) {
ui.notifications.warn(game.i18n.localize("BOL.ui.warninitiative"))
}
} else {
if (rollData.isLegendary) {
fvttInit = 10