mirror of
https://github.com/correl/mage.git
synced 2024-12-25 19:25:41 +00:00
* Kaervek the Merciless - Fixed converted mana costs calculation (X spells).
This commit is contained in:
parent
cbfc32db3c
commit
17db5adf13
1 changed files with 3 additions and 4 deletions
|
@ -42,6 +42,7 @@ import mage.constants.Zone;
|
||||||
import mage.filter.FilterSpell;
|
import mage.filter.FilterSpell;
|
||||||
import mage.game.Game;
|
import mage.game.Game;
|
||||||
import mage.game.permanent.Permanent;
|
import mage.game.permanent.Permanent;
|
||||||
|
import mage.game.stack.Spell;
|
||||||
import mage.players.Player;
|
import mage.players.Player;
|
||||||
import mage.target.common.TargetCreatureOrPlayer;
|
import mage.target.common.TargetCreatureOrPlayer;
|
||||||
|
|
||||||
|
@ -59,8 +60,6 @@ public class KaervekTheMerciless extends CardImpl {
|
||||||
this.subtype.add("Human");
|
this.subtype.add("Human");
|
||||||
this.subtype.add("Shaman");
|
this.subtype.add("Shaman");
|
||||||
|
|
||||||
this.color.setRed(true);
|
|
||||||
this.color.setBlack(true);
|
|
||||||
this.power = new MageInt(5);
|
this.power = new MageInt(5);
|
||||||
this.toughness = new MageInt(4);
|
this.toughness = new MageInt(4);
|
||||||
|
|
||||||
|
@ -100,8 +99,8 @@ class KaervekTheMercilessEffect extends OneShotEffect {
|
||||||
@Override
|
@Override
|
||||||
public boolean apply(Game game, Ability source) {
|
public boolean apply(Game game, Ability source) {
|
||||||
MageObject spellCast = game.getObject(targetPointer.getFirst(game, source));
|
MageObject spellCast = game.getObject(targetPointer.getFirst(game, source));
|
||||||
if (spellCast != null) {
|
if (spellCast instanceof Spell) {
|
||||||
int cost = spellCast.getManaCost().convertedManaCost();
|
int cost = ((Spell)spellCast).getConvertedManaCost();
|
||||||
Player target = game.getPlayer(source.getFirstTarget());
|
Player target = game.getPlayer(source.getFirstTarget());
|
||||||
if (target != null) {
|
if (target != null) {
|
||||||
target.damage(cost, source.getSourceId(), game, false, true);
|
target.damage(cost, source.getSourceId(), game, false, true);
|
||||||
|
|
Loading…
Reference in a new issue