mirror of
https://github.com/correl/mage.git
synced 2025-03-17 01:06:26 -09:00
- Fixed #5931
This commit is contained in:
parent
bf5e603fcb
commit
30e8fec8df
4 changed files with 8 additions and 9 deletions
|
@ -28,8 +28,6 @@ import mage.target.targetpointer.FixedTarget;
|
||||||
*/
|
*/
|
||||||
public final class CallerOfTheHunt extends CardImpl {
|
public final class CallerOfTheHunt extends CardImpl {
|
||||||
|
|
||||||
FilterCreaturePermanent filter = new FilterCreaturePermanent();
|
|
||||||
|
|
||||||
public CallerOfTheHunt(UUID ownerId, CardSetInfo setInfo) {
|
public CallerOfTheHunt(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{G}");
|
||||||
|
|
||||||
|
@ -72,10 +70,10 @@ enum CallerOfTheHuntAdjuster implements CostAdjuster {
|
||||||
ContinuousEffect effectPowerToughness = new SetPowerToughnessSourceEffect(
|
ContinuousEffect effectPowerToughness = new SetPowerToughnessSourceEffect(
|
||||||
new PermanentsOnBattlefieldCount(filter), Duration.EndOfGame);
|
new PermanentsOnBattlefieldCount(filter), Duration.EndOfGame);
|
||||||
effectPowerToughness.setText("");
|
effectPowerToughness.setText("");
|
||||||
SimpleStaticAbility sa = new SimpleStaticAbility(Zone.ALL, effectPowerToughness);
|
SimpleStaticAbility setPT = new SimpleStaticAbility(Zone.ALL, effectPowerToughness);
|
||||||
GainAbilityTargetEffect effectTest = new GainAbilityTargetEffect(sa, Duration.EndOfGame);
|
GainAbilityTargetEffect gainAbility = new GainAbilityTargetEffect(setPT, Duration.EndOfGame);
|
||||||
effectTest.setTargetPointer(new FixedTarget(ability.getSourceId()));
|
gainAbility.setTargetPointer(new FixedTarget(ability.getSourceId()));
|
||||||
game.getState().addEffect(effectTest, ability);
|
game.getState().addEffect(gainAbility, ability);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,7 +48,7 @@ public final class TezzeretMasterOfTheBridge extends CardImpl {
|
||||||
this.addAbility(new PlaneswalkerEntersWithLoyaltyCountersAbility(5));
|
this.addAbility(new PlaneswalkerEntersWithLoyaltyCountersAbility(5));
|
||||||
|
|
||||||
// Creature and planeswalker spells you cast have affinity for artifacts.
|
// Creature and planeswalker spells you cast have affinity for artifacts.
|
||||||
this.addAbility(new SimpleStaticAbility(new GainAbilityControlledSpellsEffect(
|
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityControlledSpellsEffect(
|
||||||
new AffinityForArtifactsAbility(), filter
|
new AffinityForArtifactsAbility(), filter
|
||||||
)));
|
)));
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,8 @@ public class AffinityEffect extends CostModificationEffectImpl {
|
||||||
SpellAbility spellAbility = (SpellAbility)abilityToModify;
|
SpellAbility spellAbility = (SpellAbility)abilityToModify;
|
||||||
Mana mana = spellAbility.getManaCostsToPay().getMana();
|
Mana mana = spellAbility.getManaCostsToPay().getMana();
|
||||||
if (mana.getGeneric() > 0) {
|
if (mana.getGeneric() > 0) {
|
||||||
int count = game.getBattlefield().count(filter, source.getSourceId(), source.getControllerId(), game);
|
//int count = game.getBattlefield().count(filter, source.getSourceId(), source.getControllerId(), game); // this doesn't work with Sen Triplets
|
||||||
|
int count = game.getBattlefield().getAllActivePermanents(filter, source.getControllerId(), game).size(); // this works with Sen Triplets
|
||||||
int newCount = mana.getGeneric() - count;
|
int newCount = mana.getGeneric() - count;
|
||||||
if (newCount < 0) {
|
if (newCount < 0) {
|
||||||
newCount = 0;
|
newCount = 0;
|
||||||
|
|
|
@ -29,6 +29,6 @@ public class AffinityForArtifactsAbility extends SimpleStaticAbility {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String getRule() {
|
public String getRule() {
|
||||||
return "affinity for artifacts <i>(This spell costs {1} less to cast for each artifact you control.)</i>";
|
return "Affinity for artifacts <i>(This spell costs {1} less to cast for each artifact you control.)</i>";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue