mirror of
https://github.com/correl/mage.git
synced 2024-12-25 11:11:16 +00:00
* Arcane Artisan - Fixed that the tokens were not exiled but destroyes (fixes #6710).
This commit is contained in:
parent
de9ecd58bd
commit
324c2bdcf3
1 changed files with 5 additions and 6 deletions
|
@ -30,6 +30,7 @@ import mage.util.CardUtil;
|
|||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
import java.util.UUID;
|
||||
import mage.cards.CardsImpl;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
|
@ -167,12 +168,10 @@ class ArcaneArtisanExileEffect extends OneShotEffect {
|
|||
public boolean apply(Game game, Ability source) {
|
||||
Object object = game.getState().getValue(CardUtil.getCardZoneString("_tokensCreated", source.getSourceId(), game, true));
|
||||
if (object != null) {
|
||||
Set<UUID> tokensCreated = (Set<UUID>) object;
|
||||
for (UUID tokenId : tokensCreated) {
|
||||
Permanent token = game.getPermanent(tokenId);
|
||||
if (token != null) {
|
||||
token.destroy(source.getSourceId(), game, true);
|
||||
}
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
if (controller != null) {
|
||||
controller.moveCards(new CardsImpl((Set<UUID>) object), Zone.EXILED, source, game);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
|
Loading…
Reference in a new issue