mirror of
https://github.com/correl/mage.git
synced 2024-11-15 19:19:33 +00:00
Fixed issue #149, Ogre Slumlord triggered ability triggers now for all dying nontoken creatures.
This commit is contained in:
parent
ad615deb5f
commit
586d3b794d
1 changed files with 5 additions and 7 deletions
|
@ -28,9 +28,10 @@
|
||||||
package mage.sets.gatecrash;
|
package mage.sets.gatecrash;
|
||||||
|
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
import mage.Constants;
|
|
||||||
import mage.Constants.CardType;
|
import mage.Constants.CardType;
|
||||||
|
import mage.Constants.Duration;
|
||||||
import mage.Constants.Rarity;
|
import mage.Constants.Rarity;
|
||||||
|
import mage.Constants.Zone;
|
||||||
import mage.MageInt;
|
import mage.MageInt;
|
||||||
import mage.ObjectColor;
|
import mage.ObjectColor;
|
||||||
import mage.abilities.common.DiesCreatureTriggeredAbility;
|
import mage.abilities.common.DiesCreatureTriggeredAbility;
|
||||||
|
@ -44,7 +45,6 @@ import mage.filter.common.FilterCreaturePermanent;
|
||||||
import mage.filter.predicate.Predicates;
|
import mage.filter.predicate.Predicates;
|
||||||
import mage.filter.predicate.mageobject.SubtypePredicate;
|
import mage.filter.predicate.mageobject.SubtypePredicate;
|
||||||
import mage.filter.predicate.permanent.AnotherPredicate;
|
import mage.filter.predicate.permanent.AnotherPredicate;
|
||||||
import mage.filter.predicate.permanent.ControllerPredicate;
|
|
||||||
import mage.filter.predicate.permanent.TokenPredicate;
|
import mage.filter.predicate.permanent.TokenPredicate;
|
||||||
import mage.game.permanent.token.Token;
|
import mage.game.permanent.token.Token;
|
||||||
|
|
||||||
|
@ -54,13 +54,11 @@ import mage.game.permanent.token.Token;
|
||||||
*/
|
*/
|
||||||
public class OgreSlumlord extends CardImpl<OgreSlumlord> {
|
public class OgreSlumlord extends CardImpl<OgreSlumlord> {
|
||||||
|
|
||||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("another nontoken creature you control ");
|
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("another nontoken creature");
|
||||||
private static final FilterControlledPermanent filter2 = new FilterControlledPermanent("Rats you control");
|
private static final FilterControlledPermanent filter2 = new FilterControlledPermanent("Rats you control");
|
||||||
static {
|
static {
|
||||||
filter.add(new ControllerPredicate(Constants.TargetController.YOU));
|
|
||||||
filter.add(Predicates.not(new TokenPredicate()));
|
filter.add(Predicates.not(new TokenPredicate()));
|
||||||
filter.add(new AnotherPredicate());
|
filter.add(new AnotherPredicate());
|
||||||
|
|
||||||
filter2.add(new SubtypePredicate("Rat"));
|
filter2.add(new SubtypePredicate("Rat"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -77,10 +75,10 @@ public class OgreSlumlord extends CardImpl<OgreSlumlord> {
|
||||||
|
|
||||||
this.color.setBlack(true);
|
this.color.setBlack(true);
|
||||||
|
|
||||||
// Whenever another nontoken creature you control dies, put a 1/1 black Rat creature token onto the battlefield.
|
// Whenever another nontoken creature dies, you may put a 1/1 black Rat creature token onto the battlefield.
|
||||||
this.addAbility(new DiesCreatureTriggeredAbility(new CreateTokenEffect(new RatToken()), false, filter));
|
this.addAbility(new DiesCreatureTriggeredAbility(new CreateTokenEffect(new RatToken()), false, filter));
|
||||||
// Rats you control have deathtouch.
|
// Rats you control have deathtouch.
|
||||||
this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new GainAbilityAllEffect(DeathtouchAbility.getInstance(), Constants.Duration.WhileOnBattlefield, filter2)));
|
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(DeathtouchAbility.getInstance(), Duration.WhileOnBattlefield, filter2)));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue