Bazaar developer reference

CvPlotManager::FindLayer(uint)

Defined in
CvPlotManager.cpp, line 184
Class
CvPlotManager
Hook name
CivHooks::CvPlotManager_FindLayer

Hooks

static bool BeforeCvPlotManager_FindLayer(CvPlotManager* self, uint uiLayerID, CvSparseIDInfoGrid*& result);static void AfterCvPlotManager_FindLayer(CvPlotManager* self, uint uiLayerID, CvSparseIDInfoGrid*& result);static CvSparseIDInfoGrid* ReplaceCvPlotManager_FindLayer(CvSparseIDInfoGrid* (*original)(CvPlotManager*, uint), CvPlotManager* self, uint uiLayerID);CivRegisterBefore<CivHooks::CvPlotManager_FindLayer>(host, &BeforeCvPlotManager_FindLayer);CivRegisterAfter<CivHooks::CvPlotManager_FindLayer>(host, &AfterCvPlotManager_FindLayer);CivRegisterReplace<CivHooks::CvPlotManager_FindLayer>(host, &ReplaceCvPlotManager_FindLayer);

Code

184CvSparseIDInfoGrid* CvPlotManager::FindLayer(uint uiLayerID)185{186	for (CvSparseIDInfoGridVector::const_iterator itr = m_aLayers.begin(); itr != m_aLayers.end(); ++itr)187	{188		if ((*itr).m_uiID == uiLayerID)189		{190			return (*itr).m_pkGrid;191		}192	}193194	return NULL;195}

Calls

Called by