- Set some activating players.

This commit is contained in:
Sloth
2012-11-05 09:24:32 +00:00
parent ef4919be2c
commit 2c05418610

View File

@@ -1882,6 +1882,7 @@ public class Upkeep extends Phase implements java.io.Serializable {
sb.append("When the last is removed, sacrifice it.)"); sb.append("When the last is removed, sacrifice it.)");
ability.setStackDescription(sb.toString()); ability.setStackDescription(sb.toString());
ability.setDescription(sb.toString()); ability.setDescription(sb.toString());
ability.setActivatingPlayer(card.getController());
Singletons.getModel().getGame().getStack().addSimultaneousStackEntry(ability); Singletons.getModel().getGame().getStack().addSimultaneousStackEntry(ability);
@@ -1924,6 +1925,7 @@ public class Upkeep extends Phase implements java.io.Serializable {
sb.append("If you can't, sacrifice it.)"); sb.append("If you can't, sacrifice it.)");
ability.setStackDescription(sb.toString()); ability.setStackDescription(sb.toString());
ability.setDescription(sb.toString()); ability.setDescription(sb.toString());
ability.setActivatingPlayer(card.getController());
Singletons.getModel().getGame().getStack().addSimultaneousStackEntry(ability); Singletons.getModel().getGame().getStack().addSimultaneousStackEntry(ability);
@@ -2007,6 +2009,7 @@ public class Upkeep extends Phase implements java.io.Serializable {
sb.append("battlefield and all other cards revealed this way into his or her graveyard."); sb.append("battlefield and all other cards revealed this way into his or her graveyard.");
ability.setStackDescription(sb.toString()); ability.setStackDescription(sb.toString());
ability.setDescription(sb.toString()); ability.setDescription(sb.toString());
ability.setActivatingPlayer(oath.getController());
Singletons.getModel().getGame().getStack().addSimultaneousStackEntry(ability); Singletons.getModel().getGame().getStack().addSimultaneousStackEntry(ability);
} }
@@ -2056,6 +2059,7 @@ public class Upkeep extends Phase implements java.io.Serializable {
sb.append("from their graveyard to owner's hand if they have more than an opponent."); sb.append("from their graveyard to owner's hand if they have more than an opponent.");
ability.setStackDescription(sb.toString()); ability.setStackDescription(sb.toString());
ability.setDescription(sb.toString()); ability.setDescription(sb.toString());
ability.setActivatingPlayer(oathList.get(0).getController());
Singletons.getModel().getGame().getStack().addSimultaneousStackEntry(ability); Singletons.getModel().getGame().getStack().addSimultaneousStackEntry(ability);
@@ -2081,24 +2085,23 @@ public class Upkeep extends Phase implements java.io.Serializable {
// battlefield have each of them deal damage. // battlefield have each of them deal damage.
if (0 < karmas.size()) { if (0 < karmas.size()) {
for (final Card karma : karmas) { for (final Card karma : karmas) {
final Card src = karma; final Ability ability = new Ability(karma, "0") {
final Ability ability = new Ability(src, "0") {
@Override @Override
public void resolve() { public void resolve() {
if (damage > 0) { if (damage > 0) {
player.addDamage(damage, src); player.addDamage(damage, karma);
} }
} }
}; // Ability }; // Ability
if (damage > 0) { if (damage > 0) {
final StringBuilder sb = new StringBuilder(); final StringBuilder sb = new StringBuilder();
sb.append("Karma deals ").append(damage).append(" damage to ").append(player); sb.append("Karma deals ").append(damage).append(" damage to ").append(player);
ability.setStackDescription(sb.toString()); ability.setStackDescription(sb.toString());
ability.setDescription(sb.toString()); ability.setDescription(sb.toString());
ability.setActivatingPlayer(karma.getController());
Singletons.getModel().getGame().getStack().addSimultaneousStackEntry(ability);
Singletons.getModel().getGame().getStack().addSimultaneousStackEntry(ability);
} }
} }
} // if } // if