Bazaar developer reference

CvUnit::doHeal()

Defined in
CvUnit.cpp, line 5923
Class
CvUnit
Hook name
CivHooks::CvUnit_doHeal

Hooks

static bool BeforeCvUnit_doHeal(CvUnit* self);static void AfterCvUnit_doHeal(CvUnit* self);static void ReplaceCvUnit_doHeal(void (*original)(CvUnit*), CvUnit* self);CivRegisterBefore<CivHooks::CvUnit_doHeal>(host, &BeforeCvUnit_doHeal);CivRegisterAfter<CivHooks::CvUnit_doHeal>(host, &AfterCvUnit_doHeal);CivRegisterReplace<CivHooks::CvUnit_doHeal>(host, &ReplaceCvUnit_doHeal);

Code

5923void CvUnit::doHeal()5924{5925	VALIDATE_OBJECT5926	if(!isBarbarian())5927	{5928		changeDamage(-(healRate(plot())));5929	}5930}

Calls

Called by