Merge pull request #342 from lukaspj/fix/replace-dstrcmp

Replace uses of dStrCmp with new String::compare
This commit is contained in:
Brian Roberts 2020-10-03 17:01:12 -05:00 committed by GitHub
commit d50f1f0b81
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
85 changed files with 213 additions and 189 deletions

View file

@ -90,7 +90,7 @@ protected:
// search the technique contents for the desired parameter
for (S32 iParam = 0; iParam < pTechnique->getContents().getCount(); iParam++) {
const domAny* param = daeSafeCast<domAny>(pTechnique->getContents()[iParam]);
if (param && !dStrcmp(param->getElementName(), name))
if (param && !String::compare(param->getElementName(), name))
return param;
}
}

View file

@ -530,7 +530,7 @@ bool ColladaShapeLoader::canLoadCachedDTS(const Torque::Path& path)
//assume the dts is good since it was zipped on purpose
Torque::FS::FileSystemRef ref = Torque::FS::GetFileSystem(cachedPath);
if (ref && !dStrcmp("Zip", ref->getTypeStr()))
if (ref && !String::compare("Zip", ref->getTypeStr()))
{
bool forceLoadDAE = Con::getBoolVariable("$collada::forceLoadDAE", false);
@ -722,7 +722,7 @@ TSShape* loadColladaShape(const Torque::Path &path)
if (dtsStream.open(cachedPath.getFullPath(), Torque::FS::File::Write))
{
Torque::FS::FileSystemRef ref = Torque::FS::GetFileSystem(daePath);
if (ref && !dStrcmp("Zip", ref->getTypeStr()))
if (ref && !String::compare("Zip", ref->getTypeStr()))
Con::errorf("No cached dts file found in archive for %s. Forcing cache to disk.", daePath.getFullFileName().c_str());
Con::printf("Writing cached COLLADA shape to %s", cachedPath.getFullPath().c_str());

View file

@ -269,7 +269,7 @@ void AnimData::parseTargetString(const char* target, S32 fullCount, const char*
else if (const char* p2 = dStrrchr(target, '.')) {
// Check for named elements
for (S32 iElem = 0; elements[iElem][0] != 0; iElem++) {
if (!dStrcmp(p2, elements[iElem])) {
if (!String::compare(p2, elements[iElem])) {
targetValueOffset = iElem;
targetValueCount = 1;
break;