Core/PacketIO: Fixed a few more opcodes

This commit is contained in:
Subv committed 2012-08-09 19:18:31 -05:00
1 parent 99d4a1093b
commit ab771aef1f
4 files changed
+93 -68

No files matched your search

+50 -3
View File
@@ -25720,9 +25720,56 @@ bool Player::SetHover(bool enable)
void Player::SendMovementSetCanFly(bool apply)
{
WorldPacket data(apply ? SMSG_MOVE_SET_CAN_FLY : SMSG_MOVE_UNSET_CAN_FLY, 12);
data.append(GetPackGUID());
data << uint32(0); //! movement counter
ObjectGuid guid = GetGUID();
WorldPacket data;
if (apply)
{
data.Initialize(SMSG_MOVE_SET_CAN_FLY, 1 + 8 + 4);
data.WriteBit(guid[1]);
data.WriteBit(guid[6]);
data.WriteBit(guid[5]);
data.WriteBit(guid[0]);
data.WriteBit(guid[7]);
data.WriteBit(guid[4]);
data.WriteBit(guid[2]);
data.WriteBit(guid[3]);
data.WriteByteSeq(guid[6]);
data.WriteByteSeq(guid[3]);
data << uint32(0); //! movement counter
data.WriteByteSeq(guid[2]);
data.WriteByteSeq(guid[1]);
data.WriteByteSeq(guid[4]);
data.WriteByteSeq(guid[7]);
data.WriteByteSeq(guid[0]);
data.WriteByteSeq(guid[5]);
}
else
{
data.Initialize(SMSG_MOVE_UNSET_CAN_FLY, 1 + 8 + 4);
data.WriteBit(guid[1]);
data.WriteBit(guid[4]);
data.WriteBit(guid[2]);
data.WriteBit(guid[5]);
data.WriteBit(guid[0]);
data.WriteBit(guid[3]);
data.WriteBit(guid[6]);
data.WriteBit(guid[7]);
data.WriteByteSeq(guid[4]);
data.WriteByteSeq(guid[6]);
data << uint32(0); //! movement counter
data.WriteByteSeq(guid[1]);
data.WriteByteSeq(guid[0]);
data.WriteByteSeq(guid[2]);
data.WriteByteSeq(guid[3]);
data.WriteByteSeq(guid[5]);
data.WriteByteSeq(guid[7]);
}
SendDirectMessage(&data);
}