Macros pour le corps à corps
Cas particulier car 3 utilisations possibles, et pas d'armes
This commit is contained in:
@ -220,6 +220,32 @@ export class RdDItem extends Item {
|
||||
isService() { return this.type == TYPES.service; }
|
||||
|
||||
isCompetence() { return typesObjetsCompetence.includes(this.type) }
|
||||
isEsquive() {
|
||||
return (this.isCompetence()
|
||||
&& this.system.categorie == 'melee'
|
||||
&& Grammar.includesLowerCaseNoAccent(this.name, 'Esquive'));
|
||||
}
|
||||
|
||||
isCorpsACorps() {
|
||||
return (this.isCompetence()
|
||||
&& this.system.categorie == 'melee'
|
||||
&& Grammar.includesLowerCaseNoAccent(this.name, 'Corps à Corps'));
|
||||
}
|
||||
|
||||
isCompetenceArme() {
|
||||
if (this.isCompetence()) {
|
||||
switch (this.system.categorie) {
|
||||
case 'melee':
|
||||
return !this.isCorpsACorps() && !this.isEsquive()
|
||||
case 'tir':
|
||||
case 'lancer':
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
isCompetencePossession() { return TYPES.competencecreature == this.type && this.system.categorie == "possession" }
|
||||
isTemporel() { return typesObjetsTemporels.includes(this.type) }
|
||||
isOeuvre() { return typesObjetsOeuvres.includes(this.type) }
|
||||
|
Reference in New Issue
Block a user