Bazaar developer reference

SkipGUIDSeparators(const char *, uint)

Defined in
CvGameCoreUtils.cpp, line 1437
Hook name
CivHooks::CvGameCoreUtils_cpp_SkipGUIDSeparators

Hooks

static bool BeforeCvGameCoreUtils_cpp_SkipGUIDSeparators(const char* pszGUID, uint uiStartIndex, uint& result);static void AfterCvGameCoreUtils_cpp_SkipGUIDSeparators(const char* pszGUID, uint uiStartIndex, uint& result);static uint ReplaceCvGameCoreUtils_cpp_SkipGUIDSeparators(uint (*original)(const char*, uint), const char* pszGUID, uint uiStartIndex);CivRegisterBefore<CivHooks::CvGameCoreUtils_cpp_SkipGUIDSeparators>(host, &BeforeCvGameCoreUtils_cpp_SkipGUIDSeparators);CivRegisterAfter<CivHooks::CvGameCoreUtils_cpp_SkipGUIDSeparators>(host, &AfterCvGameCoreUtils_cpp_SkipGUIDSeparators);CivRegisterReplace<CivHooks::CvGameCoreUtils_cpp_SkipGUIDSeparators>(host, &ReplaceCvGameCoreUtils_cpp_SkipGUIDSeparators);

Code

1437static uint SkipGUIDSeparators(const char* pszGUID, uint uiStartIndex)1438{1439	UINT uiLength = strlen(pszGUID);1440	if(uiStartIndex < uiLength)1441	{1442		do1443		{1444			char ch = pszGUID[uiStartIndex];1445			if(ch == '{' || ch == '-' || ch == ' ')1446				++uiStartIndex;1447			else1448				break;14491450		}1451		while(uiStartIndex < uiLength);1452	}1453	return uiStartIndex;1454}

Calls

Called by