mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-15 18:28:00 +00:00
- Corrected the base logic for AssignGroupAi.
- Added AILogic to Pir's Whim.
This commit is contained in:
@@ -16,10 +16,7 @@ public class AssignGroupAi extends SpellAbilityAi {
|
||||
}
|
||||
|
||||
public SpellAbility chooseSingleSpellAbility(Player player, SpellAbility sa, List<SpellAbility> spells, Map<String, Object> params) {
|
||||
if (sa.hasParam("AILogic")) {
|
||||
return Iterables.getFirst(spells, null);
|
||||
}
|
||||
final String logic = sa.getParam("AILogic");
|
||||
final String logic = sa.getParamOrDefault("AILogic", "");
|
||||
|
||||
if (logic.equals("FriendOrFoe")) {
|
||||
if (params.containsKey("Affected") && spells.size() >= 2) {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
Name:Pir's Whim
|
||||
ManaCost:3 G
|
||||
Types:Sorcery
|
||||
A:SP$ AssignGroup | Cost$ 3 G | Defined$ Player | Choices$ DBSearch,DBSacrifice | SpellDescription$ For each player, choose friend or foe. Each friend searches their library for a land card, puts it onto the battlefield tapped, then shuffles their library. Each foe sacrifices an artifact or enchantment they control.
|
||||
A:SP$ AssignGroup | Cost$ 3 G | Defined$ Player | Choices$ DBSearch,DBSacrifice | AILogic$ FriendOrFoe | SpellDescription$ For each player, choose friend or foe. Each friend searches their library for a land card, puts it onto the battlefield tapped, then shuffles their library. Each foe sacrifices an artifact or enchantment they control.
|
||||
SVar:DBSearch:DB$ChangeZone | Origin$ Library | Destination$ Battlefield | DefinedPlayer$ Remembered | ChangeType$ Land | ChangeNum$ 1 | StackDescription$ Each friend searches their library for a land card, puts it onto the battlefield tapped, then shuffles their library. | SpellDescription$ Friend searches their library for a land card, puts it onto the battlefield tapped, then shuffles their library.
|
||||
SVar:DBSacrifice:DB$Sacrifice | Defined$ Remembered | SacValid$ Artifact,Enchantment | SacMessage$ artifact or enchantment | StackDescription$ Each foe sacrifices an artifact or enchantment they control. | SpellDescription$ Foe sacrifices an artifact or enchantment they control.
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/pirs_whim.jpg
|
||||
|
||||
Reference in New Issue
Block a user