diff --git a/src/game/Creature.cpp b/src/game/Creature.cpp index af06d050d..c70367fea 100644 --- a/src/game/Creature.cpp +++ b/src/game/Creature.cpp @@ -2170,7 +2170,8 @@ bool Creature::HasSpellCooldown(uint32 spell_id) const uint8 Creature::getRace() const { - return Unit::getRace() ? Unit::getRace() : GetCreatureModelRace(GetNativeDisplayId()); + uint8 race = Unit::getRace(); + return race ? race : GetCreatureModelRace(GetNativeDisplayId()); } bool Creature::IsInEvadeMode() const diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 2e0a73c12..d97b32de6 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -8625,7 +8625,7 @@ void Unit::TauntFadeOut(Unit *taunter) //====================================================================== -bool Unit::IsSecondChoiceTarget(Unit* pTarget, bool checkThreatArea) +bool Unit::IsSecondChoiceTarget(Unit* pTarget, bool checkThreatArea) const { MANGOS_ASSERT(pTarget && GetTypeId() == TYPEID_UNIT); diff --git a/src/game/Unit.h b/src/game/Unit.h index 9c13531dd..313f5cb25 100644 --- a/src/game/Unit.h +++ b/src/game/Unit.h @@ -1387,7 +1387,7 @@ class MANGOS_DLL_SPEC Unit : public WorldObject bool IsIgnoreUnitState(SpellEntry const *spell, IgnoreUnitState ignoreState); bool isTargetableForAttack(bool inversAlive = false) const; - bool isPassiveToHostile() { return HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PASSIVE); } + bool isPassiveToHostile() const { return HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PASSIVE); } virtual bool IsInWater() const; virtual bool IsUnderWater() const; @@ -1673,7 +1673,7 @@ class MANGOS_DLL_SPEC Unit : public WorldObject void AddThreat(Unit* pVictim, float threat = 0.0f, bool crit = false, SpellSchoolMask schoolMask = SPELL_SCHOOL_MASK_NONE, SpellEntry const *threatSpell = NULL); float ApplyTotalThreatModifier(float threat, SpellSchoolMask schoolMask = SPELL_SCHOOL_MASK_NORMAL); void DeleteThreatList(); - bool IsSecondChoiceTarget(Unit* pTarget, bool checkThreatArea); + bool IsSecondChoiceTarget(Unit* pTarget, bool checkThreatArea) const; bool SelectHostileTarget(); void TauntApply(Unit* pVictim); void TauntFadeOut(Unit *taunter); @@ -1845,8 +1845,6 @@ class MANGOS_DLL_SPEC Unit : public WorldObject float GetSpeedRate( UnitMoveType mtype ) const { return m_speed_rate[mtype]; } void SetSpeedRate(UnitMoveType mtype, float rate, bool forced = false); - bool isHover() const { return HasAuraType(SPELL_AURA_HOVER); } - void KnockBackFrom(Unit* target, float horizontalSpeed, float verticalSpeed); void _RemoveAllAuraMods(); @@ -1908,7 +1906,7 @@ class MANGOS_DLL_SPEC Unit : public WorldObject void _SetAINotifyScheduled(bool on) { m_AINotifyScheduled = on;} // only for call from RelocationNotifyEvent code void OnRelocated(); - bool IsLinkingEventTrigger() { return m_isCreatureLinkingTrigger; } + bool IsLinkingEventTrigger() const { return m_isCreatureLinkingTrigger; } protected: explicit Unit (); diff --git a/src/shared/revision_nr.h b/src/shared/revision_nr.h index ea5d1e359..df3c9c4ad 100644 --- a/src/shared/revision_nr.h +++ b/src/shared/revision_nr.h @@ -1,4 +1,4 @@ #ifndef __REVISION_NR_H__ #define __REVISION_NR_H__ - #define REVISION_NR "12018" + #define REVISION_NR "12019" #endif // __REVISION_NR_H__