Bazaar developer reference

CvPolicyAI::GetLogFileName(CvString &) const

Defined in
CvPolicyAI.cpp, line 1021
Class
CvPolicyAI
Hook name
CivHooks::CvPolicyAI_GetLogFileName

Hooks

static bool BeforeCvPolicyAI_GetLogFileName(const CvPolicyAI* self, CvString& playerName, CvString& result);static void AfterCvPolicyAI_GetLogFileName(const CvPolicyAI* self, CvString& playerName, CvString& result);static CvString ReplaceCvPolicyAI_GetLogFileName(CvString (*original)(const CvPolicyAI*, CvString&), const CvPolicyAI* self, CvString& playerName);CivRegisterBefore<CivHooks::CvPolicyAI_GetLogFileName>(host, &BeforeCvPolicyAI_GetLogFileName);CivRegisterAfter<CivHooks::CvPolicyAI_GetLogFileName>(host, &AfterCvPolicyAI_GetLogFileName);CivRegisterReplace<CivHooks::CvPolicyAI_GetLogFileName>(host, &ReplaceCvPolicyAI_GetLogFileName);

Code

1020/// Build log filename1021CvString CvPolicyAI::GetLogFileName(CvString& playerName) const1022{1023	CvString strLogName;10241025	// Open the log file1026	if(GC.getPlayerAndCityAILogSplit())1027	{1028		strLogName = "PolicyAILog_" + playerName + ".csv";1029	}1030	else1031	{1032		strLogName = "PolicyAILog.csv";1033	}10341035	return strLogName;1036}

Calls

Called by