Utilisation du token.name au lieu d'actor.name

Pour permettre de masquer les informations sur les
PNJs secondaires, et ne pas dévoiler le nom de l'acteur
This commit is contained in:
2024-11-15 00:01:55 +01:00
parent 45e9e94646
commit dca9505925
25 changed files with 75 additions and 62 deletions

View File

@ -181,7 +181,7 @@ export class RdDActor extends RdDBaseActorSang {
whisper: ChatUtility.getOwners(this),
content: await renderTemplate(`systems/foundryvtt-reve-de-dragon/templates/chat-potionenchantee-chateaudormant.html`, {
pr: nouveauReve,
alias: this.name,
alias: this.getAlias(),
potionName: it.name,
potionImg: it.img
})
@ -1341,7 +1341,7 @@ export class RdDActor extends RdDBaseActorSang {
const etat = this.getEtatGeneral({ ethylisme: true });
const nbDoses = Number(this.system.compteurs.ethylisme.nb_doses || 0);
const ethylismeData = {
alias: this.name,
alias: this.getAlias(),
actor: this,
vie: this.system.sante.vie.max,
alcool: alcool,
@ -1426,7 +1426,7 @@ export class RdDActor extends RdDBaseActorSang {
const perteDissolution = Math.max(0, Math.min(dissolution, conversion));
let stressRollData = {
alias: this.name,
alias: this.getAlias(),
selectedCarac: this.system.carac.reve,
rolled: stressRoll,
stress: fromStress,
@ -1517,7 +1517,7 @@ export class RdDActor extends RdDBaseActorSang {
carac.value = niveauSuivant;
let checkXp = {
alias: this.name,
alias: this.getAlias(),
carac: caracName,
value: niveauSuivant,
xp: carac.xp
@ -1547,7 +1547,7 @@ export class RdDActor extends RdDBaseActorSang {
newCompData.system.niveau += 1;
newCompData.system.xp = newXP;
let checkXp = {
alias: this.name,
alias: this.getAlias(),
competence: newCompData.name,
niveau: newCompData.system.niveau,
xp: newCompData.system.xp,
@ -1784,7 +1784,7 @@ export class RdDActor extends RdDBaseActorSang {
}
const competence = this.getCompetence(compName);
let rollData = {
alias: this.name,
alias: this.getAlias(),
caracValue: Number(carac.value),
selectedCarac: carac,
competence: competence,
@ -1857,7 +1857,7 @@ export class RdDActor extends RdDBaseActorSang {
label: 'Jet ' + Grammar.apostrophe('de', competence.name),
template: 'systems/foundryvtt-reve-de-dragon/templates/dialog-roll-competence.html',
rollData: {
alias: this.name,
alias: this.getAlias(),
carac: this.system.carac,
selectedCarac: this.getCaracByName(caracName),
selectedCaracName: caracName,
@ -2930,7 +2930,7 @@ export class RdDActor extends RdDBaseActorSang {
let newQuantite = herbeData.system.quantite - herbeData.nbBrins;
let messageData = {
alias: this.name,
alias: this.getAlias(),
nbBrinsReste: newQuantite,
potion: newPotion,
herbe: herbeData