fixed a bug where "becomes(" was no longer giving more the a single ability to a card, example, inkmoth nexus would only gain flying, and not gain infect, this i imagine was due in part to a goof up...we split the string at the top by comma, in the refactor for this section it was changed to be either "" or becomesblah[2] <--this is incorrect, becuase what if a card would gain 2 abilities or more ...the we need to append the rest of the split portions back into the abilities string for adding.
also a piece that didn't get in my last commit, nothing big just 2 lines...not sure why on earth it didn't commit them before...
This commit is contained in:
@@ -1956,8 +1956,16 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
newToughness = pt[1];
|
||||
ptFound = true;
|
||||
}
|
||||
string sabilities = (becomesParameters.size() > 2) ? becomesParameters[2] : "";
|
||||
|
||||
string sabilities = "";
|
||||
if(becomesParameters.size() > 2)
|
||||
{
|
||||
for(unsigned int i = 2;i < becomesParameters.size();i++)
|
||||
{
|
||||
sabilities.append(becomesParameters[i].c_str());
|
||||
if(i+1 < becomesParameters.size())
|
||||
sabilities.append(",");
|
||||
}
|
||||
}
|
||||
if (oneShot || forceUEOT)
|
||||
return NEW ATransformerInstant(id, card, target, stypes, sabilities,newPower,ptFound,newToughness,ptFound,vector<string>(),false,forceFOREVER);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user