* Fixed a bug with tokens using the optional EntersBattlefieldEffect (e.g. Clone with Mimic Vat).

This commit is contained in:
LevelX2 2016-10-23 00:36:36 +02:00
parent f48e20a48c
commit c7744d8631
2 changed files with 118 additions and 1 deletions

View file

@ -104,7 +104,10 @@ public class EntersBattlefieldEffect extends ReplacementEffectImpl {
public boolean replaceEvent(GameEvent event, Ability source, Game game) {
if (optional) {
Player controller = game.getPlayer(source.getControllerId());
MageObject object = game.getObject(source.getSourceId());
MageObject object = game.getPermanentEntering(source.getSourceId());
if (object == null) {
object = game.getObject(source.getSourceId());
}
if (controller == null || object == null) {
return false;
}