Moved some postresolveEffects to the correct package.

This commit is contained in:
LevelX2 2015-03-24 15:45:33 +01:00
parent 16b01b03be
commit 2a9af5ad99
17 changed files with 31 additions and 22 deletions

View file

@ -663,16 +663,18 @@ public abstract class AbilityImpl implements Ability {
@Override
public List<Watcher> getWatchers() {
if (watchers != null)
if (watchers != null) {
return watchers;
else
} else {
return emptyWatchers;
}
}
@Override
public void addWatcher(Watcher watcher) {
if (watchers == null)
if (watchers == null) {
watchers = new ArrayList<>();
}
watcher.setSourceId(this.sourceId);
watcher.setControllerId(this.controllerId);
watchers.add(watcher);
@ -680,16 +682,18 @@ public abstract class AbilityImpl implements Ability {
@Override
public List<Ability> getSubAbilities() {
if (subAbilities != null)
if (subAbilities != null) {
return subAbilities;
else
} else {
return emptyAbilities;
}
}
@Override
public void addSubAbility(Ability ability) {
if (subAbilities == null)
if (subAbilities == null) {
subAbilities = new ArrayList<>();
}
ability.setSourceId(this.sourceId);
ability.setControllerId(this.controllerId);
subAbilities.add(ability);

View file

@ -36,6 +36,8 @@ import mage.game.Game;
import java.io.ObjectStreamException;
import java.util.UUID;
import mage.constants.Zone;
import mage.players.Player;
/**
*
@ -64,6 +66,9 @@ public class ExileSpellEffect extends PostResolveEffect implements MageSingleton
@Override
public void postResolve(Card card, Ability source, UUID controllerId, Game game) {
card.moveToExile(null, "", source.getSourceId(), game);
Player controller = game.getPlayer(controllerId);
if (controller != null) {
controller.moveCardToExileWithInfo(card, null, "", controllerId, game, Zone.STACK);
}
}
}

View file

@ -1,4 +1,4 @@
package mage.abilities.effects.common;
package mage.abilities.effects.postresolve;
import mage.constants.Zone;
import mage.abilities.Ability;

View file

@ -25,7 +25,7 @@
* authors and should not be interpreted as representing official policies, either expressed
* or implied, of BetaSteward_at_googlemail.com.
*/
package mage.abilities.effects.common;
package mage.abilities.effects.postresolve;
import java.util.UUID;
import mage.abilities.Ability;

View file

@ -26,7 +26,7 @@
* or implied, of BetaSteward_at_googlemail.com.
*/
package mage.abilities.effects.common;
package mage.abilities.effects.postresolve;
import mage.constants.Zone;
import mage.abilities.Ability;