* Zaffai, Thunder Conductor - fixed that it allows to choose opponent instead random (#8094)

* Fix Zaffai: Target opponent should be at random.

Co-authored-by: Oleg Agafonov <jaydi85@gmail.com>
This commit is contained in:
Grath 2021-08-02 18:55:34 -04:00 committed by GitHub
parent 42a86bd196
commit a9cc7cefd0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -70,19 +70,25 @@ class ZaffaiThunderConductorEffect extends OneShotEffect {
if (player == null) {
return false;
}
player.scry(1, source, game);
Spell spell = (Spell) getValue(MagecraftAbility.SPELL_KEY);
if (spell == null || spell.getManaValue() < 5) {
return false;
return true;
}
new Elemental44Token().putOntoBattlefield(1, game, source, source.getControllerId());
if (spell.getManaValue() < 10) {
return true;
}
TargetOpponent target = new TargetOpponent(true);
player.chooseTarget(outcome, target, source, game);
target.setRandom(true);
target.chooseTarget(Outcome.Damage, player.getId(), source, game);
Player opponent = game.getPlayer(target.getFirstTarget());
if (opponent != null) {
opponent.damage(10, source.getSourceId(), source, game);
}
return true;
}
}