[9210] Fix visual bug making npc run-in-same-position in client.

Not send MOVEMENTFLAG_FORWARD (even if expected). As result npc will not run in same position when npc becomes visible at client side.

Signed-off-by: NoFantasy <nofantasy@nf.no>
This commit is contained in:
NoFantasy 2010-01-18 20:38:02 +01:00
parent e1d0c1cdba
commit de4d8c3a04
2 changed files with 5 additions and 4 deletions

View file

@ -263,14 +263,15 @@ void Object::BuildMovementUpdate(ByteBuffer * data, uint16 flags, uint32 flags2)
{
flags2 = MOVEMENTFLAG_NONE;
if (!((Creature*)this)->IsStopped())
flags2 |= MOVEMENTFLAG_FORWARD; // not set if not really moving
// disabled, makes them run-in-same-place before movement generator updated once.
/*if (((Creature*)this)->hasUnitState(UNIT_STAT_MOVING))
flags2 |= MOVEMENTFLAG_FORWARD;*/ // not set if not really moving
if (((Creature*)this)->canFly())
{
flags2 |= MOVEMENTFLAG_LEVITATING; // (ok) most seem to have this
if (((Creature*)this)->IsStopped())
if (!((Creature*)this)->hasUnitState(UNIT_STAT_MOVING))
flags2 |= MOVEMENTFLAG_FLY_UNK1; // (ok) possibly some "hover" mode
else
{