Changeset 5307 in orxonox.OLD for trunk/src/util
- Timestamp:
- Oct 7, 2005, 6:47:24 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/util/resource_manager.cc
r5306 r5307 251 251 { 252 252 PRINTF(4)("not loading cached resource %s\n", tmpResource->name); 253 printf("adding %s count: %d\n", tmpResource->pointer->getName(), tmpResource->count);253 // printf("adding %s count: %d\n", tmpResource->pointer->getName(), tmpResource->count); 254 254 tmpResource->count++; 255 255 if(tmpResource->prio < prio) … … 258 258 else 259 259 { 260 char* tmpDir;261 260 // Setting up the new Resource 262 261 tmpResource = new Resource; … … 321 320 #ifndef NO_TEXT 322 321 case TTF: 323 if (param1 )322 if (param1 != NULL) 324 323 tmpResource->ttfSize = *(unsigned int*)param1; 325 324 else … … 351 350 else 352 351 { 352 char* tmpDir; 353 353 tIterator<char>* iterator = imageDirs->getIterator(); 354 354 tmpDir = iterator->firstElement(); … … 421 421 if (resource == NULL) 422 422 return false; 423 printf("removing %s count: %d\n", resource->pointer->getName(), resource->count);423 // printf("removing %s count: %d\n", resource->pointer->getName(), resource->count); 424 424 if (resource->count > 0) 425 425 resource->count--; … … 521 521 { 522 522 bool match = false; 523 bool subMatch = false;524 523 525 524 switch (type) … … 542 541 match = true; 543 542 } 544 else if ( enumRes->skinFileName!= NULL && !strcmp(enumRes->skinFileName, (const char*)param1))543 else if (!strcmp(enumRes->skinFileName, (const char*)param1)) 545 544 match = true; 546 545 break; … … 548 547 #ifndef NO_TEXT 549 548 case TTF: 550 if ( !param1)549 if (param1 == NULL) 551 550 { 552 551 if (enumRes->ttfSize == FONT_DEFAULT_SIZE) 553 subMatch = true;552 match = true; 554 553 } 555 554 else if (enumRes->ttfSize == *(unsigned int*)param1) 556 subMatch = true;555 match = true; 557 556 break; 558 557 #endif /* NO_TEXT */
Note: See TracChangeset
for help on using the changeset viewer.