Replace AString with std::string.
This commit is contained in:
@@ -59,7 +59,7 @@ struct StringPolicy
|
||||
{
|
||||
return ke::FastHashCharSequence(key, strlen(key));
|
||||
}
|
||||
static inline bool matches(const char *find, const ke::AString &key)
|
||||
static inline bool matches(const char *find, const std::string &key)
|
||||
{
|
||||
return key.compare(find) == 0;
|
||||
}
|
||||
@@ -89,7 +89,7 @@ struct WeaponIDPolicy
|
||||
}
|
||||
};
|
||||
|
||||
typedef ke::HashMap<ke::AString, ItemDefHashValue, StringPolicy> ClassnameMap;
|
||||
typedef ke::HashMap<std::string, ItemDefHashValue, StringPolicy> ClassnameMap;
|
||||
typedef ke::HashMap<int, ItemDefHashValue, IntegerPolicy> ItemIndexMap;
|
||||
typedef ke::HashMap<SMCSWeapon, ItemDefHashValue, WeaponIDPolicy> WeaponIDMap;
|
||||
|
||||
|
||||
@@ -291,7 +291,7 @@ void CreateHashMaps()
|
||||
int iLoadoutslot = node.pDef->GetDefaultLoadoutSlot();
|
||||
|
||||
ClassnameMap::Insert i = g_mapClassToDefIdx.findForAdd(classname);
|
||||
g_mapClassToDefIdx.add(i, ke::AString(classname), ItemDefHashValue(iLoadoutslot, price, iWeaponID, iItemDefIdx, classname));
|
||||
g_mapClassToDefIdx.add(i, std::string(classname), ItemDefHashValue(iLoadoutslot, price, iWeaponID, iItemDefIdx, classname));
|
||||
|
||||
ItemIndexMap::Insert x = g_mapDefIdxToClass.findForAdd(iItemDefIdx);
|
||||
g_mapDefIdxToClass.add(x, iItemDefIdx, ItemDefHashValue(iLoadoutslot, price, iWeaponID, iItemDefIdx, classname));
|
||||
|
||||
Reference in New Issue
Block a user