Erwan
- fix for issue 559 based on Mike's suggestions. The test suite passes
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
#Generic engine features
|
||||
########################
|
||||
generic/attacks_each_turn.txt
|
||||
generic/becomes_transform_i559.txt
|
||||
generic/bushido_1.txt
|
||||
generic/bushido_2.txt
|
||||
generic/cycling.txt
|
||||
|
||||
26
projects/mtg/bin/Res/test/generic/becomes_transform_i559.txt
Normal file
26
projects/mtg/bin/Res/test/generic/becomes_transform_i559.txt
Normal file
@@ -0,0 +1,26 @@
|
||||
#NAME: Niveous Wisps + Grizzly Bears + Execute=FAIL!
|
||||
#Card Explanation:
|
||||
#Niveous Wisps: (target creature becomes white)
|
||||
#Execute: (destroy target white creature)
|
||||
#BUG: Grizzly Bears cannot be targeted by Execute though it should be able to.
|
||||
#This is because Grizzly Bears didn't become white.
|
||||
# see http://code.google.com/p/wagic/issues/detail?id=559
|
||||
[INIT]
|
||||
firstmain
|
||||
[PLAYER1]
|
||||
hand:Niveous Wisps,Execute
|
||||
inplay:Grizzly Bears
|
||||
manapool:{W}{B}{2}
|
||||
[PLAYER2]
|
||||
[DO]
|
||||
Niveous Wisps
|
||||
Grizzly Bears
|
||||
Execute
|
||||
Grizzly Bears
|
||||
[ASSERT]
|
||||
firstmain
|
||||
[PLAYER1]
|
||||
graveyard:Niveous Wisps,Execute,Grizzly Bears
|
||||
manapool={0}
|
||||
[PLAYER2]
|
||||
[END]
|
||||
@@ -2095,7 +2095,7 @@ void PopulateColorIndexVector(list<int>& colors, const string& colorStringList,
|
||||
for (int colorIndex = Constants::MTG_COLOR_ARTIFACT; colorIndex < Constants::MTG_NB_COLORS; ++colorIndex)
|
||||
{
|
||||
// if the text is not a basic ability but contains a valid color add it to the color vector
|
||||
if ((Constants::GetBasicAbilityIndex(*iter) != -1)
|
||||
if ((Constants::GetBasicAbilityIndex(*iter) == -1)
|
||||
&& ((*iter).find(Constants::MTGColorStrings[colorIndex]) != string::npos))
|
||||
colors.push_back(colorIndex);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user