mirror of
https://github.com/magefree/mage.git
synced 2025-12-24 20:41:58 -08:00
Add ignored failing test and fix bug for hybrid mana payments (#9566)
This commit is contained in:
parent
b1b78d6db0
commit
01ee54d416
2 changed files with 55 additions and 10 deletions
|
|
@ -62,37 +62,37 @@ public class HybridManaCost extends ManaCostImpl {
|
|||
public boolean testPay(Mana testMana) {
|
||||
switch (mana1) {
|
||||
case B:
|
||||
if (testMana.getBlack() > 0) {
|
||||
if (testMana.getBlack() > 0 || testMana.getAny() > 0) {
|
||||
return true;
|
||||
}
|
||||
case U:
|
||||
if (testMana.getBlue() > 0) {
|
||||
if (testMana.getBlue() > 0 || testMana.getAny() > 0) {
|
||||
return true;
|
||||
}
|
||||
case R:
|
||||
if (testMana.getRed() > 0) {
|
||||
if (testMana.getRed() > 0 || testMana.getAny() > 0) {
|
||||
return true;
|
||||
}
|
||||
case W:
|
||||
if (testMana.getWhite() > 0) {
|
||||
if (testMana.getWhite() > 0 || testMana.getAny() > 0) {
|
||||
return true;
|
||||
}
|
||||
case G:
|
||||
if (testMana.getGreen() > 0) {
|
||||
if (testMana.getGreen() > 0 || testMana.getAny() > 0) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
switch (mana2) {
|
||||
case B:
|
||||
return testMana.getBlack() > 0;
|
||||
return testMana.getBlack() > 0 || testMana.getAny() > 0;
|
||||
case U:
|
||||
return testMana.getBlue() > 0;
|
||||
return testMana.getBlue() > 0 || testMana.getAny() > 0;
|
||||
case R:
|
||||
return testMana.getRed() > 0;
|
||||
return testMana.getRed() > 0 || testMana.getAny() > 0;
|
||||
case W:
|
||||
return testMana.getWhite() > 0;
|
||||
return testMana.getWhite() > 0 || testMana.getAny() > 0;
|
||||
case G:
|
||||
return testMana.getGreen() > 0;
|
||||
return testMana.getGreen() > 0 || testMana.getAny() > 0;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue