Skip to content

Commit

Permalink
Core/Misc: Reduce differences between branches
Browse files Browse the repository at this point in the history
  • Loading branch information
Shauren committed Sep 9, 2024
1 parent 29e7cbb commit fcfb576
Showing 1 changed file with 22 additions and 23 deletions.
45 changes: 22 additions & 23 deletions src/server/game/Entities/Object/Object.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -315,15 +315,15 @@ void Object::BuildMovementUpdate(ByteBuffer* data, uint16 flags) const
ASSERT(unit);
unit->BuildMovementPacket(data);

*data << unit->GetSpeed(MOVE_WALK)
<< unit->GetSpeed(MOVE_RUN)
<< unit->GetSpeed(MOVE_RUN_BACK)
<< unit->GetSpeed(MOVE_SWIM)
<< unit->GetSpeed(MOVE_SWIM_BACK)
<< unit->GetSpeed(MOVE_FLIGHT)
<< unit->GetSpeed(MOVE_FLIGHT_BACK)
<< unit->GetSpeed(MOVE_TURN_RATE)
<< unit->GetSpeed(MOVE_PITCH_RATE);
*data << float(unit->GetSpeed(MOVE_WALK));
*data << float(unit->GetSpeed(MOVE_RUN));
*data << float(unit->GetSpeed(MOVE_RUN_BACK));
*data << float(unit->GetSpeed(MOVE_SWIM));
*data << float(unit->GetSpeed(MOVE_SWIM_BACK));
*data << float(unit->GetSpeed(MOVE_FLIGHT));
*data << float(unit->GetSpeed(MOVE_FLIGHT_BACK));
*data << float(unit->GetSpeed(MOVE_TURN_RATE));
*data << float(unit->GetSpeed(MOVE_PITCH_RATE));

// 0x08000000
if (unit->m_movementInfo.GetMovementFlags() & MOVEMENTFLAG_SPLINE_ENABLED)
Expand All @@ -341,21 +341,21 @@ void Object::BuildMovementUpdate(ByteBuffer* data, uint16 flags) const
else
*data << uint8(0);

*data << object->GetPositionX();
*data << object->GetPositionY();
*data << object->GetPositionZ();
*data << float(object->GetPositionX());
*data << float(object->GetPositionY());
*data << float(object->GetPositionZ());

if (transport)
{
*data << object->GetTransOffsetX();
*data << object->GetTransOffsetY();
*data << object->GetTransOffsetZ();
*data << float(object->GetTransOffsetX());
*data << float(object->GetTransOffsetY());
*data << float(object->GetTransOffsetZ());
}
else
{
*data << object->GetPositionX();
*data << object->GetPositionY();
*data << object->GetPositionZ();
*data << float(object->GetPositionX());
*data << float(object->GetPositionY());
*data << float(object->GetPositionZ());
}

*data << object->GetOrientation();
Expand All @@ -371,10 +371,10 @@ void Object::BuildMovementUpdate(ByteBuffer* data, uint16 flags) const
if (flags & UPDATEFLAG_STATIONARY_POSITION)
{
ASSERT(object);
*data << object->GetStationaryX();
*data << object->GetStationaryY();
*data << object->GetStationaryZ();
*data << object->GetStationaryO();
*data << float(object->GetStationaryX());
*data << float(object->GetStationaryY());
*data << float(object->GetStationaryZ());
*data << float(object->GetStationaryO());
}
}
}
Expand Down Expand Up @@ -443,7 +443,6 @@ void Object::BuildMovementUpdate(ByteBuffer* data, uint16 flags) const
// 0x80
if (flags & UPDATEFLAG_VEHICLE)
{
/// @todo Allow players to aquire this updateflag.
ASSERT(unit);
ASSERT(unit->GetVehicleKit());
ASSERT(unit->GetVehicleKit()->GetVehicleInfo());
Expand Down

0 comments on commit fcfb576

Please sign in to comment.