mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 12:18:00 +00:00
- Treva, the Renewer, Rith, the Awakener and Oros, the Avenger are usable by the AI now, and fixed a bug involving Control Magic and either of these cards.
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<java version="1.6.0_11" class="java.beans.XMLDecoder">
|
<java version="1.6.0_16" class="java.beans.XMLDecoder">
|
||||||
<object id="MultiSplitLayout$Split0" class="org.jdesktop.swingx.MultiSplitLayout$Split">
|
<object id="MultiSplitLayout$Split0" class="org.jdesktop.swingx.MultiSplitLayout$Split">
|
||||||
<void property="bounds">
|
<void property="bounds">
|
||||||
<object class="java.awt.Rectangle">
|
<object class="java.awt.Rectangle">
|
||||||
|
|||||||
@@ -12340,31 +12340,28 @@ public class CardFactory_Creatures {
|
|||||||
//*************** START *********** START **************************
|
//*************** START *********** START **************************
|
||||||
else if (cardName.equals("Oros, the Avenger"))
|
else if (cardName.equals("Oros, the Avenger"))
|
||||||
{
|
{
|
||||||
final String player = card.getController();
|
|
||||||
|
|
||||||
final Ability ability2 = new Ability(card, "2 W")
|
final Ability ability2 = new Ability(card, "2 W")
|
||||||
{
|
{
|
||||||
public void resolve()
|
public void resolve()
|
||||||
{
|
{
|
||||||
if (player.equals("Human"))
|
//if (player.equals("Human"))
|
||||||
{
|
//{
|
||||||
CardList cards = new CardList();
|
CardList cards = new CardList();
|
||||||
PlayerZone hum = AllZone.getZone(Constant.Zone.Play, Constant.Player.Human);
|
PlayerZone hum = AllZone.getZone(Constant.Zone.Play, Constant.Player.Human);
|
||||||
PlayerZone comp = AllZone.getZone(Constant.Zone.Play, Constant.Player.Computer);
|
PlayerZone comp = AllZone.getZone(Constant.Zone.Play, Constant.Player.Computer);
|
||||||
cards.addAll(hum.getCards());
|
cards.addAll(hum.getCards());
|
||||||
cards.addAll(comp.getCards());
|
cards.addAll(comp.getCards());
|
||||||
cards = cards.getType("Creature");
|
cards = cards.getType("Creature");
|
||||||
|
|
||||||
for (int i=0;i<cards.size(); i++)
|
for (int i=0;i<cards.size(); i++)
|
||||||
{
|
{
|
||||||
if (!CardUtil.getColors(cards.get(i)).contains(Constant.Color.White)
|
if (!CardUtil.getColors(cards.get(i)).contains(Constant.Color.White)
|
||||||
&& CardFactoryUtil.canDamage(card, cards.get(i)))
|
&& CardFactoryUtil.canDamage(card, cards.get(i)))
|
||||||
{
|
{
|
||||||
cards.get(i).addDamage(3, card);
|
cards.get(i).addDamage(3, card);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
//}
|
||||||
}
|
|
||||||
}
|
}
|
||||||
public boolean canPlay()
|
public boolean canPlay()
|
||||||
{
|
{
|
||||||
@@ -12374,7 +12371,7 @@ public class CardFactory_Creatures {
|
|||||||
};// ability2
|
};// ability2
|
||||||
//card.clearSpellAbility();
|
//card.clearSpellAbility();
|
||||||
card.addSpellAbility(ability2);
|
card.addSpellAbility(ability2);
|
||||||
ability2.setStackDescription(card.getName() + " - " + player + " deals 3 damage to each nonwhite creature.");
|
ability2.setStackDescription(card.getName() + " - deals 3 damage to each nonwhite creature.");
|
||||||
|
|
||||||
|
|
||||||
}//*************** END ************ END **************************
|
}//*************** END ************ END **************************
|
||||||
@@ -12390,7 +12387,7 @@ public class CardFactory_Creatures {
|
|||||||
public void resolve()
|
public void resolve()
|
||||||
{
|
{
|
||||||
int lifeGain = 0;
|
int lifeGain = 0;
|
||||||
if (player.equals("Human"))
|
if (card.getController().equals("Human"))
|
||||||
{
|
{
|
||||||
String choices[] = {"white", "blue" , "black" , "red" , "green"};
|
String choices[] = {"white", "blue" , "black" , "red" , "green"};
|
||||||
Object o = AllZone.Display.getChoiceOptional("Select Color: ", choices);
|
Object o = AllZone.Display.getChoiceOptional("Select Color: ", choices);
|
||||||
@@ -12398,8 +12395,18 @@ public class CardFactory_Creatures {
|
|||||||
lifeGain = CardFactoryUtil.getNumberOfPermanentsByColor((String)o);
|
lifeGain = CardFactoryUtil.getNumberOfPermanentsByColor((String)o);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
PlayerZone cPlay = AllZone.getZone(Constant.Zone.Play, Constant.Player.Computer);
|
||||||
|
PlayerZone hPlay = AllZone.getZone(Constant.Zone.Play, Constant.Player.Human);
|
||||||
|
CardList list = new CardList();
|
||||||
|
list.addAll(cPlay.getCards());
|
||||||
|
list.addAll(hPlay.getCards());
|
||||||
|
String color = CardFactoryUtil.getMostProminentColor(list);
|
||||||
|
lifeGain = CardFactoryUtil.getNumberOfPermanentsByColor(color);
|
||||||
|
}
|
||||||
|
|
||||||
PlayerLife life = AllZone.GameAction.getPlayerLife(player);
|
PlayerLife life = AllZone.GameAction.getPlayerLife(card.getController());
|
||||||
life.addLife(lifeGain);
|
life.addLife(lifeGain);
|
||||||
}
|
}
|
||||||
public boolean canPlay()
|
public boolean canPlay()
|
||||||
@@ -12426,13 +12433,23 @@ public class CardFactory_Creatures {
|
|||||||
public void resolve()
|
public void resolve()
|
||||||
{
|
{
|
||||||
int numberTokens = 0;
|
int numberTokens = 0;
|
||||||
if (player.equals("Human"))
|
if (card.getController().equals("Human"))
|
||||||
{
|
{
|
||||||
String choices[] = {"white", "blue" , "black" , "red" , "green"};
|
String choices[] = {"white", "blue" , "black" , "red" , "green"};
|
||||||
Object o = AllZone.Display.getChoiceOptional("Select Color: ", choices);
|
Object o = AllZone.Display.getChoiceOptional("Select Color: ", choices);
|
||||||
//System.out.println("Color:" + o);
|
//System.out.println("Color:" + o);
|
||||||
numberTokens = CardFactoryUtil.getNumberOfPermanentsByColor((String)o);
|
numberTokens = CardFactoryUtil.getNumberOfPermanentsByColor((String)o);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
PlayerZone cPlay = AllZone.getZone(Constant.Zone.Play, Constant.Player.Computer);
|
||||||
|
PlayerZone hPlay = AllZone.getZone(Constant.Zone.Play, Constant.Player.Human);
|
||||||
|
CardList list = new CardList();
|
||||||
|
list.addAll(cPlay.getCards());
|
||||||
|
list.addAll(hPlay.getCards());
|
||||||
|
String color = CardFactoryUtil.getMostProminentColor(list);
|
||||||
|
numberTokens = CardFactoryUtil.getNumberOfPermanentsByColor(color);
|
||||||
|
}
|
||||||
|
|
||||||
for (int i=0;i<numberTokens;i++)
|
for (int i=0;i<numberTokens;i++)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user