Rename TYPES en ITEM_TYPES

Pour ajouter les ACTOR_TYPES
This commit is contained in:
2024-09-25 22:56:24 +02:00
parent c586a90690
commit 52e1f9dfbf
21 changed files with 181 additions and 167 deletions

View File

@ -1,5 +1,5 @@
import { ENTITE_INCARNE, ENTITE_NONINCARNE } from "../constants.js";
import { TYPES } from "../item.js";
import { ITEM_TYPES } from "../item.js";
import { Misc } from "../misc.js";
import { RdDEncaisser } from "../rdd-roll-encaisser.js";
import { STATUSES } from "../settings/status-effects.js";
@ -12,7 +12,7 @@ export class RdDEntite extends RdDBaseActorReve {
}
canReceive(item) {
return item.type == TYPES.competencecreature
return item.type == ITEM_TYPES.competencecreature
}
isEntite(typeentite = []) {
@ -29,7 +29,7 @@ export class RdDEntite extends RdDBaseActorReve {
getChance() { return this.getReve() }
getDraconicOuPossession() {
return this.itemTypes[TYPES.competencecreature]
return this.itemTypes[ITEM_TYPES.competencecreature]
.filter(it => it.system.categorie == 'possession')
.sort(Misc.descending(it => it.system.niveau))
.find(it => true);