Bazaar developer reference

CvDiplomacyAI::IsPlayerBrokenSpyPromise(PlayerTypes)

Defined in
CvDiplomacyAI.cpp, line 22740
Class
CvDiplomacyAI
Hook name
CivHooks::CvDiplomacyAI_IsPlayerBrokenSpyPromise

Hooks

static bool BeforeCvDiplomacyAI_IsPlayerBrokenSpyPromise(CvDiplomacyAI* self, PlayerTypes ePlayer, bool& result);static void AfterCvDiplomacyAI_IsPlayerBrokenSpyPromise(CvDiplomacyAI* self, PlayerTypes ePlayer, bool& result);static bool ReplaceCvDiplomacyAI_IsPlayerBrokenSpyPromise(bool (*original)(CvDiplomacyAI*, PlayerTypes), CvDiplomacyAI* self, PlayerTypes ePlayer);CivRegisterBefore<CivHooks::CvDiplomacyAI_IsPlayerBrokenSpyPromise>(host, &BeforeCvDiplomacyAI_IsPlayerBrokenSpyPromise);CivRegisterAfter<CivHooks::CvDiplomacyAI_IsPlayerBrokenSpyPromise>(host, &AfterCvDiplomacyAI_IsPlayerBrokenSpyPromise);CivRegisterReplace<CivHooks::CvDiplomacyAI_IsPlayerBrokenSpyPromise>(host, &ReplaceCvDiplomacyAI_IsPlayerBrokenSpyPromise);

Code

22740bool CvDiplomacyAI::IsPlayerBrokenSpyPromise(PlayerTypes ePlayer)22741{22742	CvAssertMsg(ePlayer >= 0, "DIPLOMACY_AI: Invalid Player Index.  Please send slewis your save file and version.");22743	CvAssertMsg(ePlayer < MAX_MAJOR_CIVS, "DIPLOMACY_AI: Invalid Player Index.  Please send slewis your save file and version.");22744	return m_pabPlayerBrokenSpyPromise[ePlayer];22745}

Called by