Bazaar developer reference

CvCityReligions::GetFollowersOtherReligions(ReligionTypes)

Defined in
CvReligionClasses.cpp, line 3719
Class
CvCityReligions
Hook name
CivHooks::CvCityReligions_GetFollowersOtherReligions

Hooks

static bool BeforeCvCityReligions_GetFollowersOtherReligions(CvCityReligions* self, ReligionTypes eReligion, int& result);static void AfterCvCityReligions_GetFollowersOtherReligions(CvCityReligions* self, ReligionTypes eReligion, int& result);static int ReplaceCvCityReligions_GetFollowersOtherReligions(int (*original)(CvCityReligions*, ReligionTypes), CvCityReligions* self, ReligionTypes eReligion);CivRegisterBefore<CivHooks::CvCityReligions_GetFollowersOtherReligions>(host, &BeforeCvCityReligions_GetFollowersOtherReligions);CivRegisterAfter<CivHooks::CvCityReligions_GetFollowersOtherReligions>(host, &AfterCvCityReligions_GetFollowersOtherReligions);CivRegisterReplace<CivHooks::CvCityReligions_GetFollowersOtherReligions>(host, &ReplaceCvCityReligions_GetFollowersOtherReligions);

Code

3718/// How many followers are there of religions OTHER than this one?3719int CvCityReligions::GetFollowersOtherReligions(ReligionTypes eReligion)3720{3721	int iOtherFollowers = 0;3722	ReligionInCityList::iterator religionIt;37233724	for(religionIt = m_ReligionStatus.begin(); religionIt != m_ReligionStatus.end(); ++religionIt)3725	{3726		if (religionIt->m_eReligion > RELIGION_PANTHEON && religionIt->m_eReligion != eReligion)3727		{3728			iOtherFollowers += religionIt->m_iFollowers;3729		}3730	}37313732	return iOtherFollowers;3733}

Calls

Called by