forked from External/mage
Adding Chronozoa card impl
This commit is contained in:
parent
60e512580f
commit
1567c4efe9
6 changed files with 180 additions and 62 deletions
|
|
@ -0,0 +1,27 @@
|
|||
package mage.abilities.condition.common;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.condition.Condition;
|
||||
import mage.counters.CounterType;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.Permanent;
|
||||
|
||||
/**
|
||||
* Created by glerman on 20/6/15.
|
||||
*/
|
||||
public class LastTimeCounterRemovedCondition implements Condition{
|
||||
|
||||
|
||||
private static final LastTimeCounterRemovedCondition fInstance = new LastTimeCounterRemovedCondition();
|
||||
|
||||
public static LastTimeCounterRemovedCondition getInstance() {
|
||||
return fInstance;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
final Permanent p = game.getPermanent(source.getSourceId());
|
||||
final int timeCounters = p.getCounters().getCount(CounterType.TIME);
|
||||
return timeCounters == 0;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue