[0067] Set- canfly/forcemoveroot/waterwalk packets, SMSG_PLAY_SPELL_VISUAL

Signed-off-by: Yaki Khadafi <ElSolDolLo@gmail.com>
This commit is contained in:
Yaki Khadafi 2012-08-12 12:53:15 +03:00 committed by Antz
parent 6b1df231a5
commit e7d0275ae2
13 changed files with 237 additions and 104 deletions

View file

@ -296,9 +296,8 @@ void WorldSession::HandleLogoutRequestOpcode(WorldPacket& /*recv_data*/)
if ((GetPlayer()->GetPositionZ() < height + 0.1f) && !(GetPlayer()->IsInWater()))
GetPlayer()->SetStandState(UNIT_STAND_STATE_SIT);
WorldPacket data(SMSG_FORCE_MOVE_ROOT, (8 + 4)); // guess size
data << GetPlayer()->GetPackGUID();
data << (uint32)2;
WorldPacket data;
GetPlayer()->BuildForceMoveRootPacket(&data, true, 2);
SendPacket(&data);
GetPlayer()->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_STUNNED);
}
@ -327,10 +326,8 @@ void WorldSession::HandleLogoutCancelOpcode(WorldPacket& /*recv_data*/)
// not remove flags if can't free move - its not set in Logout request code.
if (GetPlayer()->CanFreeMove())
{
//!we can move again
data.Initialize(SMSG_FORCE_MOVE_UNROOT, 8); // guess size
data << GetPlayer()->GetPackGUID();
data << uint32(0);
//! we can move again
GetPlayer()->BuildForceMoveRootPacket(&data, false, 0);
SendPacket(&data);
//! Stand Up
@ -1034,13 +1031,16 @@ void WorldSession::HandleFeatherFallAck(WorldPacket& recv_data)
DEBUG_LOG("WORLD: CMSG_MOVE_FEATHER_FALL_ACK");
// not used
recv_data.rpos(recv_data.wpos()); // prevent warnings spam
recv_data.rfinish(); // prevent warnings spam
/*
bitsream packet
*/
}
void WorldSession::HandleMoveUnRootAck(WorldPacket& recv_data)
{
// not used
recv_data.rpos(recv_data.wpos()); // prevent warnings spam
recv_data.rfinish(); // prevent warnings spam
/*
bitsream packet
*/
@ -1048,8 +1048,8 @@ void WorldSession::HandleMoveUnRootAck(WorldPacket& recv_data)
void WorldSession::HandleMoveRootAck(WorldPacket& recv_data)
{
// no used
recv_data.rpos(recv_data.wpos()); // prevent warnings spam
// not used
recv_data.rfinish(); // prevent warnings spam
/*
bitsream packet
*/
@ -1490,20 +1490,14 @@ void WorldSession::HandleMoveSetCanFlyAckOpcode(WorldPacket& recv_data)
{
// fly mode on/off
DEBUG_LOG("WORLD: CMSG_MOVE_SET_CAN_FLY_ACK");
// recv_data.hexlike();
ObjectGuid guid;
MovementInfo movementInfo;
recv_data >> guid.ReadAsPacked();
recv_data >> Unused<uint32>(); // unk
recv_data >> movementInfo;
recv_data >> Unused<float>(); // unk2
if (_player->GetMover()->GetObjectGuid() != guid)
if (_player->GetMover()->GetObjectGuid() != movementInfo.GetGuid())
{
DEBUG_LOG("WorldSession::HandleMoveSetCanFlyAckOpcode: player %s, mover %s, received %s, ignored",
_player->GetGuidStr().c_str(), _player->GetMover()->GetGuidStr().c_str(), guid.GetString().c_str());
_player->GetGuidStr().c_str(), _player->GetMover()->GetGuidStr().c_str(), movementInfo.GetGuid().GetString().c_str());
return;
}