Bazaar developer reference

CvPolicyEntry::GetImprovementYieldChanges(int, int) const

Defined in
CvPolicyClasses.cpp, line 2072
Class
CvPolicyEntry
Hook name
CivHooks::CvPolicyEntry_GetImprovementYieldChanges

Hooks

static bool BeforeCvPolicyEntry_GetImprovementYieldChanges(const CvPolicyEntry* self, int i, int j, int& result);static void AfterCvPolicyEntry_GetImprovementYieldChanges(const CvPolicyEntry* self, int i, int j, int& result);static int ReplaceCvPolicyEntry_GetImprovementYieldChanges(int (*original)(const CvPolicyEntry*, int, int), const CvPolicyEntry* self, int i, int j);CivRegisterBefore<CivHooks::CvPolicyEntry_GetImprovementYieldChanges>(host, &BeforeCvPolicyEntry_GetImprovementYieldChanges);CivRegisterAfter<CivHooks::CvPolicyEntry_GetImprovementYieldChanges>(host, &AfterCvPolicyEntry_GetImprovementYieldChanges);CivRegisterReplace<CivHooks::CvPolicyEntry_GetImprovementYieldChanges>(host, &ReplaceCvPolicyEntry_GetImprovementYieldChanges);

Code

2071/// Yield modifier for a specific improvement by yield type2072int CvPolicyEntry::GetImprovementYieldChanges(int i, int j) const2073{2074	CvAssertMsg(i < GC.getNumImprovementInfos(), "Index out of bounds");2075	CvAssertMsg(i > -1, "Index out of bounds");2076	CvAssertMsg(j < NUM_YIELD_TYPES, "Index out of bounds");2077	CvAssertMsg(j > -1, "Index out of bounds");2078	return m_ppiImprovementYieldChanges[i][j];2079}

Called by