mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 13:37:05 +00:00
[0027] Prevent sending transport maps in player update object (will be replaced by a better fix later). Should fix the random teleports for this moment...
Fixed aura update (Fixes warrior/paladin client freeze on world login).
This commit is contained in:
parent
eb3f94c24e
commit
3561a43fe1
5 changed files with 26 additions and 5 deletions
|
|
@ -21,6 +21,6 @@
|
|||
|
||||
namespace AIRegistry
|
||||
{
|
||||
void Initialize(void) override;
|
||||
void Initialize(void);
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -891,9 +891,7 @@ void Map::SendInitSelf(Player* player)
|
|||
|
||||
// attach to player data current transport data
|
||||
if (Transport* transport = player->GetTransport())
|
||||
{
|
||||
transport->BuildCreateUpdateBlockForPlayer(&data, player);
|
||||
}
|
||||
|
||||
// build data for self presence in world at own client (one time for map)
|
||||
player->BuildCreateUpdateBlockForPlayer(&data, player);
|
||||
|
|
@ -939,6 +937,11 @@ void Map::SendInitTransports(Player* player)
|
|||
|
||||
WorldPacket packet;
|
||||
transData.BuildPacket(&packet);
|
||||
|
||||
// Prevent sending transport maps in player update object
|
||||
if (packet.ReadUInt16() != player->GetMapId())
|
||||
return;
|
||||
|
||||
player->GetSession()->SendPacket(&packet);
|
||||
}
|
||||
|
||||
|
|
@ -962,6 +965,11 @@ void Map::SendRemoveTransports(Player* player)
|
|||
|
||||
WorldPacket packet;
|
||||
transData.BuildPacket(&packet);
|
||||
|
||||
// Prevent sending transport maps in player update object
|
||||
if (packet.ReadUInt16() != player->GetMapId())
|
||||
return;
|
||||
|
||||
player->GetSession()->SendPacket(&packet);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -9184,7 +9184,7 @@ void SpellAuraHolder::BuildUpdatePacket(WorldPacket& data) const
|
|||
data << uint32(GetId());
|
||||
|
||||
uint8 auraFlags = GetAuraFlags();
|
||||
data << uint8(auraFlags);
|
||||
data << uint16(auraFlags);
|
||||
data << uint8(GetAuraLevel());
|
||||
|
||||
uint32 stackCount = m_procCharges ? m_procCharges * m_stackAmount : m_stackAmount;
|
||||
|
|
|
|||
|
|
@ -556,6 +556,11 @@ void Transport::UpdateForMap(Map const* targetMap)
|
|||
BuildCreateUpdateBlockForPlayer(&transData, itr->getSource());
|
||||
WorldPacket packet;
|
||||
transData.BuildPacket(&packet);
|
||||
|
||||
// Prevent sending transport maps in player update object
|
||||
if (packet.ReadUInt16() != itr->getSource()->GetMapId())
|
||||
return;
|
||||
|
||||
itr->getSource()->SendDirectMessage(&packet);
|
||||
}
|
||||
}
|
||||
|
|
@ -568,8 +573,16 @@ void Transport::UpdateForMap(Map const* targetMap)
|
|||
transData.BuildPacket(&out_packet);
|
||||
|
||||
for (Map::PlayerList::const_iterator itr = pl.begin(); itr != pl.end(); ++itr)
|
||||
{
|
||||
if (this != itr->getSource()->GetTransport())
|
||||
{
|
||||
// Prevent sending transport maps in player update object
|
||||
if (out_packet.ReadUInt16() != itr->getSource()->GetMapId())
|
||||
return;
|
||||
|
||||
itr->getSource()->SendDirectMessage(&out_packet);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
#ifndef __REVISION_NR_H__
|
||||
#define __REVISION_NR_H__
|
||||
#define REVISION_NR "0026"
|
||||
#define REVISION_NR "0027"
|
||||
#endif // __REVISION_NR_H__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue