mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-15 18:28:00 +00:00
- Currently no card has keyword "CARDNAME can't have -1/-1 counters placed on it.", replaced with canHaveCountersPlacedOnIt
This commit is contained in:
@@ -49,8 +49,7 @@ public class CountersPutAi extends SpellAbilityAi {
|
|||||||
list = CardLists.filter(player.getCardsIn(ZoneType.Battlefield), new Predicate<Card>() {
|
list = CardLists.filter(player.getCardsIn(ZoneType.Battlefield), new Predicate<Card>() {
|
||||||
@Override
|
@Override
|
||||||
public boolean apply(final Card c) {
|
public boolean apply(final Card c) {
|
||||||
return c.canBeTargetedBy(sa) && !c.hasKeyword("CARDNAME can't have counters placed on it.")
|
return c.canBeTargetedBy(sa) && c.canHaveCountersPlacedOnIt(CounterType.valueOf(type));
|
||||||
&& !(c.hasKeyword("CARDNAME can't have -1/-1 counters placed on it.") && type.equals("M1M1"));
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -193,11 +193,7 @@ public class CostPutCounter extends CostPartWithList {
|
|||||||
final Player activator = ability.getActivatingPlayer();
|
final Player activator = ability.getActivatingPlayer();
|
||||||
final Card source = ability.getSourceCard();
|
final Card source = ability.getSourceCard();
|
||||||
if (this.payCostFromSource()) {
|
if (this.payCostFromSource()) {
|
||||||
if (source.hasKeyword("CARDNAME can't have counters placed on it.")) {
|
if (!source.canHaveCountersPlacedOnIt(this.counter)) {
|
||||||
return false;
|
|
||||||
}
|
|
||||||
if (source.hasKeyword("CARDNAME can't have -1/-1 counters placed on it.")
|
|
||||||
&& this.counter.equals(CounterType.M1M1)) {
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user