Remove all _Myfirs from vectors.

This commit is contained in:
rodrigodemoura@gmail.com
2011-10-13 18:00:16 +00:00
parent 71949f636d
commit 663058cdab
2 changed files with 4 additions and 4 deletions
+1 -1
View File
@@ -134,7 +134,7 @@ void CardPrimitive::setColor(const string& _color, int removeAllOthers)
{
for( size_t i =0 ; i< Constants::MTGColorStrings.size(); i++)
{
if (_color.compare(Constants::MTGColorStrings._Myfirst[i]) == 0)
if (_color.compare(Constants::MTGColorStrings[i]) == 0)
return setColor(i, removeAllOthers);
}
//Keep artifact compare, to Remove this we need change all MTG.txt
+3 -3
View File
@@ -250,7 +250,7 @@ ManaCost::ManaCost(vector<int8_t>& _cost, int nb_elems)
init();
for (int i = 0; i < nb_elems; i++)
{
cost[_cost._Myfirst[i * 2]] = _cost._Myfirst[i * 2 + 1];
cost[_cost[i * 2]] = _cost[i * 2 + 1];
}
}
@@ -638,7 +638,7 @@ int ManaCost::isPositive()
for (int i = 0; i < Constants::NB_Colors; i++)
{
if (cost._Myfirst[i] < 0)
if (cost[i] < 0)
{
return 0;
}
@@ -696,7 +696,7 @@ ManaCost * ManaCost::Diff(ManaCost * _cost)
for (int i = 0; i < Constants::NB_Colors; i++)
{
diff[i * 2] = i;
diff[i * 2 + 1] = cost._Myfirst[i] - _cost->getCost(i);
diff[i * 2 + 1] = cost[i] - _cost->getCost(i);
}
int hybridResult = tryToPayHybrids(_cost->hybrids, _cost->hybrids.size(), diff);
if (!hybridResult)