Hid Subtypes behind MTGAllCards and added a mutex to be able to use both singleton from several threads.

This commit is contained in:
Xawotihs@gmail.com
2012-02-12 22:20:05 +00:00
parent ebc4eb331f
commit bd1afebbea
15 changed files with 74 additions and 54 deletions
+1 -1
View File
@@ -504,7 +504,7 @@ size_t MTGGameZone::getIndex(MTGCardInstance * card)
unsigned int MTGGameZone::countByType(const char * value)
{
int result = 0;
int subTypeId = Subtypes::subtypesList->find(value);
int subTypeId = MTGAllCards::findType(value);
for (int i = 0; i < (nb_cards); i++)
{
if (cards[i]->hasType(subTypeId))