mirror of
https://github.com/magefree/mage.git
synced 2025-12-20 02:30:08 -08:00
Add hint to Florian, Voldaren Scion
This commit is contained in:
parent
d889fa8e23
commit
cef2a1edc8
1 changed files with 33 additions and 1 deletions
|
|
@ -3,6 +3,9 @@ package mage.cards.f;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
import mage.MageInt;
|
import mage.MageInt;
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
|
import mage.abilities.dynamicvalue.DynamicValue;
|
||||||
|
import mage.abilities.effects.Effect;
|
||||||
|
import mage.abilities.hint.ValueHint;
|
||||||
import mage.abilities.triggers.BeginningOfPostcombatMainTriggeredAbility;
|
import mage.abilities.triggers.BeginningOfPostcombatMainTriggeredAbility;
|
||||||
import mage.abilities.effects.OneShotEffect;
|
import mage.abilities.effects.OneShotEffect;
|
||||||
import mage.abilities.effects.common.asthought.PlayFromNotOwnHandZoneTargetEffect;
|
import mage.abilities.effects.common.asthought.PlayFromNotOwnHandZoneTargetEffect;
|
||||||
|
|
@ -35,7 +38,7 @@ public final class FlorianVoldarenScion extends CardImpl {
|
||||||
|
|
||||||
// At the beginning of your postcombat main phase, look at the top X cards of your library, where X is the total amount of life your opponents lost this turn.
|
// At the beginning of your postcombat main phase, look at the top X cards of your library, where X is the total amount of life your opponents lost this turn.
|
||||||
// Exile one of those cards and put the rest on the bottom of your library in a random order. You may play the exiled card this turn.
|
// Exile one of those cards and put the rest on the bottom of your library in a random order. You may play the exiled card this turn.
|
||||||
this.addAbility(new BeginningOfPostcombatMainTriggeredAbility(new FlorianVoldarenScionEffect(), false));
|
this.addAbility(new BeginningOfPostcombatMainTriggeredAbility(new FlorianVoldarenScionEffect(), false).addHint(FlorianValue.getHint()));
|
||||||
}
|
}
|
||||||
|
|
||||||
private FlorianVoldarenScion(final FlorianVoldarenScion card) {
|
private FlorianVoldarenScion(final FlorianVoldarenScion card) {
|
||||||
|
|
@ -48,6 +51,35 @@ public final class FlorianVoldarenScion extends CardImpl {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
enum FlorianValue implements DynamicValue {
|
||||||
|
instance;
|
||||||
|
private static final ValueHint hint = new ValueHint("Total amount of life your opponents lost this turn", instance);
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int calculate(Game game, Ability sourceAbility, Effect effect) {
|
||||||
|
Player controller = game.getPlayer(sourceAbility.getControllerId());
|
||||||
|
PlayerLostLifeWatcher watcher = game.getState().getWatcher(PlayerLostLifeWatcher.class);
|
||||||
|
if (controller != null && watcher != null) {
|
||||||
|
return watcher.getAllOppLifeLost(controller.getId(), game);
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public FlorianValue copy() {
|
||||||
|
return instance;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getMessage() {
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
|
||||||
|
public static ValueHint getHint() {
|
||||||
|
return hint;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
class FlorianVoldarenScionEffect extends OneShotEffect {
|
class FlorianVoldarenScionEffect extends OneShotEffect {
|
||||||
|
|
||||||
FlorianVoldarenScionEffect() {
|
FlorianVoldarenScionEffect() {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue