Skip to content

Commit

Permalink
fix hasCondition again
Browse files Browse the repository at this point in the history
  • Loading branch information
moo-man committed Dec 6, 2023
1 parent bac4f2b commit 31e3087
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions scripts/actor/actor.js
Original file line number Diff line number Diff line change
Expand Up @@ -704,8 +704,7 @@ export class WrathAndGloryActor extends Actor {
get faction() { return this.getItemTypes("faction")[0] }

hasCondition(conditionKey) {
let existing = this.effects.find(e => e.statuses.has(conditionKey))
return existing
return this.statuses.has(conditionKey)
}

hasKeyword(keyword) {
Expand Down
2 changes: 1 addition & 1 deletion scripts/item/item.js
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ export class WrathAndGloryItem extends Item {


hasCondition(conditionKey) {
let existing = this.effects.statuses.has(conditionKey)
let existing = this.effects.find(e => e.statuses.has(conditionKey))
return existing
}

Expand Down

0 comments on commit 31e3087

Please sign in to comment.