Removed duplicate class for cost. Refactored 1 card.

This commit is contained in:
magenoxx 2012-07-18 20:52:57 +04:00
parent 23a75c39ba
commit 86089f0fb9
3 changed files with 3 additions and 40 deletions

View file

@ -54,9 +54,7 @@ public class OnlyDuringYourTurnCost extends CostImpl<OnlyDuringYourTurnCost> {
@Override
public boolean canPay(UUID sourceId, UUID controllerId, Game game) {
if (game.getActivePlayerId().equals(controllerId))
return true;
return false;
return game.getActivePlayerId().equals(controllerId);
}
@Override

View file

@ -1,35 +0,0 @@
package mage.abilities.costs.common;
import mage.abilities.Ability;
import mage.abilities.costs.CostImpl;
import mage.game.Game;
import java.util.UUID;
/**
* "Activate this ability only during your turn" cost
**/
public class YourTurnCost extends CostImpl<YourTurnCost> {
public YourTurnCost() {
this.text = "Activate this ability only during your turn";
}
public YourTurnCost(final YourTurnCost cost) {
super(cost);
}
@Override
public boolean canPay(UUID sourceId, UUID controllerId, Game game) {
return game.getActivePlayerId().equals(controllerId);
}
@Override
public boolean pay(Ability ability, Game game, UUID sourceId, UUID controllerId, boolean noMana) {
return true;
}
@Override
public YourTurnCost copy() {
return new YourTurnCost(this);
}
}