Bazaar developer reference

CvDiplomacyAI::SetDenouncedPlayerCounter(PlayerTypes, int)

Defined in
CvDiplomacyAI.cpp, line 21676
Class
CvDiplomacyAI
Hook name
CivHooks::CvDiplomacyAI_SetDenouncedPlayerCounter

Hooks

static bool BeforeCvDiplomacyAI_SetDenouncedPlayerCounter(CvDiplomacyAI* self, PlayerTypes ePlayer, int iValue);static void AfterCvDiplomacyAI_SetDenouncedPlayerCounter(CvDiplomacyAI* self, PlayerTypes ePlayer, int iValue);static void ReplaceCvDiplomacyAI_SetDenouncedPlayerCounter(void (*original)(CvDiplomacyAI*, PlayerTypes, int), CvDiplomacyAI* self, PlayerTypes ePlayer, int iValue);CivRegisterBefore<CivHooks::CvDiplomacyAI_SetDenouncedPlayerCounter>(host, &BeforeCvDiplomacyAI_SetDenouncedPlayerCounter);CivRegisterAfter<CivHooks::CvDiplomacyAI_SetDenouncedPlayerCounter>(host, &AfterCvDiplomacyAI_SetDenouncedPlayerCounter);CivRegisterReplace<CivHooks::CvDiplomacyAI_SetDenouncedPlayerCounter>(host, &ReplaceCvDiplomacyAI_SetDenouncedPlayerCounter);

Code

21676void CvDiplomacyAI::SetDenouncedPlayerCounter(PlayerTypes ePlayer, int iValue)21677{21678	CvAssertMsg(ePlayer >= 0, "DIPLOMACY_AI: Invalid Player Index.  Please send Jon this with your last 5 autosaves and what changelist # you're playing.");21679	CvAssertMsg(ePlayer < MAX_MAJOR_CIVS, "DIPLOMACY_AI: Invalid Player Index.  Please send Jon this with your last 5 autosaves and what changelist # you're playing.");21680	m_paiDenouncedPlayerCounter[ePlayer] = iValue;21681}

Called by