mirror of
https://github.com/correl/mage.git
synced 2025-01-12 11:08:01 +00:00
[KLD] Some minor fixes.
This commit is contained in:
parent
d9c804602e
commit
346b6654f8
4 changed files with 9 additions and 7 deletions
|
@ -62,10 +62,10 @@ public class DeadlockTrap extends CardImpl {
|
|||
this.addAbility(new EntersBattlefieldTriggeredAbility(new GetEnergyCountersControllerEffect(2)));
|
||||
|
||||
// {t}, Pay {E}: Tap target creature or planeswalker. Its activated abilities can't be activated this turn.
|
||||
SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DeadlockTrapCantActivateEffect(), new TapSourceCost());
|
||||
SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new TapSourceCost());
|
||||
ability.addCost(new PayEnergyCost(1));
|
||||
ability.addTarget(new TargetCreatureOrPlaneswalker());
|
||||
ability.addEffect(new TapTargetEffect());
|
||||
ability.addEffect(new DeadlockTrapCantActivateEffect());
|
||||
this.addAbility(ability);
|
||||
|
||||
}
|
||||
|
@ -84,7 +84,7 @@ class DeadlockTrapCantActivateEffect extends RestrictionEffect {
|
|||
|
||||
public DeadlockTrapCantActivateEffect() {
|
||||
super(Duration.EndOfTurn);
|
||||
staticText = "Activated abilities of target creature or planeswalker can't be activated this turn";
|
||||
staticText = "Its activated abilities can't be activated this turn";
|
||||
}
|
||||
|
||||
public DeadlockTrapCantActivateEffect(final DeadlockTrapCantActivateEffect effect) {
|
||||
|
|
|
@ -60,7 +60,7 @@ public class DhundOperative extends CardImpl {
|
|||
|
||||
// As long as you control an artifact, Dhund Operative gets +1/+0 and has deathtouch.
|
||||
Effect boostEffect = new ConditionalContinuousEffect(
|
||||
new BoostSourceEffect(2, 0, Duration.WhileOnBattlefield),
|
||||
new BoostSourceEffect(1, 0, Duration.WhileOnBattlefield),
|
||||
new PermanentsOnTheBattlefieldCondition(StaticFilters.FILTER_CONTROLLED_PERMANENT_ARTIFACT),
|
||||
"As long as you control an artifact, {this} gets +1/+0");
|
||||
Effect gainAbilityEffect = new ConditionalContinuousEffect(
|
||||
|
|
|
@ -99,6 +99,7 @@ class DieYoungEffect extends OneShotEffect {
|
|||
if (cost.pay(source, game, source.getSourceId(), source.getControllerId(), true)) {
|
||||
Permanent targetCreature = game.getPermanent(getTargetPointer().getFirst(game, source));
|
||||
if (targetCreature != null) {
|
||||
numberToPayed *= -1;
|
||||
ContinuousEffect effect = new BoostTargetEffect(numberToPayed, numberToPayed, Duration.EndOfTurn);
|
||||
effect.setTargetPointer(new FixedTarget(targetCreature, game));
|
||||
game.addEffect(effect, source);
|
||||
|
|
|
@ -29,18 +29,19 @@ public class SacrificeSourceUnlessPaysEffect extends OneShotEffect {
|
|||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Player player = game.getPlayer(source.getControllerId());
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId());
|
||||
if (player != null && sourcePermanent != null) {
|
||||
if (controller != null && sourcePermanent != null) {
|
||||
StringBuilder sb = new StringBuilder(cost.getText()).append("?");
|
||||
if (!sb.toString().toLowerCase().startsWith("exile ") && !sb.toString().toLowerCase().startsWith("return ")) {
|
||||
sb.insert(0, "Pay ");
|
||||
}
|
||||
String message = CardUtil.replaceSourceName(sb.toString(), sourcePermanent.getLogName());
|
||||
message = Character.toUpperCase(message.charAt(0)) + message.substring(1);
|
||||
if (player.chooseUse(Outcome.Benefit, message, source, game)) {
|
||||
if (controller.chooseUse(Outcome.Benefit, message, source, game)) {
|
||||
cost.clearPaid();
|
||||
if (cost.pay(source, game, source.getSourceId(), source.getControllerId(), false, null)) {
|
||||
game.informPlayers(controller.getLogName() + " pays " + cost.toString());
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue