Bazaar developer reference

CvPlayer::GetResearchAgreementCounter(PlayerTypes) const

Defined in
CvPlayer.cpp, line 19352
Class
CvPlayer
Hook name
CivHooks::CvPlayer_GetResearchAgreementCounter

Hooks

static bool BeforeCvPlayer_GetResearchAgreementCounter(const CvPlayer* self, PlayerTypes ePlayer, int& result);static void AfterCvPlayer_GetResearchAgreementCounter(const CvPlayer* self, PlayerTypes ePlayer, int& result);static int ReplaceCvPlayer_GetResearchAgreementCounter(int (*original)(const CvPlayer*, PlayerTypes), const CvPlayer* self, PlayerTypes ePlayer);CivRegisterBefore<CivHooks::CvPlayer_GetResearchAgreementCounter>(host, &BeforeCvPlayer_GetResearchAgreementCounter);CivRegisterAfter<CivHooks::CvPlayer_GetResearchAgreementCounter>(host, &AfterCvPlayer_GetResearchAgreementCounter);CivRegisterReplace<CivHooks::CvPlayer_GetResearchAgreementCounter>(host, &ReplaceCvPlayer_GetResearchAgreementCounter);

Code

19351/// Get the beakers accumulated during the RA with a player19352int CvPlayer::GetResearchAgreementCounter(PlayerTypes ePlayer) const19353{19354	CvAssertMsg(ePlayer >= 0, "eIndex is expected to be non-negative (invalid Index)");19355	CvAssertMsg(ePlayer < MAX_PLAYERS, "eIndex is expected to be within maximum bounds (invalid Index)");19356	return m_aiResearchAgreementCounter[ePlayer];19357}

Calls

Called by