feat(Core/Entities): Add OnPlayerSendListInventory script hook (#21676)

This commit is contained in:
Vincent Vanclef
2025-03-11 15:01:55 +01:00
committed by GitHub
parent d4b1c795c8
commit dd42f7a673
4 changed files with 18 additions and 0 deletions

View File

@@ -1036,6 +1036,8 @@ void WorldSession::SendListInventory(ObjectGuid vendorGuid, uint32 vendorEntry)
{
LOG_DEBUG("network", "WORLD: Sent SMSG_LIST_INVENTORY");
sScriptMgr->OnPlayerSendListInventory(GetPlayer(), vendorGuid, vendorEntry);
Creature* vendor = GetPlayer()->GetNPCIfCanInteractWith(vendorGuid, UNIT_NPC_FLAG_VENDOR);
if (!vendor)
{