Bazaar developer reference

CvArmyAI::Reset(int, PlayerTypes, int, bool)

Defined in
CvArmyAI.cpp, line 56
Class
CvArmyAI
Hook name
CivHooks::CvArmyAI_Reset

Hooks

static bool BeforeCvArmyAI_Reset(CvArmyAI* self, int iID, PlayerTypes eOwner, int iOperationID, bool arg3);static void AfterCvArmyAI_Reset(CvArmyAI* self, int iID, PlayerTypes eOwner, int iOperationID, bool arg3);static void ReplaceCvArmyAI_Reset(void (*original)(CvArmyAI*, int, PlayerTypes, int, bool), CvArmyAI* self, int iID, PlayerTypes eOwner, int iOperationID, bool arg3);CivRegisterBefore<CivHooks::CvArmyAI_Reset>(host, &BeforeCvArmyAI_Reset);CivRegisterAfter<CivHooks::CvArmyAI_Reset>(host, &AfterCvArmyAI_Reset);CivRegisterReplace<CivHooks::CvArmyAI_Reset>(host, &ReplaceCvArmyAI_Reset);

Code

55/// Initializes data members that are serialize56void CvArmyAI::Reset(int iID, PlayerTypes eOwner, int iOperationID, bool /* bConstructorCall */)57{58	//--------------------------------59	// Uninit class60	Uninit();6162	m_iID = iID;63	m_eOwner = eOwner;64	m_iOperationID = iOperationID;65	m_iCurrentX = -1;66	m_iCurrentY = -1;67	m_iGoalX = -1;68	m_iGoalY = -1;69	m_eDomainType = DOMAIN_LAND;70	m_iFormationIndex = NO_MUFORMATION;71	m_eAIState = NO_ARMYAISTATE;7273	m_FormationEntries.clear();74}

Calls

Called by