mirror of
https://github.com/magefree/mage.git
synced 2026-01-26 05:09:16 -08:00
[DFT] Implement Howler's Heavy
This commit is contained in:
parent
3f3dfa83f1
commit
660bc0d6b4
4 changed files with 71 additions and 8 deletions
|
|
@ -13,7 +13,7 @@ import mage.game.stack.StackObject;
|
|||
public class CycleTriggeredAbility extends ZoneChangeTriggeredAbility {
|
||||
|
||||
public CycleTriggeredAbility(Effect effect, boolean optional) {
|
||||
super(Zone.ALL, effect, "When you cycle {this}, ", optional);
|
||||
super(Zone.ALL, effect, "When you cycle this card, ", optional);
|
||||
this.withRuleTextReplacement(true); // default true to replace "{this}" with "it"
|
||||
}
|
||||
|
||||
|
|
@ -32,14 +32,15 @@ public class CycleTriggeredAbility extends ZoneChangeTriggeredAbility {
|
|||
|
||||
@Override
|
||||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
if (event.getSourceId().equals(this.getSourceId())) {
|
||||
StackObject object = game.getStack().getStackObject(event.getSourceId());
|
||||
if (object != null && object.getStackAbility() instanceof CyclingAbility) {
|
||||
this.getEffects().setValue("cycleCosts", object.getStackAbility().getCosts());
|
||||
return true;
|
||||
}
|
||||
if (!event.getSourceId().equals(this.getSourceId())) {
|
||||
return false;
|
||||
}
|
||||
return false;
|
||||
StackObject object = game.getStack().getStackObject(event.getSourceId());
|
||||
if (object == null || !(object.getStackAbility() instanceof CyclingAbility)) {
|
||||
return false;
|
||||
}
|
||||
this.getEffects().setValue("cycleCosts", object.getStackAbility().getCosts());
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -356,6 +356,7 @@ public enum SubType {
|
|||
SCULPTURE("Sculpture", SubTypeSet.CreatureType),
|
||||
SERF("Serf", SubTypeSet.CreatureType),
|
||||
SERPENT("Serpent", SubTypeSet.CreatureType),
|
||||
SEAL("Seal", SubTypeSet.CreatureType),
|
||||
SERVO("Servo", SubTypeSet.CreatureType),
|
||||
SHADE("Shade", SubTypeSet.CreatureType),
|
||||
SHAMAN("Shaman", SubTypeSet.CreatureType),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue