Remove some unnecessary checks.

This commit is contained in:
Nathaniel Brandes 2017-03-09 23:39:50 -08:00
parent 900d68f77d
commit 74b9f0eb24
3 changed files with 3 additions and 3 deletions

View file

@ -105,7 +105,7 @@ class HeraldOfWarCostReductionEffect extends CostModificationEffectImpl {
@Override
public boolean applies(Ability abilityToModify, Ability source, Game game) {
if (abilityToModify instanceof SpellAbility || abilityToModify instanceof FlashbackAbility) {
if (abilityToModify instanceof SpellAbility) {
Card sourceCard = game.getCard(abilityToModify.getSourceId());
if (sourceCard != null && abilityToModify.getControllerId().equals(source.getControllerId()) && (sourceCard.hasSubtype("Angel", game) || sourceCard.hasSubtype("Human", game))) {
return true;

View file

@ -94,7 +94,7 @@ class KaerveksTorchCostIncreaseEffect extends CostModificationEffectImpl {
@Override
public boolean applies(Ability abilityToModify, Ability source, Game game) {
if (abilityToModify instanceof SpellAbility || abilityToModify instanceof FlashbackAbility) {
if (abilityToModify instanceof SpellAbility) {
for (UUID modeId : abilityToModify.getModes().getSelectedModes()) {
Mode mode = abilityToModify.getModes().get(modeId);
for (Target target : mode.getTargets()) {

View file

@ -89,7 +89,7 @@ class TrinisphereEffect extends CostModificationEffectImpl {
@Override
public boolean applies(Ability abilityToModify, Ability source, Game game) {
if ((abilityToModify instanceof SpellAbility || abilityToModify instanceof FlashbackAbility)) {
if (abilityToModify instanceof SpellAbility) {
Permanent permanent = game.getPermanent(source.getSourceId());
return permanent != null && !permanent.isTapped();
}