Refactoring cards that mill (WIP, do not merge) (#6713)

* added mill method

* updated mill effects to use new method

* refactored individual cards

* small updated to Grindstone and Sphinx's Tutelage

* another updated to Grindstone

* fixed a test

* fixed Countermand null check

* more refactoring

* updated dredge ability to use mill
This commit is contained in:
Evan Kranzler 2020-06-24 07:50:00 -04:00 committed by GitHub
parent 8b5f4f28f0
commit 785be83484
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
102 changed files with 738 additions and 957 deletions

View file

@ -5,7 +5,6 @@ import mage.abilities.dynamicvalue.DynamicValue;
import mage.abilities.dynamicvalue.common.StaticValue;
import mage.abilities.effects.OneShotEffect;
import mage.constants.Outcome;
import mage.constants.Zone;
import mage.game.Game;
import mage.players.Player;
import mage.util.CardUtil;
@ -41,7 +40,7 @@ public class PutTopCardOfLibraryIntoGraveTargetEffect extends OneShotEffect {
public boolean apply(Game game, Ability source) {
Player player = game.getPlayer(targetPointer.getFirst(game, source));
if (player != null) {
player.moveCards(player.getLibrary().getTopCards(game, numberCards.calculate(game, source, this)), Zone.GRAVEYARD, source, game);
player.millCards(numberCards.calculate(game, source, this), source, game);
return true;
}
return false;