Use ComputerUtilAbility.isFullyTargetable() and add more tests.

This commit is contained in:
asvitkine
2022-12-23 20:28:05 -07:00
parent 74a37c95c4
commit eb0f426adc
5 changed files with 52 additions and 14 deletions

View File

@@ -1655,16 +1655,6 @@ public abstract class SpellAbility extends CardTraitBase implements ISpellAbilit
return targetRestrictions != null;
}
public boolean hasLegalTargets() {
if (!isTargetNumberValid() && getTargetRestrictions().getNumCandidates(this, true) == 0) {
return false;
}
if (!StaticAbilityMustTarget.meetsMustTargetRestriction(this)) {
return false;
}
return true;
}
public TargetRestrictions getTargetRestrictions() {
return targetRestrictions;
}