CombatUtil: add "CARDNAME can block creatures with landwalk abilities as though they didn't have those abilities."

ts not a global deactivating, but a local one.
This commit is contained in:
Hanmac
2016-07-18 07:52:09 +00:00
parent fc046a582d
commit ec762d652f

View File

@@ -498,7 +498,8 @@ public class CombatUtil {
// Landwalk // Landwalk
if (isUnblockableFromLandwalk(attacker, defender)) { if (isUnblockableFromLandwalk(attacker, defender)) {
return false; if (CardLists.getAmountOfKeyword(defender.getCreaturesInPlay(), "CARDNAME can block creatures with landwalk abilities as though they didn't have those abilities.") == 0)
return false;
} }
return true; return true;
@@ -763,6 +764,7 @@ public class CombatUtil {
if (blocker.isValid(valid, null, null, null) && if (blocker.isValid(valid, null, null, null) &&
CardLists.getValidCardCount(combat.getBlockers(attacker), valid, null, null) == 0) { CardLists.getValidCardCount(combat.getBlockers(attacker), valid, null, null) == 0) {
attackersWithLure.add(attacker); attackersWithLure.add(attacker);
break;
} }
} }
} }
@@ -937,6 +939,11 @@ public class CombatUtil {
if (CardFactoryUtil.hasProtectionFrom(blocker, attacker)) { if (CardFactoryUtil.hasProtectionFrom(blocker, attacker)) {
return false; return false;
} }
if (isUnblockableFromLandwalk(attacker, blocker.getController())
&& !blocker.hasKeyword("CARDNAME can block creatures with landwalk abilities as though they didn't have those abilities.")) {
return false;
}
// rare case: // rare case:
if (blocker.hasKeyword("Shadow") if (blocker.hasKeyword("Shadow")