forked from External/mage
AddCardSubtypeAllEffect uses SubType enum
This commit is contained in:
parent
19a8f3c4c1
commit
2ca7927580
7 changed files with 13 additions and 27 deletions
|
|
@ -27,7 +27,6 @@
|
|||
*/
|
||||
package mage.game.permanent;
|
||||
|
||||
import java.util.*;
|
||||
import mage.MageObject;
|
||||
import mage.MageObjectReference;
|
||||
import mage.ObjectColor;
|
||||
|
|
@ -56,6 +55,8 @@ import mage.players.Player;
|
|||
import mage.util.GameLog;
|
||||
import mage.util.ThreadLocalStringBuilder;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* @author BetaSteward_at_googlemail.com
|
||||
*/
|
||||
|
|
@ -925,7 +926,7 @@ public abstract class PermanentImpl extends CardImpl implements Permanent {
|
|||
@Override
|
||||
public boolean cantBeAttachedBy(MageObject source, Game game) {
|
||||
for (ProtectionAbility ability : this.getAbilities(game).getProtectionAbilities()) {
|
||||
if (!(source.getSubtype(game).contains("Aura")
|
||||
if (!(source.getSubtype(game).contains(SubType.AURA)
|
||||
&& !ability.removesAuras())
|
||||
&& !source.getId().equals(ability.getAuraIdNotToBeRemoved())
|
||||
&& !ability.canTarget(source, game)) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue