Add (core): SendTeleportPacket helper (#14389)
* Add (core): SendTeleportPacket helper add helper to SendTeleportPacket * sin hard
This commit is contained in:
parent
0a4051c4b2
commit
2850052f3e
1 changed files with 4 additions and 1 deletions
|
|
@ -20079,7 +20079,10 @@ void Unit::SendTeleportPacket(Position& pos)
|
|||
Position oldPos = { GetPositionX(), GetPositionY(), GetPositionZ(), GetOrientation() };
|
||||
if (GetTypeId() == TYPEID_UNIT)
|
||||
Relocate(&pos);
|
||||
|
||||
if (GetTypeId() == TYPEID_PLAYER)
|
||||
{
|
||||
ToPlayer()->SetCanTeleport(true);
|
||||
}
|
||||
WorldPacket data2(MSG_MOVE_TELEPORT, 38);
|
||||
data2 << GetPackGUID();
|
||||
BuildMovementPacket(&data2);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue