Refactored case-conversion functions.
StrToLower() returns a modified copy of the string, InPlaceLowercase() modifies the string in-place.
This commit is contained in:
@@ -710,8 +710,7 @@ AString cMonster::MobTypeToString(cMonster::eType a_MobType)
|
||||
|
||||
cMonster::eType cMonster::StringToMobType(const AString & a_Name)
|
||||
{
|
||||
AString lcName(a_Name);
|
||||
StrToLower(lcName);
|
||||
AString lcName = StrToLower(a_Name);
|
||||
|
||||
// Binary-search for the lowercase name:
|
||||
int lo = 0, hi = ARRAYCOUNT(g_MobTypeNames) - 1;
|
||||
|
||||
Reference in New Issue
Block a user