Bazaar developer reference

CvGame::GetTurnsBetweenMinorCivElections()

Defined in
CvGame.cpp, line 10377
Class
CvGame
Hook name
CivHooks::CvGame_GetTurnsBetweenMinorCivElections

Hooks

static bool BeforeCvGame_GetTurnsBetweenMinorCivElections(CvGame* self, int& result);static void AfterCvGame_GetTurnsBetweenMinorCivElections(CvGame* self, int& result);static int ReplaceCvGame_GetTurnsBetweenMinorCivElections(int (*original)(CvGame*), CvGame* self);CivRegisterBefore<CivHooks::CvGame_GetTurnsBetweenMinorCivElections>(host, &BeforeCvGame_GetTurnsBetweenMinorCivElections);CivRegisterAfter<CivHooks::CvGame_GetTurnsBetweenMinorCivElections>(host, &AfterCvGame_GetTurnsBetweenMinorCivElections);CivRegisterReplace<CivHooks::CvGame_GetTurnsBetweenMinorCivElections>(host, &ReplaceCvGame_GetTurnsBetweenMinorCivElections);

Code

10377int CvGame::GetTurnsBetweenMinorCivElections()10378{10379	int iTurnsBetweenCityStateElections = GC.getESPIONAGE_TURNS_BETWEEN_CITY_STATE_ELECTIONS();10380	iTurnsBetweenCityStateElections *= GC.getGame().getGameSpeedInfo().getMinorCivElectionFreqMod();10381	iTurnsBetweenCityStateElections /= 100;10382	return iTurnsBetweenCityStateElections;10383}

Calls

Called by