forked from public/foundryvtt-reve-de-dragon
Various fixes for v12
This commit is contained in:
@ -991,9 +991,7 @@ export class RdDActor extends RdDBaseActorSang {
|
||||
|
||||
/* -------------------------------------------- */
|
||||
buildTMRInnaccessible() {
|
||||
return this.items[TYPES.casetmr]
|
||||
.filter(it => EffetsDraconiques.isInnaccessible(it))
|
||||
.map(it => it.system.coord)
|
||||
return this.items.filter(it => it.type == TYPES.casetmr).filter(it => EffetsDraconiques.isInnaccessible(it)).map(it => it.system.coord)
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
|
@ -108,8 +108,8 @@ export class RdDItemSheet extends ItemSheet {
|
||||
const competences = await SystemCompendiums.getCompetences('personnage');
|
||||
formData.categories = this.item.getCategories()
|
||||
if (this.item.type == 'tache' || this.item.type == 'livre' || this.item.type == 'meditation' || this.item.type == 'oeuvre') {
|
||||
formData.caracList = foundry.utils.duplicate(game.system.model.Actor.personnage.carac)
|
||||
formData.caracList["reve-actuel"] = foundry.utils.duplicate(game.system.model.Actor.personnage.reve.reve)
|
||||
formData.caracList = foundry.utils.duplicate(game.model.Actor.personnage.carac)
|
||||
formData.caracList["reve-actuel"] = foundry.utils.duplicate(game.model.Actor.personnage.reve.reve)
|
||||
formData.competences = competences;
|
||||
}
|
||||
if (this.item.type == 'arme') {
|
||||
|
@ -567,7 +567,7 @@ export class Migrations {
|
||||
if (currentVersion.startsWith("v")) {
|
||||
currentVersion = currentVersion.substring(1)
|
||||
}
|
||||
if (isNewerVersion(game.system.version, currentVersion)) {
|
||||
if (foundry.utils.isNewerVersion(game.system.version, currentVersion)) {
|
||||
// if (true) { /* comment previous and uncomment here to test before upgrade */
|
||||
const migrations = Migrations.getMigrations().filter(m => isNewerVersion(m.version, currentVersion));
|
||||
if (migrations.length > 0) {
|
||||
|
@ -17,7 +17,7 @@ export class AutoAdjustDarkness {
|
||||
static async adjust(darkness) {
|
||||
if (AutoAdjustDarkness.isAuto()) {
|
||||
const scene = game.scenes.viewed;
|
||||
if (scene?.globalLight && scene?.tokenVision) {
|
||||
if (scene?.environment?.globalLight?.enabled && scene?.tokenVision) {
|
||||
await scene.update({ darkness });
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user