Moves from using dStrCmp to the new String::compare static functions. Keeps things cleaner, consistent, and works with intellisense.

This commit is contained in:
Lukas Aldershaab 2020-10-03 14:37:55 +02:00
parent 76c5e30869
commit c999baf7ed
68 changed files with 168 additions and 144 deletions

View file

@ -1108,11 +1108,11 @@ DefineEngineMethod(AIPlayer, getNavMesh, S32, (),,
DefineEngineMethod(AIPlayer, setNavSize, void, (const char *size),,
"@brief Set the size of NavMesh this character uses. One of \"Small\", \"Regular\" or \"Large\".")
{
if(!dStrcmp(size, "Small"))
if(!String::compare(size, "Small"))
object->setNavSize(AIPlayer::Small);
else if(!dStrcmp(size, "Regular"))
else if(!String::compare(size, "Regular"))
object->setNavSize(AIPlayer::Regular);
else if(!dStrcmp(size, "Large"))
else if(!String::compare(size, "Large"))
object->setNavSize(AIPlayer::Large);
else
Con::errorf("AIPlayer::setNavSize: no such size '%s'.", size);