* Replicate abilities - fixed that AI can freeze the game after play card with replicate (AI don't use it now);

This commit is contained in:
Oleg Agafonov 2020-01-04 20:22:49 +04:00
parent a249dcffd8
commit 1ae9fc883e
4 changed files with 74 additions and 23 deletions

View file

@ -1,12 +1,12 @@
package mage.abilities.costs;
import java.io.Serializable;
import java.util.UUID;
import mage.abilities.Ability;
import mage.game.Game;
import mage.target.Targets;
import java.io.Serializable;
import java.util.UUID;
public interface Cost extends Serializable {
UUID getId();
@ -15,6 +15,10 @@ public interface Cost extends Serializable {
void setText(String text);
/**
* Check is it possible to pay
* For mana it checks only single color and amount available, not total mana cost
*/
boolean canPay(Ability ability, UUID sourceId, UUID controllerId, Game game);
boolean pay(Ability ability, Game game, UUID sourceId, UUID controllerId, boolean noMana);