CvGameLeagues::GetActiveLeague()
- Defined in
- CvVotingClasses.cpp, line 7116
- Class
- CvGameLeagues
- Hook name
CivHooks::CvGameLeagues_GetActiveLeague
Hooks
static bool BeforeCvGameLeagues_GetActiveLeague(CvGameLeagues* self, CvLeague*& result);static void AfterCvGameLeagues_GetActiveLeague(CvGameLeagues* self, CvLeague*& result);static CvLeague* ReplaceCvGameLeagues_GetActiveLeague(CvLeague* (*original)(CvGameLeagues*), CvGameLeagues* self);CivRegisterBefore<CivHooks::CvGameLeagues_GetActiveLeague>(host, &BeforeCvGameLeagues_GetActiveLeague);CivRegisterAfter<CivHooks::CvGameLeagues_GetActiveLeague>(host, &AfterCvGameLeagues_GetActiveLeague);CivRegisterReplace<CivHooks::CvGameLeagues_GetActiveLeague>(host, &ReplaceCvGameLeagues_GetActiveLeague);
Code
7116CvLeague* CvGameLeagues::GetActiveLeague()7117{7118 CvLeague* pLeague = NULL;7119 for (LeagueList::iterator it = m_vActiveLeagues.begin(); it != m_vActiveLeagues.end(); it++)7120 {7121 pLeague = it;7122 }7123 CvAssertMsg(GetNumActiveLeagues() == 0 || GetNumActiveLeagues() == 1, "Unexpected number of active leagues. Please send Anton your save file and version.");7124 return pLeague;7125}
Calls
BaseVector::beginBaseVector::end
Called by
- CvCity::setupWonderGraphics()
- CvDealAI::GetVoteCommitmentValue(bool, PlayerTypes, int, int, int, bool, bool)
- CvDeal::IsPossibleToTradeItem(PlayerTypes, PlayerTypes, TradeableItems, int, int, int, bool, bool, bool)
- CvDiplomacyAI::DoSendStatementToPlayer(PlayerTypes, DiploStatementTypes, int, CvDeal *)
- CvGame::IsResolutionPassed(ResolutionTypes, int) const
- CvGame::IsUnitedNationsActive()
- CvGrandStrategyAI::GetUnitedNationsPriority()
- CvGameLeagues::DoTurn()
- CvLeagueAI::CanCommitVote(PlayerTypes, CvString *)
- CvLeagueAI::EvaluateVoteForTrade(int, int, int, bool)
- CvLeagueAI::FindBestVoteChoices(CvEnactProposal *, VoteConsiderationList &)
- CvLeagueAI::FindBestVoteChoices(CvRepealProposal *, VoteConsiderationList &)
- CvLeagueAI::GetDesiredVoteCommitments(PlayerTypes)
- CvLeagueAI::GetExtraVotesPerCityStateAlly()
- CvLeagueAI::ScoreVoteChoice(CvEnactProposal *, int)
- CvLeagueAI::ScoreVoteChoice(CvRepealProposal *, int)
- CvLeagueAI::ScoreVoteChoicePlayer(CvProposal *, int, bool)
- CvVoterDecision::GetDecision()
- CvLuaGame::lGetActiveLeague(lua_State *)