From a7fba672259237a0e8cb7edac6e1c050db4e25c0 Mon Sep 17 00:00:00 2001 From: SilverIce Date: Sun, 10 Jul 2011 22:17:08 +0300 Subject: [PATCH] [11732] Interrupt movement state at dying TODO: proper solution would be update creatures while in corpse state. This also would solve problems with death persistent auras that not get updated for died creatures --- src/game/Creature.cpp | 2 +- src/game/Unit.cpp | 1 + src/shared/revision_nr.h | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/game/Creature.cpp b/src/game/Creature.cpp index 7e284db11..e9205a5e2 100644 --- a/src/game/Creature.cpp +++ b/src/game/Creature.cpp @@ -1542,7 +1542,7 @@ bool Creature::FallGround() // hacky solution: by some reason died creatures not updated, that's why need finalize movement state GetMap()->CreatureRelocation(this, GetPositionX(), GetPositionY(), tz, GetOrientation()); - movespline->_Finalize(); + DisableSpline(); return true; } diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index ea6797ba1..5b27d0825 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -8362,6 +8362,7 @@ void Unit::SetDeathState(DeathState s) UnsummonAllTotems(); StopMoving(); + DisableSpline(); ModifyAuraState(AURA_STATE_HEALTHLESS_20_PERCENT, false); ModifyAuraState(AURA_STATE_HEALTHLESS_35_PERCENT, false); diff --git a/src/shared/revision_nr.h b/src/shared/revision_nr.h index 87d391987..5b65e5030 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 "11731" + #define REVISION_NR "11732" #endif // __REVISION_NR_H__