diff --git a/projects/mtg/bin/Res/test/_tests.txt b/projects/mtg/bin/Res/test/_tests.txt index 89f651a1c..7e25a912f 100644 --- a/projects/mtg/bin/Res/test/_tests.txt +++ b/projects/mtg/bin/Res/test/_tests.txt @@ -13,6 +13,7 @@ generic/equip_reach.txt generic/equip_shroud.txt generic/equip_shroud2.txt generic/equip_wither.txt +generic/equipment_i252.txt generic/fear.txt generic/fear_i147.txt generic/first_and_double_strike1_i187.txt diff --git a/projects/mtg/bin/Res/test/generic/equipment_i252.txt b/projects/mtg/bin/Res/test/generic/equipment_i252.txt new file mode 100644 index 000000000..64c3f6b44 --- /dev/null +++ b/projects/mtg/bin/Res/test/generic/equipment_i252.txt @@ -0,0 +1,44 @@ +#Test:equipment +#see http://code.google.com/p/wagic/issues/detail?id=252 +[INIT] +FIRSTMAIN +[PLAYER1] +manapool:{5}{G} +hand:giant spider +inplay:trusty machete +[PLAYER2] +inplay:colossus of sardia +[DO] +giant spider +trusty machete +giant spider +eot +next +#upkeep +next +#draw +next +#main +next +#begin +next +#attackers +colossus of sardia +next +#blockers +giant spider +next +#damage +next +#trample +next +#combat end +[ASSERT] +COMBATEND +[PLAYER1] +inplay:trusty machete +graveyard:giant spider +life:16 +[PLAYER2] +inplay:colossus of sardia +[END] \ No newline at end of file diff --git a/projects/mtg/src/GameObserver.cpp b/projects/mtg/src/GameObserver.cpp index 5f23d94cf..439bf5975 100644 --- a/projects/mtg/src/GameObserver.cpp +++ b/projects/mtg/src/GameObserver.cpp @@ -291,7 +291,7 @@ void GameObserver::stateEffects() card->afterDamage(); //Remove auras that don't have a valid target anymore - if (card->target && !isInPlay(card->target)){ + if (card->target && !isInPlay(card->target) && !card->hasType("equipment")){ players[i]->game->putInGraveyard(card); } }