Bazaar developer reference

CvDiplomacyAI::GetWarProjection(PlayerTypes) const

Defined in
CvDiplomacyAI.cpp, line 6125
Class
CvDiplomacyAI
Hook name
CivHooks::CvDiplomacyAI_GetWarProjection

Hooks

static bool BeforeCvDiplomacyAI_GetWarProjection(const CvDiplomacyAI* self, PlayerTypes ePlayer, WarProjectionTypes& result);static void AfterCvDiplomacyAI_GetWarProjection(const CvDiplomacyAI* self, PlayerTypes ePlayer, WarProjectionTypes& result);static WarProjectionTypes ReplaceCvDiplomacyAI_GetWarProjection(WarProjectionTypes (*original)(const CvDiplomacyAI*, PlayerTypes), const CvDiplomacyAI* self, PlayerTypes ePlayer);CivRegisterBefore<CivHooks::CvDiplomacyAI_GetWarProjection>(host, &BeforeCvDiplomacyAI_GetWarProjection);CivRegisterAfter<CivHooks::CvDiplomacyAI_GetWarProjection>(host, &AfterCvDiplomacyAI_GetWarProjection);CivRegisterReplace<CivHooks::CvDiplomacyAI_GetWarProjection>(host, &ReplaceCvDiplomacyAI_GetWarProjection);

Code

6124/// What is the Projection of war with this Player6125WarProjectionTypes CvDiplomacyAI::GetWarProjection(PlayerTypes ePlayer) const6126{6127	CvAssertMsg(ePlayer >= 0, "DIPLOMACY_AI: Invalid Player Index.  Please send Jon this with your last 5 autosaves and what changelist # you're playing.");6128	CvAssertMsg(ePlayer < MAX_CIV_PLAYERS, "DIPLOMACY_AI: Invalid Player Index.  Please send Jon this with your last 5 autosaves and what changelist # you're playing.");6129	return (WarProjectionTypes) m_paeWarProjection[ePlayer];6130}

Called by