TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
HealInfo Class Reference

#include <Unit.h>

Public Member Functions

 HealInfo (Unit *healer, Unit *target, uint32 heal, SpellInfo const *spellInfo, SpellSchoolMask schoolMask)
 
void AbsorbHeal (uint32 amount)
 
Unit * GetHealer () const
 
Unit * GetTarget () const
 
uint32 GetHeal () const
 
uint32 GetAbsorb () const
 
SpellInfo const * GetSpellInfo () const
 
SpellSchoolMask GetSchoolMask () const
 

Private Attributes

Unit *const _healer
 
Unit *const _target
 
uint32 _heal
 
uint32 _absorb
 
SpellInfo const *const _spellInfo
 
SpellSchoolMask const _schoolMask
 

Constructor & Destructor Documentation

HealInfo::HealInfo ( Unit *  healer,
Unit *  target,
uint32  heal,
SpellInfo const *  spellInfo,
SpellSchoolMask  schoolMask 
)
inlineexplicit
967  : _healer(healer), _target(target), _heal(heal), _absorb(0), _spellInfo(spellInfo), _schoolMask(schoolMask) { }
uint32 _absorb
Definition: Unit.h:961
SpellInfo const *const _spellInfo
Definition: Unit.h:962
SpellSchoolMask const _schoolMask
Definition: Unit.h:963
uint32 _heal
Definition: Unit.h:960
Unit *const _target
Definition: Unit.h:959
Unit *const _healer
Definition: Unit.h:958

Member Function Documentation

void HealInfo::AbsorbHeal ( uint32  amount)
inline
970  {
971  amount = std::min(amount, GetHeal());
972  _absorb += amount;
973  _heal -= amount;
974  }
uint32 _absorb
Definition: Unit.h:961
uint32 GetHeal() const
Definition: Unit.h:978
T min(const T &x, const T &y)
Definition: g3dmath.h:305
uint32 _heal
Definition: Unit.h:960

+ Here is the call graph for this function:

uint32 HealInfo::GetAbsorb ( ) const
inline
979 { return _absorb; }
uint32 _absorb
Definition: Unit.h:961
uint32 HealInfo::GetHeal ( ) const
inline
978 { return _heal; }
uint32 _heal
Definition: Unit.h:960

+ Here is the caller graph for this function:

Unit* HealInfo::GetHealer ( ) const
inline
976 { return _healer; }
Unit *const _healer
Definition: Unit.h:958
SpellSchoolMask HealInfo::GetSchoolMask ( ) const
inline
981 { return _schoolMask; };
SpellSchoolMask const _schoolMask
Definition: Unit.h:963

+ Here is the caller graph for this function:

SpellInfo const* HealInfo::GetSpellInfo ( ) const
inline
980 { return _spellInfo; };
SpellInfo const *const _spellInfo
Definition: Unit.h:962

+ Here is the caller graph for this function:

Unit* HealInfo::GetTarget ( ) const
inline
977 { return _target; }
Unit *const _target
Definition: Unit.h:959

Member Data Documentation

uint32 HealInfo::_absorb
private
uint32 HealInfo::_heal
private
Unit* const HealInfo::_healer
private
SpellSchoolMask const HealInfo::_schoolMask
private
SpellInfo const* const HealInfo::_spellInfo
private
Unit* const HealInfo::_target
private

The documentation for this class was generated from the following file: