Bazaar developer reference

CvDiplomacyAI::IsWantsResearchAgreementWithPlayer(PlayerTypes) const

Defined in
CvDiplomacyAI.cpp, line 7462
Class
CvDiplomacyAI
Hook name
CivHooks::CvDiplomacyAI_IsWantsResearchAgreementWithPlayer

Hooks

static bool BeforeCvDiplomacyAI_IsWantsResearchAgreementWithPlayer(const CvDiplomacyAI* self, PlayerTypes ePlayer, bool& result);static void AfterCvDiplomacyAI_IsWantsResearchAgreementWithPlayer(const CvDiplomacyAI* self, PlayerTypes ePlayer, bool& result);static bool ReplaceCvDiplomacyAI_IsWantsResearchAgreementWithPlayer(bool (*original)(const CvDiplomacyAI*, PlayerTypes), const CvDiplomacyAI* self, PlayerTypes ePlayer);CivRegisterBefore<CivHooks::CvDiplomacyAI_IsWantsResearchAgreementWithPlayer>(host, &BeforeCvDiplomacyAI_IsWantsResearchAgreementWithPlayer);CivRegisterAfter<CivHooks::CvDiplomacyAI_IsWantsResearchAgreementWithPlayer>(host, &AfterCvDiplomacyAI_IsWantsResearchAgreementWithPlayer);CivRegisterReplace<CivHooks::CvDiplomacyAI_IsWantsResearchAgreementWithPlayer>(host, &ReplaceCvDiplomacyAI_IsWantsResearchAgreementWithPlayer);

Code

7461/// Does this AI want to make a Research Agreement with ePlayer?7462bool CvDiplomacyAI::IsWantsResearchAgreementWithPlayer(PlayerTypes ePlayer) const7463{7464	CvAssertMsg(ePlayer >= 0, "DIPLOMACY_AI: Invalid Player Index.  Please send Jon this with your last 5 autosaves and what changelist # you're playing.");7465	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.");7466	return m_pabWantsResearchAgreementWithPlayer[ePlayer];7467}

Called by