mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-23 10:26:28 +01:00
Core/Talents: Align server checks to Client limits
Set the max amount of talents to process in CMSG_LEARN_PREVIEW_TALENTS_PET to 30 ( 24 talents rounded up ).
This commit is contained in:
@@ -868,7 +868,10 @@ void WorldSession::HandleLearnPreviewTalentsPet(WorldPacket& recvData)
|
||||
|
||||
uint32 talentId, talentRank;
|
||||
|
||||
for (uint32 i = 0; i < talentsCount; ++i)
|
||||
// Client has max 24 talents, rounded up : 30
|
||||
const int MaxTalentsCount = 30;
|
||||
|
||||
for (uint32 i = 0; i < talentsCount && i < MaxTalentsCount; ++i)
|
||||
{
|
||||
recvData >> talentId >> talentRank;
|
||||
|
||||
@@ -876,4 +879,6 @@ void WorldSession::HandleLearnPreviewTalentsPet(WorldPacket& recvData)
|
||||
}
|
||||
|
||||
_player->SendTalentsInfoData(true);
|
||||
|
||||
recvData.rfinish();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user