mirror of
https://github.com/mangosfour/server.git
synced 2025-12-14 16:37:01 +00:00
[8866] Replace [8864] by more correct way fix attack stance problem.
Thanks to TOM_RUS for help in more deep reseach problem source.
This commit is contained in:
parent
06e90a954a
commit
670a2dbb4c
4 changed files with 20 additions and 17 deletions
|
|
@ -181,8 +181,8 @@ void Object::BuildCreateUpdateBlockForPlayer(UpdateData *data, Player *target) c
|
|||
|
||||
if(isType(TYPEMASK_UNIT))
|
||||
{
|
||||
if(((Unit*)this)->GetTargetGUID())
|
||||
flags |= UPDATEFLAG_HAS_TARGET;
|
||||
if(((Unit*)this)->getVictim())
|
||||
flags |= UPDATEFLAG_HAS_ATTACKING_TARGET;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -546,9 +546,12 @@ void Object::BuildMovementUpdate(ByteBuffer * data, uint16 flags, uint32 flags2)
|
|||
}
|
||||
|
||||
// 0x4
|
||||
if(flags & UPDATEFLAG_HAS_TARGET) // packed guid (current target guid)
|
||||
if(flags & UPDATEFLAG_HAS_ATTACKING_TARGET) // packed guid (current target guid)
|
||||
{
|
||||
data->appendPackGUID(((Unit*)this)->GetTargetGUID());
|
||||
if (((Unit*)this)->getVictim())
|
||||
data->append(((Unit*)this)->getVictim()->GetPackGUID());
|
||||
else
|
||||
data->appendPackGUID(0);
|
||||
}
|
||||
|
||||
// 0x2
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue