Bazaar developer reference

CvDiplomacyAI::IsGoingForWorldConquest()

Defined in
CvDiplomacyAI.cpp, line 24361
Class
CvDiplomacyAI
Hook name
CivHooks::CvDiplomacyAI_IsGoingForWorldConquest

Hooks

static bool BeforeCvDiplomacyAI_IsGoingForWorldConquest(CvDiplomacyAI* self, bool& result);static void AfterCvDiplomacyAI_IsGoingForWorldConquest(CvDiplomacyAI* self, bool& result);static bool ReplaceCvDiplomacyAI_IsGoingForWorldConquest(bool (*original)(CvDiplomacyAI*), CvDiplomacyAI* self);CivRegisterBefore<CivHooks::CvDiplomacyAI_IsGoingForWorldConquest>(host, &BeforeCvDiplomacyAI_IsGoingForWorldConquest);CivRegisterAfter<CivHooks::CvDiplomacyAI_IsGoingForWorldConquest>(host, &AfterCvDiplomacyAI_IsGoingForWorldConquest);CivRegisterReplace<CivHooks::CvDiplomacyAI_IsGoingForWorldConquest>(host, &ReplaceCvDiplomacyAI_IsGoingForWorldConquest);

Code

24360/// Does this player want to conquer the world?24361bool CvDiplomacyAI::IsGoingForWorldConquest()24362{24363	AIGrandStrategyTypes eGrandStrategy = (AIGrandStrategyTypes) GC.getInfoTypeForString("AIGRANDSTRATEGY_CONQUEST");2436424365	if(eGrandStrategy != NO_AIGRANDSTRATEGY)24366	{24367		if(GetPlayer()->GetGrandStrategyAI()->GetActiveGrandStrategy() == eGrandStrategy)24368		{24369			return true;24370		}24371	}2437224373	return false;24374}

Calls

Called by