mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 04:08:01 +00:00
add AEthermage's Touch (from Dissension)
This commit is contained in:
1
.gitattributes
vendored
1
.gitattributes
vendored
@@ -172,6 +172,7 @@ res/cardsfolder/aether_tradewinds.txt svneol=native#text/plain
|
||||
res/cardsfolder/aether_vial.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/aether_web.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/aetherflame_wall.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/aethermages_touch.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/aethersnipe.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/affa_guard_hound.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/afflict.txt -text svneol=native#text/plain
|
||||
|
||||
9
res/cardsfolder/aethermages_touch.txt
Normal file
9
res/cardsfolder/aethermages_touch.txt
Normal file
@@ -0,0 +1,9 @@
|
||||
Name:AEthermage's Touch
|
||||
ManaCost:2 W U
|
||||
Types:Instant
|
||||
Text:no text
|
||||
A:SP$ Dig | Cost$ 2 W U | DigNum$ 4 | Reveal$ True | ChangeNum$ 1 | Optional$ True | ChangeValid$ Creature | DestinationZone$ Battlefield | Keywords$ HIDDEN At the beginning of your end step, return CARDNAME to its owner's hand.| SpellDescription$ Reveal the top four cards of your library. You may put a creature card from among them onto the battlefield. It has "At the beginning of your end step, return this creature to its owner's hand." Then put the rest of the cards revealed this way on the bottom of your library in any order.
|
||||
SVar:RemAIDeck:True
|
||||
SVar:Rarity:Rare
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/aethermages_touch.jpg
|
||||
End
|
||||
@@ -159,6 +159,24 @@ public class EndOfTurn implements java.io.Serializable
|
||||
AllZone.Stack.addSimultaneousStackEntry(change);
|
||||
|
||||
}
|
||||
if(c.hasKeyword("At the beginning of your end step, return CARDNAME to its owner's hand.")
|
||||
&& AllZone.Phase.isPlayerTurn(c.getController())) {
|
||||
final Card source = c;
|
||||
final SpellAbility change = new Ability(source, "0") {
|
||||
@Override
|
||||
public void resolve() {
|
||||
if(AllZoneUtil.isCardInPlay(source)) {
|
||||
AllZone.GameAction.moveToHand(source);
|
||||
}
|
||||
}
|
||||
};
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.append(source).append(" - At the beginning of your end step, return CARDNAME to its owner's hand.");
|
||||
change.setStackDescription(sb.toString());
|
||||
|
||||
AllZone.Stack.addSimultaneousStackEntry(change);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@ package forge.card.abilityFactory;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.Random;
|
||||
import java.util.Arrays;
|
||||
|
||||
import javax.swing.JOptionPane;
|
||||
|
||||
@@ -224,6 +225,10 @@ public class AbilityFactory_Reveal {
|
||||
boolean optional = params.containsKey("Optional");
|
||||
boolean noMove = params.containsKey("NoMove");
|
||||
boolean changeAll = false;
|
||||
ArrayList<String> keywords = new ArrayList<String>();
|
||||
if(params.containsKey("Keywords")) {
|
||||
keywords.addAll(Arrays.asList(params.get("Keywords").split(" & ")));
|
||||
}
|
||||
|
||||
if(params.containsKey("ChangeNum")) {
|
||||
if(params.get("ChangeNum").equalsIgnoreCase("All")) changeAll = true;
|
||||
@@ -324,7 +329,10 @@ public class AbilityFactory_Reveal {
|
||||
AllZone.GameAction.moveToLibrary(chosen, libraryPosition);
|
||||
}
|
||||
else {
|
||||
AllZone.GameAction.moveTo(zone, chosen);
|
||||
Card c = AllZone.GameAction.moveTo(zone, chosen);
|
||||
if(destZone1.equals("Battlefield") && !keywords.isEmpty()) {
|
||||
for(String kw : keywords) c.addExtrinsicKeyword(kw);
|
||||
}
|
||||
}
|
||||
//AllZone.GameAction.revealToComputer() - for when this exists
|
||||
j++;
|
||||
@@ -372,8 +380,12 @@ public class AbilityFactory_Reveal {
|
||||
for(int i = 0; i < rest.size(); i++) {
|
||||
Card c = rest.get(i);
|
||||
PlayerZone toZone = AllZone.getZone(destZone2, c.getOwner());
|
||||
AllZone.GameAction.moveTo(toZone, c);
|
||||
c = AllZone.GameAction.moveTo(toZone, c);
|
||||
if(destZone2.equals("Battlefield") && !keywords.isEmpty()) {
|
||||
for(String kw : keywords) c.addExtrinsicKeyword(kw);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}//end if canTarget
|
||||
|
||||
Reference in New Issue
Block a user