CvCity::setRallyPlot(CvPlot *)
- Defined in
- CvCity.cpp, line 7739
- Class
- CvCity
- Hook name
CivHooks::CvCity_setRallyPlot
Hooks
static bool BeforeCvCity_setRallyPlot(CvCity* self, CvPlot* pPlot);static void AfterCvCity_setRallyPlot(CvCity* self, CvPlot* pPlot);static void ReplaceCvCity_setRallyPlot(void (*original)(CvCity*, CvPlot*), CvCity* self, CvPlot* pPlot);CivRegisterBefore<CivHooks::CvCity_setRallyPlot>(host, &BeforeCvCity_setRallyPlot);CivRegisterAfter<CivHooks::CvCity_setRallyPlot>(host, &AfterCvCity_setRallyPlot);CivRegisterReplace<CivHooks::CvCity_setRallyPlot>(host, &ReplaceCvCity_setRallyPlot);
Code
7739void CvCity::setRallyPlot(CvPlot* pPlot)7740{7741 VALIDATE_OBJECT7742 if(getRallyPlot() != pPlot)7743 {7744 if(pPlot != NULL)7745 {7746 m_iRallyX = pPlot->getX();7747 m_iRallyY = pPlot->getY();7748 }7749 else7750 {7751 m_iRallyX = INVALID_PLOT_COORD;7752 m_iRallyY = INVALID_PLOT_COORD;7753 }77547755 if(isCitySelected())7756 {7757 DLLUI->setDirty(ColoredPlots_DIRTY_BIT, true);7758 }7759 }7760}
Calls
- CvCity::getRallyPlot() const
- CvCity::isCitySelected()
- CvGlobals::GetEngineUserInterface()
- CvPlot::getX() const
- CvPlot::getY() const
FAutoVariable::operator=ICvUserInterface1::setDirty