mirror of
https://github.com/correl/mage.git
synced 2025-01-12 11:08:01 +00:00
Minor changes to some cards.
This commit is contained in:
parent
a46eb1a366
commit
09a099facd
3 changed files with 42 additions and 38 deletions
|
@ -67,7 +67,11 @@ public class Pentavus extends CardImpl {
|
||||||
this.subtype.add("Construct");
|
this.subtype.add("Construct");
|
||||||
this.power = new MageInt(0);
|
this.power = new MageInt(0);
|
||||||
this.toughness = new MageInt(0);
|
this.toughness = new MageInt(0);
|
||||||
this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(5))));
|
|
||||||
|
// Pentavus enters the battlefield with five +1/+1 counters on it.
|
||||||
|
this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(5)),
|
||||||
|
"with five +1/+1 counters on it"));
|
||||||
|
|
||||||
Ability firstAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new PentaviteToken(), 1), new GenericManaCost(1));
|
Ability firstAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new PentaviteToken(), 1), new GenericManaCost(1));
|
||||||
firstAbility.addCost(new RemoveCountersSourceCost(CounterType.P1P1.createInstance(1)));
|
firstAbility.addCost(new RemoveCountersSourceCost(CounterType.P1P1.createInstance(1)));
|
||||||
this.addAbility(firstAbility);
|
this.addAbility(firstAbility);
|
||||||
|
|
|
@ -105,7 +105,7 @@ class MoveCounterFromSourceToTargetEffect extends OneShotEffect {
|
||||||
if (sourcePermanent != null && sourcePermanent.getCounters().getCount(CounterType.P1P1) > 0) {
|
if (sourcePermanent != null && sourcePermanent.getCounters().getCount(CounterType.P1P1) > 0) {
|
||||||
Permanent targetPermanent = game.getPermanent(targetPointer.getFirst(game, source));
|
Permanent targetPermanent = game.getPermanent(targetPointer.getFirst(game, source));
|
||||||
if (targetPermanent != null) {
|
if (targetPermanent != null) {
|
||||||
sourcePermanent.getCounters().removeCounter(CounterType.P1P1, 1);
|
sourcePermanent.removeCounters(CounterType.P1P1.createInstance(), game);
|
||||||
targetPermanent.addCounters(CounterType.P1P1.createInstance(), game);
|
targetPermanent.addCounters(CounterType.P1P1.createInstance(), game);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -248,41 +248,41 @@ class NecromancyLeavesBattlefieldTriggeredEffect extends OneShotEffect {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class NecromancyAttachEffect extends OneShotEffect {
|
//class NecromancyAttachEffect extends OneShotEffect {
|
||||||
|
//
|
||||||
public NecromancyAttachEffect(Outcome outcome) {
|
// public NecromancyAttachEffect(Outcome outcome) {
|
||||||
super(outcome);
|
// super(outcome);
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
public NecromancyAttachEffect(Outcome outcome, String rule) {
|
// public NecromancyAttachEffect(Outcome outcome, String rule) {
|
||||||
super(outcome);
|
// super(outcome);
|
||||||
staticText = rule;
|
// staticText = rule;
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
public NecromancyAttachEffect(final NecromancyAttachEffect effect) {
|
// public NecromancyAttachEffect(final NecromancyAttachEffect effect) {
|
||||||
super(effect);
|
// super(effect);
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
@Override
|
// @Override
|
||||||
public NecromancyAttachEffect copy() {
|
// public NecromancyAttachEffect copy() {
|
||||||
return new NecromancyAttachEffect(this);
|
// return new NecromancyAttachEffect(this);
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
@Override
|
// @Override
|
||||||
public boolean apply(Game game, Ability source) {
|
// public boolean apply(Game game, Ability source) {
|
||||||
Card card = game.getCard(source.getFirstTarget());
|
// Card card = game.getCard(source.getFirstTarget());
|
||||||
if (card != null && game.getState().getZone(source.getFirstTarget()).equals(Zone.GRAVEYARD)) {
|
// if (card != null && game.getState().getZone(source.getFirstTarget()).equals(Zone.GRAVEYARD)) {
|
||||||
// Card have no attachedTo attribute yet so write ref only to enchantment now
|
// // Card have no attachedTo attribute yet so write ref only to enchantment now
|
||||||
Permanent enchantment = game.getPermanent(source.getSourceId());
|
// Permanent enchantment = game.getPermanent(source.getSourceId());
|
||||||
if (enchantment != null) {
|
// if (enchantment != null) {
|
||||||
enchantment.attachTo(card.getId(), game);
|
// enchantment.attachTo(card.getId(), game);
|
||||||
}
|
// }
|
||||||
return true;
|
// return true;
|
||||||
}
|
// }
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
}
|
//}
|
||||||
|
|
||||||
class NecromancyChangeAbilityEffect extends ContinuousEffectImpl implements SourceEffect {
|
class NecromancyChangeAbilityEffect extends ContinuousEffectImpl implements SourceEffect {
|
||||||
|
|
||||||
|
@ -319,7 +319,7 @@ class NecromancyChangeAbilityEffect extends ContinuousEffectImpl implements Sour
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean apply(Layer layer, SubLayer sublayer, Ability source, Game game) {
|
public boolean apply(Layer layer, SubLayer sublayer, Ability source, Game game) {
|
||||||
Permanent permanent = affectedObjectList.get(0).getPermanent(game);;
|
Permanent permanent = affectedObjectList.get(0).getPermanent(game);
|
||||||
if (permanent != null) {
|
if (permanent != null) {
|
||||||
switch (layer) {
|
switch (layer) {
|
||||||
case TypeChangingEffects_4:
|
case TypeChangingEffects_4:
|
||||||
|
|
Loading…
Reference in a new issue