Added new method for discarding cards to handle batch triggers (ready for review) (#6489)

* added new discard method

* started refactoring to use new discard method

* refactored A through I

* fixed some issues

* separated balance effect into its own class

* refactored J through R

* refactored S through Z

* applied requested changes
This commit is contained in:
Evan Kranzler 2020-05-03 14:35:26 -04:00 committed by GitHub
parent 2739391b1d
commit 75577cdbe9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
68 changed files with 1290 additions and 1953 deletions

View file

@ -2550,6 +2550,11 @@ public class TestPlayer implements Player {
return computerPlayer.discard(amount, random, source, game);
}
@Override
public Cards discard(Cards cards, Ability source, Game game) {
return computerPlayer.discard(cards, source, game);
}
@Override
public boolean discard(Card card, Ability source, Game game) {
return computerPlayer.discard(card, source, game);

View file

@ -1,7 +1,5 @@
package org.mage.test.stub;
import java.io.Serializable;
import java.util.*;
import mage.MageObject;
import mage.MageObjectReference;
import mage.abilities.*;
@ -41,6 +39,9 @@ import mage.target.TargetAmount;
import mage.target.TargetCard;
import mage.target.common.TargetCardInLibrary;
import java.io.Serializable;
import java.util.*;
/**
* @author Quercitron
*/
@ -656,6 +657,11 @@ public class PlayerStub implements Player {
return 1;
}
@Override
public Cards discard(Cards cards, Ability source, Game game) {
return null;
}
@Override
public Card discardOne(boolean random, Ability source, Game game) {
return null;