CvDiplomacyAI::SetOtherPlayerNumMinorsConquered(PlayerTypes, int)
- Defined in
- CvDiplomacyAI.cpp, line 10198
- Class
- CvDiplomacyAI
- Hook name
CivHooks::CvDiplomacyAI_SetOtherPlayerNumMinorsConquered
Hooks
static bool BeforeCvDiplomacyAI_SetOtherPlayerNumMinorsConquered(CvDiplomacyAI* self, PlayerTypes ePlayer, int iValue);static void AfterCvDiplomacyAI_SetOtherPlayerNumMinorsConquered(CvDiplomacyAI* self, PlayerTypes ePlayer, int iValue);static void ReplaceCvDiplomacyAI_SetOtherPlayerNumMinorsConquered(void (*original)(CvDiplomacyAI*, PlayerTypes, int), CvDiplomacyAI* self, PlayerTypes ePlayer, int iValue);CivRegisterBefore<CivHooks::CvDiplomacyAI_SetOtherPlayerNumMinorsConquered>(host, &BeforeCvDiplomacyAI_SetOtherPlayerNumMinorsConquered);CivRegisterAfter<CivHooks::CvDiplomacyAI_SetOtherPlayerNumMinorsConquered>(host, &AfterCvDiplomacyAI_SetOtherPlayerNumMinorsConquered);CivRegisterReplace<CivHooks::CvDiplomacyAI_SetOtherPlayerNumMinorsConquered>(host, &ReplaceCvDiplomacyAI_SetOtherPlayerNumMinorsConquered);
Code
10197/// Sets how many Minors have we seen this Player conquer10198void CvDiplomacyAI::SetOtherPlayerNumMinorsConquered(PlayerTypes ePlayer, int iValue)10199{10200 CvAssertMsg(ePlayer >= 0, "DIPLOMACY_AI: Invalid Player Index. Please send Jon this with your last 5 autosaves and what changelist # you're playing.");10201 CvAssertMsg(ePlayer < MAX_MAJOR_CIVS, "DIPLOMACY_AI: Invalid Player Index. Please send Jon this with your last 5 autosaves and what changelist # you're playing.");10202 CvAssertMsg(iValue >= 0, "DIPLOMACY_AI: Setting number of minors conquered to a negative value. Please send Jon this with your last 5 autosaves and what changelist # you're playing.");10203 m_paiOtherPlayerNumMinorsConquered[ePlayer] = iValue;10204}