Fix for issue 647 (Evil Presence cast on a swamp removes mana ability)

This commit is contained in:
wagic.the.homebrew
2011-05-08 09:06:56 +00:00
parent b2ba514d7a
commit 2c0b5baab7
10 changed files with 111 additions and 15 deletions

View File

@@ -274,7 +274,7 @@ void CardPrimitive::setName(const string& value)
std::transform(lcname.begin(), lcname.end(), lcname.begin(), ::tolower);
//This is a bug fix for plague rats and the "foreach ability"
//Right now we add names as types, so that they get recognized
if (lcname.at(value.length() - 1) == 's')
if (value.length() && lcname.at(value.length() - 1) == 's')
Subtypes::subtypesList->find(lcname);
}