mirror of
https://github.com/magefree/mage.git
synced 2025-12-22 19:41:59 -08:00
Fixed Gideon's Triumph that it can sacrifice any creatures, not from current turn;
This commit is contained in:
parent
081ac7ca3c
commit
00915c65d7
1 changed files with 11 additions and 6 deletions
|
|
@ -49,13 +49,13 @@ public final class GideonsTriumph extends CardImpl {
|
|||
|
||||
class GideonsTriumphEffect extends OneShotEffect {
|
||||
|
||||
private static final FilterControlledPlaneswalkerPermanent filter
|
||||
private static final FilterControlledPlaneswalkerPermanent filterGideon
|
||||
= new FilterControlledPlaneswalkerPermanent(SubType.GIDEON);
|
||||
private static final FilterPermanent filter2
|
||||
private static final FilterPermanent filterSacrifice
|
||||
= new FilterPermanent("creature that attacked or blocked this turn");
|
||||
|
||||
static {
|
||||
filter2.add(GideonsTriumphCondition.instance);
|
||||
filterSacrifice.add(GideonsTriumphPredicate.instance);
|
||||
}
|
||||
|
||||
GideonsTriumphEffect() {
|
||||
|
|
@ -76,14 +76,14 @@ class GideonsTriumphEffect extends OneShotEffect {
|
|||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
int count = 1;
|
||||
if (!game.getBattlefield().getActivePermanents(filter, source.getControllerId(), game).isEmpty()) {
|
||||
if (!game.getBattlefield().getActivePermanents(filterGideon, source.getControllerId(), game).isEmpty()) {
|
||||
count++;
|
||||
}
|
||||
return new SacrificeEffect(filter2, count, "Target opponent").apply(game, source);
|
||||
return new SacrificeEffect(filterSacrifice, count, "Target opponent").apply(game, source);
|
||||
}
|
||||
}
|
||||
|
||||
enum GideonsTriumphCondition implements Predicate<Permanent> {
|
||||
enum GideonsTriumphPredicate implements Predicate<Permanent> {
|
||||
instance;
|
||||
|
||||
@Override
|
||||
|
|
@ -123,4 +123,9 @@ class GideonsTriumphWatcher extends Watcher {
|
|||
return new GideonsTriumphWatcher(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void reset() {
|
||||
attackedOrBlockedThisTurnCreatures.clear();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue