diff --git a/projects/mtg/bin/Res/test/_tests.txt b/projects/mtg/bin/Res/test/_tests.txt index b90a86b98..a6c2a2553 100644 --- a/projects/mtg/bin/Res/test/_tests.txt +++ b/projects/mtg/bin/Res/test/_tests.txt @@ -74,6 +74,7 @@ bottle_gnomes.txt bottle_gnomes2.txt boggart_arsonists.txt brass_man.txt +cage_of_hands.txt Call_to_Heel_1.txt Call_to_Heel_2.txt castle.txt diff --git a/projects/mtg/bin/Res/test/cage_of_hands.txt b/projects/mtg/bin/Res/test/cage_of_hands.txt new file mode 100644 index 000000000..13be21e1f --- /dev/null +++ b/projects/mtg/bin/Res/test/cage_of_hands.txt @@ -0,0 +1,24 @@ +#Bug:Cage of hands doesn't return to its owner's hand +[INIT] +FIRSTMAIN +[PLAYER1] +hand:cage of hands +manapool:{2}{W} +inplay:swamp,plains +[PLAYER2] +inplay:grizzly bears +[DO] +cage of hands +grizzly bears +plains +swamp +cage of hands +[ASSERT] +FIRSTMAIN +[PLAYER1] +hand:cage of hands +inplay:swamp,plains +manapool:{0} +[PLAYER2] +inplay:grizzly bears +[END] \ No newline at end of file diff --git a/projects/mtg/src/MTGAbility.cpp b/projects/mtg/src/MTGAbility.cpp index 86edb9637..30a490c85 100644 --- a/projects/mtg/src/MTGAbility.cpp +++ b/projects/mtg/src/MTGAbility.cpp @@ -401,6 +401,11 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG if (found != string::npos){ int end = s.find(")",found+1); string szone = s.substr(found + 7,end - found - 7); + + //hack for http://code.google.com/p/wagic/issues/detail?id=120 + //We assume that auras don't move their own target... + if (card->hasType("aura")) target = card; + MTGAbility * a = NEW AAMover(id,card,target,szone); a->oneShot = 1; return a;