- Added Reins of Power

This commit is contained in:
swordshine
2013-05-24 04:31:50 +00:00
parent b1b9b1d3b7
commit 44e967bfcb
5 changed files with 25 additions and 2 deletions

1
.gitattributes vendored
View File

@@ -8664,6 +8664,7 @@ res/cardsfolder/r/reign_of_terror.txt -text
res/cardsfolder/r/reincarnation.txt -text
res/cardsfolder/r/reinforced_bulwark.txt svneol=native#text/plain
res/cardsfolder/r/reinforcements.txt svneol=native#text/plain
res/cardsfolder/r/reins_of_power.txt -text
res/cardsfolder/r/reins_of_the_vinesteed.txt -text
res/cardsfolder/r/reiterate.txt svneol=native#text/plain
res/cardsfolder/r/reito_lantern.txt svneol=native#text/plain

View File

@@ -2,7 +2,7 @@ Name:Blood Reckoning
ManaCost:3 B
Types:Enchantment
T:Mode$ Attacks | ValidCard$ Creature.YouDontCtrl | Attacked$ You,Planeswalker.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigLoseLife | TriggerDescription$ Whenever a creature attacks you or a planeswalker you control, that creature's controller loses 1 life.
SVar:TrigLoseLife:AB$ LoseLife | Cost$ 0 | Defined$ TriggeredAttackerController | LifeAmount$ 1 | SpellDescription$ Whenever a creature attacks you, its controller loses 1 life.
SVar:TrigLoseLife:AB$ LoseLife | Cost$ 0 | Defined$ TriggeredAttackerController | LifeAmount$ 1
SVar:Picture:http://www.wizards.com/global/images/magic/general/blood_reckoning.jpg
Oracle:Whenever a creature attacks you or a planeswalker you control, that creature's controller loses 1 life.
SetInfo:M13 Uncommon

View File

@@ -0,0 +1,12 @@
Name:Reins of Power
ManaCost:2 U U
Types:Instant
A:SP$ UntapAll | Cost$ 2 U U | ValidTgts$ Opponent | TgtPrompt$ Select target opponent | ValidCards$ Creature | RememberTargets$ True | RememberUntapped$ True | SubAbility$ DBUnTapYours | SpellDescription$ Untap all creatures you control and all creatures target opponent controls. You and that opponent each gain control of all creatures the other controls until end of turn. Those creatures gain haste until end of turn.
SVar:DBUnTapYours:DB$ UntapAll | ValidCards$ Creature.YouCtrl | RememberUntapped$ True | SubAbility$ DBGainCtrl
SVar:DBGainCtrl:DB$ GainControl | AllValid$ Creature.IsRemembered+RememberedPlayerCtrl | AddKWs$ Haste | NewController$ You | LoseControl$ EOT | ForgetControlled$ True | StackDescription$ None | SubAbility$ DBGainCtrlOpp
SVar:DBGainCtrlOpp:DB$ GainControl | AllValid$ Creature.IsRemembered+YouCtrl | AddKWs$ Haste | NewController$ Player.IsRemembered | LoseControl$ EOT | StackDescription$ None | SubAbility$ DBCleanup
SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True
SVar:Picture:http://www.wizards.com/global/images/magic/general/reins_of_power.jpg
Oracle:Untap all creatures you control and all creatures target opponent controls. You and that opponent each gain control of all creatures the other controls until end of turn. Those creatures gain haste until end of turn.
SetInfo:COM Rare
SetInfo:STH Rare

View File

@@ -80,6 +80,8 @@ public class ControlGainEffect extends SpellAbilityEffect {
final boolean bUntap = sa.hasParam("Untap");
final boolean bTapOnLose = sa.hasParam("TapOnLose");
final boolean bNoRegen = sa.hasParam("NoRegen");
final boolean remember = sa.hasParam("RememberControlled");
final boolean forget = sa.hasParam("ForgetControlled");
final List<String> destroyOn = sa.hasParam("DestroyTgt") ? Arrays.asList(sa.getParam("DestroyTgt").split(",")) : null;
final List<String> kws = sa.hasParam("AddKWs") ? Arrays.asList(sa.getParam("AddKWs").split(" & ")) : null;
final List<String> lose = sa.hasParam("LoseControl") ? Arrays.asList(sa.getParam("LoseControl").split(",")) : null;
@@ -142,6 +144,14 @@ public class ControlGainEffect extends SpellAbilityEffect {
}
}
if (remember && !sa.getSourceCard().getRemembered().contains(tgtC)) {
sa.getSourceCard().addRemembered(tgtC);
}
if (forget && sa.getSourceCard().getRemembered().contains(tgtC)) {
sa.getSourceCard().removeRemembered(tgtC);
}
if (lose != null) {
if (lose.contains("LeavesPlay")) {
sa.getSourceCard().addLeavesPlayCommand(this.getLoseControlCommand(tgtC, tStamp, bTapOnLose, source, kws));

View File

@@ -92,7 +92,7 @@ public class RepeatEachEffect extends SpellAbilityEffect {
if (sa.hasParam("RepeatCounters")) {
Card target = sa.getTargetCard();
if (target == null) {
target = AbilityUtils.getDefinedCards(sa.getSourceCard(), sa.getParam("Defined"), sa).get(0);
target = AbilityUtils.getDefinedCards(source, sa.getParam("Defined"), sa).get(0);
}
Set<CounterType> types = new HashSet<CounterType>(target.getCounters().keySet());
for (CounterType type : types) {