Bazaar developer reference

CvTeam::getTechShareCount(int) const

Defined in
CvTeam.cpp, line 3378
Class
CvTeam
Hook name
CivHooks::CvTeam_getTechShareCount

Hooks

static bool BeforeCvTeam_getTechShareCount(const CvTeam* self, int iIndex, int& result);static void AfterCvTeam_getTechShareCount(const CvTeam* self, int iIndex, int& result);static int ReplaceCvTeam_getTechShareCount(int (*original)(const CvTeam*, int), const CvTeam* self, int iIndex);CivRegisterBefore<CivHooks::CvTeam_getTechShareCount>(host, &BeforeCvTeam_getTechShareCount);CivRegisterAfter<CivHooks::CvTeam_getTechShareCount>(host, &AfterCvTeam_getTechShareCount);CivRegisterReplace<CivHooks::CvTeam_getTechShareCount>(host, &ReplaceCvTeam_getTechShareCount);

Code

3378int CvTeam::getTechShareCount(int iIndex) const3379{3380	CvAssertMsg(iIndex >= 0, "iIndex is expected to be non-negative (invalid Index)");3381	CvAssertMsg(iIndex < MAX_TEAMS, "iIndex is expected to be within maximum bounds (invalid Index)");3382	if(iIndex < 0 || iIndex >= MAX_TEAMS) return 0; // as set in reset()3383	return m_aiTechShareCount[iIndex];3384}

Calls

Called by