Fix for Defense of the Heart
by mtgrares
Moderators: timmermac, Blacksmith, KrazyTheFox, Agetian, friarsol, CCGHQ Admins
Fix for Defense of the Heart
by jpb » 09 Jan 2009, 07:26
Nixrage pointed out that the computer was not picking it's own creatures when it sacrificed Defense of the Heart. To fix this replace the current getCreatureFromLibrary method in GameActionUtil.java with the following one.
- Code: Select all
public Card getCreatureFromLibrary(){
PlayerZone library = AllZone.getZone(Constant.Zone.Library, card.getController());
CardList creatureList = new CardList(library.getCards());
creatureList = creatureList.getType("Creature");
if(Constant.Player.Computer.equals(card.getController())){
return CardFactoryUtil.AI_getBestCreature(creatureList);
}
else{
Object o = AllZone.Display.getChoiceOptional("Choose a creature card", creatureList.toArray());
if(o != null)
{
Card creature = (Card)o;
return creature;
}
else{
return null;
}
}
}
- jpb
- Posts: 132
- Joined: 05 Sep 2008, 13:12
- Has thanked: 0 time
- Been thanked: 0 time
1 post
• Page 1 of 1
Who is online
Users browsing this forum: Google [Bot] and 16 guests