mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 12:18:00 +00:00
add Desert (from Arabian Nights). Made possible by the new Phase code changes. Thanks Sol!
This commit is contained in:
1
.gitattributes
vendored
1
.gitattributes
vendored
@@ -1058,6 +1058,7 @@ res/cardsfolder/deranged_hermit.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/derelor.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/descendant_of_soramaro.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/desecrated_earth.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/desert.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/desert_drake.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/desert_sandstorm.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/desert_twister.txt -text svneol=native#text/plain
|
||||
|
||||
8
res/cardsfolder/desert.txt
Normal file
8
res/cardsfolder/desert.txt
Normal file
@@ -0,0 +1,8 @@
|
||||
Name:Desert
|
||||
ManaCost:no cost
|
||||
Types:Land
|
||||
Text:no text
|
||||
K:tap: add 1
|
||||
SVar:Rarity:Common
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/desert.jpg
|
||||
End
|
||||
@@ -3603,6 +3603,49 @@ class CardFactory_Lands {
|
||||
card.addSpellAbility(addMana);
|
||||
}//*************** END ************ END **************************
|
||||
|
||||
//*************** START *********** START **************************
|
||||
else if(cardName.equals("Desert")) {
|
||||
/*
|
||||
* Tap: Add 1 to your mana pool.
|
||||
* Tap: Desert deals 1 damage to target attacking creature.
|
||||
* Activate this ability only during the end of combat step.
|
||||
*/
|
||||
final String Tgts[] = {"Creature.attacking"};
|
||||
Target target = new Target("TgtV", "Select target attacking creature.", Tgts);
|
||||
Ability_Cost abCost = new Ability_Cost("T", card.getName(), true);
|
||||
|
||||
final SpellAbility ability = new Ability_Activated(card, abCost, target) {
|
||||
private static final long serialVersionUID = 4707010813373688290L;
|
||||
|
||||
@Override
|
||||
public boolean canPlayAI() {
|
||||
CardList list = AllZoneUtil.getCreaturesInPlay(card.getController().getOpponent());
|
||||
list = list.filter(new CardListFilter() {
|
||||
public boolean addCard(Card c) {
|
||||
return c.isAttacking();
|
||||
}
|
||||
});
|
||||
return list.size() > 0 && canPlay();
|
||||
}//canPlayAI()
|
||||
|
||||
@Override
|
||||
public boolean canPlay() {
|
||||
return AllZone.Phase.getPhase().equals(Constant.Phase.Combat_End);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void resolve() {
|
||||
if(getTargetCard() == null) return;
|
||||
Card c = getTargetCard();
|
||||
c.addDamage(1, card);
|
||||
|
||||
}//resolve()
|
||||
};//SpellAbility
|
||||
|
||||
ability.setDescription(abCost+"Desert deals 1 damage to target attacking creature. Activate this ability only during the end of combat step.");
|
||||
card.addSpellAbility(ability);//ability.setBeforePayMana(CardFactoryUtil.input_targetCreatureKeyword_NoCost_TapAbility("Flying", ability));
|
||||
}//*************** END ************ END **************************
|
||||
|
||||
return card;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user