mirror of
https://github.com/magefree/mage.git
synced 2025-12-25 13:02:06 -08:00
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:
parent
06f9e3db19
commit
0ccaca4a3b
8 changed files with 106 additions and 14 deletions
|
|
@ -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;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -146,7 +146,6 @@ public class BoostControlledEffect extends ContinuousEffectImpl {
|
|||
perm.addToughness(toughness.calculate(game, source, this));
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -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) {
|
||||
|
|
|
|||
|
|
@ -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;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue