forked from public/foundryvtt-reve-de-dragon
Recherche dans l'inventaire
Par nom ou par type, et dans les contenants
This commit is contained in:
@ -304,6 +304,13 @@ export class RdDItem extends Item {
|
||||
return this.parent?.type == 'commerce';
|
||||
}
|
||||
|
||||
isNomLike(texte) {
|
||||
return Grammar.includesLowerCaseNoAccent(this.name, texte)
|
||||
}
|
||||
isNomTypeLike(texte) {
|
||||
return this.isNomLike(texte) || Grammar.includesLowerCaseNoAccent(Misc.typeName(this.type, 'Item'), texte)
|
||||
}
|
||||
|
||||
getQuantite() {
|
||||
return this.isService() ? undefined : Math.round(this.system.quantite ?? 0)
|
||||
}
|
||||
|
Reference in New Issue
Block a user