CvUnit::GetPathLastPlot() const
- Defined in
- CvUnit.cpp, line 23980
- Class
- CvUnit
- Hook name
CivHooks::CvUnit_GetPathLastPlot
Hooks
static bool BeforeCvUnit_GetPathLastPlot(const CvUnit* self, CvPlot*& result);static void AfterCvUnit_GetPathLastPlot(const CvUnit* self, CvPlot*& result);static CvPlot* ReplaceCvUnit_GetPathLastPlot(CvPlot* (*original)(const CvUnit*), const CvUnit* self);CivRegisterBefore<CivHooks::CvUnit_GetPathLastPlot>(host, &BeforeCvUnit_GetPathLastPlot);CivRegisterAfter<CivHooks::CvUnit_GetPathLastPlot>(host, &AfterCvUnit_GetPathLastPlot);CivRegisterReplace<CivHooks::CvUnit_GetPathLastPlot>(host, &ReplaceCvUnit_GetPathLastPlot);
Code
23979/// Where does this path end (returns CvPlot*)?23980CvPlot* CvUnit::GetPathLastPlot() const23981{23982 VALIDATE_OBJECT23983 if(m_kLastPath.size() > 0)23984 {23985 const CvPathNode& kNode = m_kLastPath.front();23986 return GC.getMap().plotCheckInvalid(kNode.m_iX, kNode.m_iY);23987 }2398823989 return NULL;23990}
Calls
BaseVector::frontBaseVector::size- CvGlobals::getMap()
- CvMap::plotCheckInvalid(int, int) const