Bazaar developer reference

CvDiplomacyAI::SetLastTurnMilitaryAggressivePosture(PlayerTypes, AggressivePostureTypes)

Defined in
CvDiplomacyAI.cpp, line 9393
Class
CvDiplomacyAI
Hook name
CivHooks::CvDiplomacyAI_SetLastTurnMilitaryAggressivePosture

Hooks

static bool BeforeCvDiplomacyAI_SetLastTurnMilitaryAggressivePosture(CvDiplomacyAI* self, PlayerTypes ePlayer, AggressivePostureTypes ePosture);static void AfterCvDiplomacyAI_SetLastTurnMilitaryAggressivePosture(CvDiplomacyAI* self, PlayerTypes ePlayer, AggressivePostureTypes ePosture);static void ReplaceCvDiplomacyAI_SetLastTurnMilitaryAggressivePosture(void (*original)(CvDiplomacyAI*, PlayerTypes, AggressivePostureTypes), CvDiplomacyAI* self, PlayerTypes ePlayer, AggressivePostureTypes ePosture);CivRegisterBefore<CivHooks::CvDiplomacyAI_SetLastTurnMilitaryAggressivePosture>(host, &BeforeCvDiplomacyAI_SetLastTurnMilitaryAggressivePosture);CivRegisterAfter<CivHooks::CvDiplomacyAI_SetLastTurnMilitaryAggressivePosture>(host, &AfterCvDiplomacyAI_SetLastTurnMilitaryAggressivePosture);CivRegisterReplace<CivHooks::CvDiplomacyAI_SetLastTurnMilitaryAggressivePosture>(host, &ReplaceCvDiplomacyAI_SetLastTurnMilitaryAggressivePosture);

Code

9392/// Set how aggressively this player has stationed his military Units in relation to us (previous turn)9393void CvDiplomacyAI::SetLastTurnMilitaryAggressivePosture(PlayerTypes ePlayer, AggressivePostureTypes ePosture)9394{9395	CvAssertMsg(ePlayer >= 0, "DIPLOMACY_AI: Invalid Player Index.  Please send Jon this with your last 5 autosaves and what changelist # you're playing.");9396	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.");9397	CvAssertMsg(ePosture >= 0, "DIPLOMACY_AI: Invalid AggressivePostureType.  Please send Jon this with your last 5 autosaves and what changelist # you're playing.");9398	CvAssertMsg(ePosture < NUM_AGGRESSIVE_POSTURE_TYPES, "DIPLOMACY_AI: Invalid AggressivePostureType.  Please send Jon this with your last 5 autosaves and what changelist # you're playing.");93999400	m_paeLastTurnMilitaryAggressivePosture[ePlayer] = ePosture;9401}

Called by