Skip to content

Commit

Permalink
Core/Players: Fixed naked bug for players, original idea by BThallid
Browse files Browse the repository at this point in the history
  • Loading branch information
Shauren committed Mar 19, 2011
1 parent 31b9951 commit e864b0a
Showing 1 changed file with 14 additions and 11 deletions.
25 changes: 14 additions & 11 deletions src/server/game/Entities/Player/Player.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2260,22 +2260,12 @@ bool Player::TeleportTo(uint32 mapid, float x, float y, float z, float orientati
if (!GetSession()->PlayerLogout())
{
// send transfer packets
WorldPacket data(SMSG_TRANSFER_PENDING, (4+4+4));
WorldPacket data(SMSG_TRANSFER_PENDING, 4 + 4 + 4);
data << uint32(mapid);
if (m_transport)
{
data << m_transport->GetEntry() << GetMapId();
}
GetSession()->SendPacket(&data);

data.Initialize(SMSG_NEW_WORLD, (20));
if (m_transport)
data << (uint32)mapid << m_movementInfo.t_pos.PositionXYZOStream();
else
data << (uint32)mapid << (float)x << (float)y << (float)z << (float)orientation;

GetSession()->SendPacket(&data);
SendSavedInstances();
}

// remove from old map now
Expand All @@ -2301,6 +2291,19 @@ bool Player::TeleportTo(uint32 mapid, float x, float y, float z, float orientati
// if the player is saved before worldportack (at logout for example)
// this will be used instead of the current location in SaveToDB

if (!GetSession()->PlayerLogout())
{
WorldPacket data(SMSG_NEW_WORLD, 4 + 4 + 4 + 4 + 4);
data << uint32(mapid);
if (m_transport)
data << m_movementInfo.t_pos.PositionXYZOStream();
else
data << m_teleport_dest.PositionXYZOStream();

GetSession()->SendPacket(&data);
SendSavedInstances();
}

// move packet sent by client always after far teleport
// code for finish transfer to new map called in WorldSession::HandleMoveWorldportAckOpcode at client packet
SetSemaphoreTeleportFar(true);
Expand Down

7 comments on commit e864b0a

@nucleartux
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what about not displayed nicks?

@maxxx
Copy link

@maxxx maxxx commented on e864b0a Mar 19, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wow, thx

@VincentVanclef
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice fix :P

@tobmaps
Copy link
Contributor

@tobmaps tobmaps commented on e864b0a Apr 1, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

still bugged for me. It happens when you login to the place where already exist any other players - they will be shown as naked for you

@maxxx
Copy link

@maxxx maxxx commented on e864b0a Apr 1, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

confirm that still bugged

@Shauren
Copy link
Member Author

@Shauren Shauren commented on e864b0a Apr 1, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fine, but i dont care. wasnt me who claimed it fixed naked shit :P (blame my testers)

@tobmaps
Copy link
Contributor

@tobmaps tobmaps commented on e864b0a Apr 1, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this naked shit is more terrible when you has installed nudepatch xD

Please sign in to comment.