replaced X cmc targeting adjustment

This commit is contained in:
Evan Kranzler 2018-09-17 13:21:05 -04:00
parent 9b94b618cd
commit 7305fbac3a
8 changed files with 13 additions and 27 deletions

View file

@ -361,16 +361,6 @@ public abstract class CardImpl extends MageObjectImpl implements Card {
switch (ability.getTargetAdjustment()) {
case NONE:
break;
case X_CMC_EQUAL_PERM:
// xValue = ability.getManaCostsToPay().getX();
// oldTargetPermanent = (TargetPermanent) ability.getTargets().get(0);
// minTargets = oldTargetPermanent.getMinNumberOfTargets();
// maxTargets = oldTargetPermanent.getMaxNumberOfTargets();
// permanentFilter = oldTargetPermanent.getFilter().copy();
// permanentFilter.add(new ConvertedManaCostPredicate(ComparisonType.EQUAL_TO, xValue));
// ability.getTargets().clear();
// ability.getTargets().add(new TargetPermanent(minTargets, maxTargets, permanentFilter, false));
break;
case X_TARGETS:
xValue = ability.getManaCostsToPay().getX();
permanentFilter = ((TargetPermanent) ability.getTargets().get(0)).getFilter();

View file

@ -9,5 +9,5 @@ import mage.game.Game;
*/
public interface TargetAdjuster {
public void adjustTargets(Ability ability, Game game);
void adjustTargets(Ability ability, Game game);
}

View file

@ -11,7 +11,8 @@ import mage.target.TargetPermanent;
*
* @author TheElk801
*/
public class XCMCPermanentAdjuster implements TargetAdjuster {
public enum XCMCPermanentAdjuster implements TargetAdjuster {
instance;
@Override
public void adjustTargets(Ability ability, Game game) {