CMSG_INSPECT 5.4.7 (18019)

This commit is contained in:
zamalaev 2020-02-19 13:32:16 +00:00 committed by Antz
parent 4443111890
commit 63f8364827
2 changed files with 23 additions and 3 deletions

View file

@ -1161,12 +1161,32 @@ void WorldSession::HandlePlayedTime(WorldPacket& recv_data)
SendPacket(&data);
}
void WorldSession::HandleInspectOpcode(WorldPacket& recv_data)
void WorldSession::HandleInspectOpcode(WorldPacket& recvData)
{
ObjectGuid guid;
recv_data >> guid;
guid[5] = recvData.ReadBit();
guid[0] = recvData.ReadBit();
guid[7] = recvData.ReadBit();
guid[4] = recvData.ReadBit();
guid[6] = recvData.ReadBit();
guid[2] = recvData.ReadBit();
guid[1] = recvData.ReadBit();
guid[3] = recvData.ReadBit();
recvData.ReadByteSeq(guid[5]);
recvData.ReadByteSeq(guid[6]);
recvData.ReadByteSeq(guid[3]);
recvData.ReadByteSeq(guid[4]);
recvData.ReadByteSeq(guid[0]);
recvData.ReadByteSeq(guid[1]);
recvData.ReadByteSeq(guid[7]);
recvData.ReadByteSeq(guid[2]);
DEBUG_LOG("Inspected guid is %s", guid.GetString().c_str());
_player->SetSelectionGuid(guid);
Player* plr = sObjectMgr.GetPlayer(guid);
if (!plr) // wrong player
{