Bazaar developer reference

CvDllPlayer::NextUnit(int *, bool)

Defined in
CvDllPlayer.cpp, line 303
Class
CvDllPlayer
Hook name
CivHooks::CvDllPlayer_NextUnit

Hooks

static bool BeforeCvDllPlayer_NextUnit(CvDllPlayer* self, int* pIterIdx, bool bRev, ICvUnit1*& result);static void AfterCvDllPlayer_NextUnit(CvDllPlayer* self, int* pIterIdx, bool bRev, ICvUnit1*& result);static ICvUnit1* ReplaceCvDllPlayer_NextUnit(ICvUnit1* (*original)(CvDllPlayer*, int*, bool), CvDllPlayer* self, int* pIterIdx, bool bRev);// CivHooks.h gives this hook point no types, so nothing checks these hooks' parameters.host->RegisterHook(host->pluginIndex, CivHooks::CvDllPlayer_NextUnit::ID, CIV_HOOK_BEFORE, (void*)&BeforeCvDllPlayer_NextUnit);host->RegisterHook(host->pluginIndex, CivHooks::CvDllPlayer_NextUnit::ID, CIV_HOOK_AFTER, (void*)&AfterCvDllPlayer_NextUnit);host->RegisterHook(host->pluginIndex, CivHooks::CvDllPlayer_NextUnit::ID, CIV_HOOK_REPLACE, (void*)&ReplaceCvDllPlayer_NextUnit);

Code

303ICvUnit1* CvDllPlayer::NextUnit(int* pIterIdx, bool bRev)304{305	CvUnit* pkUnit = m_pPlayer->nextUnit(pIterIdx, bRev);306	return (NULL != pkUnit)? new CvDllUnit(pkUnit) : NULL;307}

Calls