Bazaar developer reference

CvDiplomacyAI::GetDeclarationLogData1ForIndex(int)

Defined in
CvDiplomacyAI.cpp, line 25125
Class
CvDiplomacyAI
Hook name
CivHooks::CvDiplomacyAI_GetDeclarationLogData1ForIndex

Hooks

static bool BeforeCvDiplomacyAI_GetDeclarationLogData1ForIndex(CvDiplomacyAI* self, int iIndex, int& result);static void AfterCvDiplomacyAI_GetDeclarationLogData1ForIndex(CvDiplomacyAI* self, int iIndex, int& result);static int ReplaceCvDiplomacyAI_GetDeclarationLogData1ForIndex(int (*original)(CvDiplomacyAI*, int), CvDiplomacyAI* self, int iIndex);CivRegisterBefore<CivHooks::CvDiplomacyAI_GetDeclarationLogData1ForIndex>(host, &BeforeCvDiplomacyAI_GetDeclarationLogData1ForIndex);CivRegisterAfter<CivHooks::CvDiplomacyAI_GetDeclarationLogData1ForIndex>(host, &AfterCvDiplomacyAI_GetDeclarationLogData1ForIndex);CivRegisterReplace<CivHooks::CvDiplomacyAI_GetDeclarationLogData1ForIndex>(host, &ReplaceCvDiplomacyAI_GetDeclarationLogData1ForIndex);

Code

25124/// Returns the DeclarationLog iData1 number associated with the index passed in25125int CvDiplomacyAI::GetDeclarationLogData1ForIndex(int iIndex)25126{25127	CvAssertMsg(iIndex >= 0, "DIPLOMACY_AI: Invalid DiploLogStatement Index.  Please send Jon this with your last 5 autosaves and what changelist # you're playing.");25128	CvAssertMsg(iIndex < MAX_DIPLO_LOG_STATEMENTS, "DIPLOMACY_AI: Invalid DiploLogStatement Index.  Please send Jon this with your last 5 autosaves and what changelist # you're playing.");25129	return m_paDeclarationsLog[iIndex].m_iData1;25130}

Called by