Convert dStrcmp to String::compare for more cases

This commit is contained in:
Lukas Aldershaab 2020-10-04 00:00:01 +02:00
parent c999baf7ed
commit 197a62f6ea
22 changed files with 45 additions and 45 deletions

View file

@ -129,7 +129,7 @@ void AssimpAppMaterial::initMaterial(const Torque::Path& path, Material* mat) co
aiString opacityMode;
if (AI_SUCCESS == mAIMat->Get("$mat.gltf.alphaMode", 0, 0, opacityMode))
{
if (dStrcmp("MASK", opacityMode.C_Str()) == 0)
if (String::compare("MASK", opacityMode.C_Str()) == 0)
{
translucent = true;
blendOp = Material::None;
@ -141,7 +141,7 @@ void AssimpAppMaterial::initMaterial(const Torque::Path& path, Material* mat) co
mat->mAlphaTest = true;
}
}
else if (dStrcmp("BLEND", opacityMode.C_Str()) == 0)
else if (String::compare("BLEND", opacityMode.C_Str()) == 0)
{
translucent = true;
blendOp = Material::LerpAlpha;

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());