示例#1
0
/* Load the Brain stats */
static bool bufferSBRAINLoad(const char *fileName, void **ppData)
{
	if (!loadBrainStats(fileName) || !allocComponentList(COMP_BRAIN, numBrainStats))
	{
		return false;
	}
	//not interested in this value
	*ppData = NULL;
	return true;
}
示例#2
0
/* Load the Brain stats */
static bool bufferSBRAINLoad(const char *fileName, void **ppData)
{
	WzConfig ini(fileName, WzConfig::ReadOnlyAndRequired);
	calcDataHash(ini, DATA_SBRAIN);

	if (!loadBrainStats(ini) || !allocComponentList(COMP_BRAIN, numBrainStats))
	{
		return false;
	}
	//not interested in this value
	*ppData = nullptr;
	return true;
}
示例#3
0
/* Load the Brain stats */
static bool bufferSBRAINLoad(const char *pBuffer, UDWORD size, void **ppData)
{
	calcDataHash((uint8_t *)pBuffer, size, DATA_SBRAIN);

	if (!loadBrainStats(pBuffer, size)
	 || !allocComponentList(COMP_BRAIN, numBrainStats))
	{
		return false;
	}

	//not interested in this value
	*ppData = NULL;
	return true;
}