mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-13 17:19:07 +00:00
Add (core): SendTeleportPacket helper (#14389)
* Add (core): SendTeleportPacket helper add helper to SendTeleportPacket * sin hard
This commit is contained in:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user