Fix: ignorer personnages joueurs non liés

Pour les fenêtres de stress/repos/voyage/astrologie, ignorer
les personnages non liés (par exemple, un guerrier sorde)
This commit is contained in:
2024-03-09 23:12:13 +01:00
parent dde3011f1d
commit 6414f76d67
8 changed files with 15 additions and 13 deletions

View File

@ -85,6 +85,8 @@ export class RdDBaseActor extends Actor {
return game.actors.get(actorId)
}
isPersonnageJoueur() { return false }
static extractActorMin = (actor) => { return { id: actor?.id, type: actor?.type, name: actor?.name, img: actor?.img }; };
static getParentActor(document) {

View File

@ -12,7 +12,7 @@ export const XP_TOPIC = {
export class ExperienceLog {
static async add(actor, topic, from, to, raison, manuel = false) {
if (!actor.hasPlayerOwner || !actor.isPersonnage()) {
if (!actor.isPersonnageJoueur()) {
return
}
if (from == to) {