Ajout de la fenêtre de thème astral
Accessible par macro/depuis les fenêtres d'astrologie
This commit is contained in:
@ -257,6 +257,7 @@ export class RdDCalendrier extends Application {
|
||||
}
|
||||
this.listeNombreAstral = newList;
|
||||
game.settings.set(SYSTEM_RDD, "liste-nombre-astral", newList);
|
||||
game.actors.forEach(actor => actor.deleteEmbeddedDocuments("Item", actor.listItems('nombreastral').map(it => it.id)));
|
||||
}
|
||||
}
|
||||
|
||||
@ -301,7 +302,7 @@ export class RdDCalendrier extends Application {
|
||||
async positionnerHeure(heure) {
|
||||
const indexDate = this.timestamp.indexDate;
|
||||
const addDay = this.timestamp.heure < heure ? 0 : 1;
|
||||
const newTimestamp = new RdDTimestamp({ indexDate: indexDate + addDay}).addHeures(heure);
|
||||
const newTimestamp = new RdDTimestamp({ indexDate: indexDate + addDay }).addHeures(heure);
|
||||
await this.setNewTimestamp(newTimestamp)
|
||||
}
|
||||
|
||||
@ -370,10 +371,6 @@ export class RdDCalendrier extends Application {
|
||||
game.settings.set(SYSTEM_RDD, "liste-nombre-astral", this.listeNombreAstral);
|
||||
}
|
||||
|
||||
static ecartHeureChance(heureNaissance, nombreAstral, heure) {
|
||||
return (heureNaissance + nombreAstral - heure) % RDD_HEURES_PAR_JOUR;
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
getAjustementAstrologique(heureNaissance, name = undefined) {
|
||||
let defHeure = RdDTimestamp.findHeure(heureNaissance);
|
||||
@ -399,6 +396,10 @@ export class RdDCalendrier extends Application {
|
||||
return 0;
|
||||
}
|
||||
|
||||
static ecartHeureChance(heureNaissance, nombreAstral, heure) {
|
||||
return ((heureNaissance + nombreAstral - heure) % RDD_HEURES_PAR_JOUR + RDD_HEURES_PAR_JOUR) % RDD_HEURES_PAR_JOUR;
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
getData() {
|
||||
let formData = super.getData();
|
||||
|
Reference in New Issue
Block a user