refactor canproducemana

This commit is contained in:
Anthony Calosa
2017-02-16 16:55:13 +08:00
parent 5a3a32462d
commit 0a68a056d8
5 changed files with 69 additions and 31 deletions

View File

@@ -579,7 +579,7 @@ TargetChooser * TargetChooserFactory::createTargetChooser(string s, MTGCardInsta
{
cd->CDdamager = 1;
}
}/*
}
//can produce mana
else if (attribute.find("cmana") != string::npos)
{
@@ -591,6 +591,7 @@ TargetChooser * TargetChooserFactory::createTargetChooser(string s, MTGCardInsta
{
cd->CDcanProduceC = 1;
}
cd->mode = CardDescriptor::CD_OR;
}
else if (attribute.find("manag") != string::npos)
{
@@ -602,6 +603,7 @@ TargetChooser * TargetChooserFactory::createTargetChooser(string s, MTGCardInsta
{
cd->CDcanProduceG = 1;
}
cd->mode = CardDescriptor::CD_OR;
}
else if (attribute.find("manau") != string::npos)
{
@@ -613,6 +615,7 @@ TargetChooser * TargetChooserFactory::createTargetChooser(string s, MTGCardInsta
{
cd->CDcanProduceU = 1;
}
cd->mode = CardDescriptor::CD_OR;
}
else if (attribute.find("manar") != string::npos)
{
@@ -624,6 +627,7 @@ TargetChooser * TargetChooserFactory::createTargetChooser(string s, MTGCardInsta
{
cd->CDcanProduceR = 1;
}
cd->mode = CardDescriptor::CD_OR;
}
else if (attribute.find("manab") != string::npos)
{
@@ -635,6 +639,7 @@ TargetChooser * TargetChooserFactory::createTargetChooser(string s, MTGCardInsta
{
cd->CDcanProduceB = 1;
}
cd->mode = CardDescriptor::CD_OR;
}
else if (attribute.find("manaw") != string::npos)
{
@@ -646,7 +651,8 @@ TargetChooser * TargetChooserFactory::createTargetChooser(string s, MTGCardInsta
{
cd->CDcanProduceW = 1;
}
}*/
cd->mode = CardDescriptor::CD_OR;
}
else if (attribute.find("multicolor") != string::npos)
{
//card is multicolored?