Bazaar developer reference

CvGame::changeTotalPopulation(int)

Defined in
CvGame.cpp, line 4862
Class
CvGame
Hook name
CivHooks::CvGame_changeTotalPopulation

Hooks

static bool BeforeCvGame_changeTotalPopulation(CvGame* self, int iChange);static void AfterCvGame_changeTotalPopulation(CvGame* self, int iChange);static void ReplaceCvGame_changeTotalPopulation(void (*original)(CvGame*, int), CvGame* self, int iChange);CivRegisterBefore<CivHooks::CvGame_changeTotalPopulation>(host, &BeforeCvGame_changeTotalPopulation);CivRegisterAfter<CivHooks::CvGame_changeTotalPopulation>(host, &AfterCvGame_changeTotalPopulation);CivRegisterReplace<CivHooks::CvGame_changeTotalPopulation>(host, &ReplaceCvGame_changeTotalPopulation);

Code

4862void CvGame::changeTotalPopulation(int iChange)4863{4864	m_iTotalPopulation = (m_iTotalPopulation + iChange);4865	CvAssert(getTotalPopulation() >= 0);4866}

Called by