mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 04:38:00 +00:00
A lot of fixes in cards.txt and the CardFactories, removed all warnings.
This commit is contained in:
@@ -3326,85 +3326,6 @@ public class CardFactory implements NewConstants {
|
||||
|
||||
|
||||
|
||||
//*************** START *********** START **************************
|
||||
else if(cardName.equals("Magus of the Disk"))
|
||||
{
|
||||
SpellAbility summoningSpell = new Spell_Permanent(card)
|
||||
{
|
||||
private static final long serialVersionUID = 2510163318362956239L;
|
||||
|
||||
public boolean canPlayAI()
|
||||
{
|
||||
boolean nevinyrralInPlay = false;
|
||||
|
||||
CardList inPlay = new CardList();
|
||||
inPlay.addAll(AllZone.Computer_Play.getCards());
|
||||
for(int i=0; i<inPlay.size(); ++i)
|
||||
{
|
||||
if( inPlay.getCard(i).getName().equals("Nevinyrral's Disk"))
|
||||
{
|
||||
nevinyrralInPlay = true;
|
||||
}
|
||||
}
|
||||
return ! nevinyrralInPlay && (0 < CardFactoryUtil.AI_getHumanCreature(card, false).size());
|
||||
}
|
||||
};
|
||||
card.clearSpellAbility();
|
||||
card.addSpellAbility(summoningSpell);
|
||||
|
||||
card.addComesIntoPlayCommand(new Command()
|
||||
{
|
||||
private static final long serialVersionUID = 1227443034730254929L;
|
||||
|
||||
public void execute()
|
||||
{
|
||||
card.tap();
|
||||
}
|
||||
});
|
||||
final SpellAbility ability = new Ability_Tap(card, "1")
|
||||
{
|
||||
private static final long serialVersionUID = -4871606824998622131L;
|
||||
|
||||
public void resolve()
|
||||
{
|
||||
CardList all = new CardList();
|
||||
all.addAll(AllZone.Human_Play.getCards());
|
||||
all.addAll(AllZone.Computer_Play.getCards());
|
||||
all = filter(all);
|
||||
|
||||
for(int i = 0; i < all.size(); i++)
|
||||
AllZone.GameAction.destroy(all.get(i));
|
||||
}
|
||||
private CardList filter(CardList list)
|
||||
{
|
||||
return list.filter(new CardListFilter()
|
||||
{
|
||||
public boolean addCard(Card c)
|
||||
{
|
||||
return c.isArtifact() || c.isCreature() || c.isEnchantment();
|
||||
}
|
||||
});
|
||||
}//filter()
|
||||
public boolean canPlayAI()
|
||||
{
|
||||
CardList human = new CardList(AllZone.Human_Play.getCards());
|
||||
CardList computer = new CardList(AllZone.Computer_Play.getCards());
|
||||
|
||||
human = human.getType("Creature");
|
||||
computer = computer.getType("Creature");
|
||||
|
||||
//the computer will at least destroy 2 more human creatures
|
||||
return computer.size() < human.size()-1 || AllZone.Computer_Life.getLife() < 7;
|
||||
}
|
||||
};//SpellAbility
|
||||
card.addSpellAbility(ability);
|
||||
ability.setDescription("1, tap: Destroy all artifacts, creatures, and enchantments.");
|
||||
ability.setStackDescription("Destroy all artifacts, creatures, and enchantments.");
|
||||
}//*************** END ************ END **************************
|
||||
|
||||
|
||||
|
||||
|
||||
//*************** START *********** START **************************
|
||||
else if(cardName.equals("Tanglebloom"))
|
||||
{
|
||||
@@ -15996,6 +15917,7 @@ return land.size() > 1 && CardFactoryUtil.AI_isMainPhase();
|
||||
}
|
||||
}
|
||||
};//Input
|
||||
ability.setDescription("W U B R G: Exile target permanent.");
|
||||
|
||||
ability.setBeforePayMana(target);
|
||||
card.addSpellAbility(ability);
|
||||
@@ -16038,7 +15960,8 @@ return land.size() > 1 && CardFactoryUtil.AI_isMainPhase();
|
||||
}
|
||||
}
|
||||
};//Input
|
||||
|
||||
ability.setDescription("1, tap: Untap target artifact.");
|
||||
|
||||
ability.setBeforePayMana(target);
|
||||
card.addSpellAbility(ability);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user