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

@ -3,7 +3,6 @@ package mage.abilities.effects.common;
import mage.abilities.Ability;
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;
@ -36,7 +35,7 @@ public class PutTopCardOfLibraryIntoGraveControllerEffect extends OneShotEffect
public boolean apply(Game game, Ability source) {
Player controller = game.getPlayer(source.getControllerId());
if (controller != null) {
return controller.moveCards(controller.getLibrary().getTopCards(game, numberCards), Zone.GRAVEYARD, source, game);
return !controller.millCards(numberCards, source, game).isEmpty();
}
return false;
}