Fixed a problem that tokens that came into play with modified attributes (P/T e.g. from Master of Etherium) were seen for triggered abilities (e.g. Sword of the Meek ) with unmodified attributes.

This commit is contained in:
LevelX2 2016-11-19 12:08:38 +01:00
parent 06f9e3db19
commit 0ccaca4a3b
8 changed files with 106 additions and 14 deletions

View file

@ -97,6 +97,7 @@ public class CreateTokenEffect extends OneShotEffect {
token.putOntoBattlefield(value, game, source.getSourceId(), source.getControllerId(), tapped, attacking);
this.lastAddedTokenId = token.getLastAddedToken();
this.lastAddedTokenIds = token.getLastAddedTokenIds();
return true;
}

View file

@ -146,7 +146,6 @@ public class BoostControlledEffect extends ContinuousEffectImpl {
perm.addToughness(toughness.calculate(game, source, this));
}
}
}
return true;
}

View file

@ -544,11 +544,10 @@ public class GameState implements Serializable, Copyable<GameState> {
// 608.2e
public void processAction(Game game) {
game.getState().handleSimultaneousEvent(game);
applyEffects(game);
game.applyEffects();
}
public void applyEffects(Game game) {
game.resetShortLivingLKI();
for (Player player : players.values()) {
player.reset();
}
@ -563,13 +562,13 @@ public class GameState implements Serializable, Copyable<GameState> {
public void removeEocEffects(Game game) {
effects.removeEndOfCombatEffects();
delayed.removeEndOfCombatAbilities();
applyEffects(game);
game.applyEffects();
}
public void removeEotEffects(Game game) {
effects.removeEndOfTurnEffects();
delayed.removeEndOfTurnAbilities();
applyEffects(game);
game.applyEffects();
}
public void addEffect(ContinuousEffect effect, Ability source) {

View file

@ -234,6 +234,7 @@ public class Token extends MageObjectImpl {
}
}
game.getState().applyEffects(game); // Needed to do it here without LKIReset i.e. do get SwordOfTheMeekTest running correctly.
return true;
}
return false;