mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 04:37:00 +00:00
[8623] Add function to update orientation of unit (for both server and client)
Signed-off-by: NoFantasy <nofantasy@nf.no>
This commit is contained in:
parent
732bcfbbb6
commit
45a2ee21ef
4 changed files with 15 additions and 15 deletions
|
|
@ -3225,6 +3225,17 @@ void Unit::SetInFront(Unit const* target)
|
|||
SetOrientation(GetAngle(target));
|
||||
}
|
||||
|
||||
void Unit::SetFacingToObject(WorldObject* pObject)
|
||||
{
|
||||
// update orientation at server
|
||||
SetOrientation(GetAngle(pObject));
|
||||
|
||||
// and client
|
||||
WorldPacket data;
|
||||
BuildHeartBeatMsg(&data);
|
||||
SendMessageToSet(&data, false);
|
||||
}
|
||||
|
||||
bool Unit::isInAccessablePlaceFor(Creature const* c) const
|
||||
{
|
||||
if(IsInWater())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue