Core/Loot: fix some issues with master loot and don't allow players to see soulbound recipes that they already learned in the loot window.

Port From (https://github.com/TrinityCore/TrinityCore/commit/7b346bcf8d4c4b39685a46ef09f389c8a317b566)
This commit is contained in:
hondacrx
2021-12-17 18:44:59 -05:00
parent 853b589348
commit 1021eadd36
3 changed files with 42 additions and 7 deletions
+1 -2
View File
@@ -521,7 +521,7 @@ namespace Game
List<ItemPosCount> dest = new();
InventoryResult msg = target.CanStoreNewItem(ItemConst.NullBag, ItemConst.NullSlot, dest, item.itemid, item.count);
if (item.follow_loot_rules && !item.AllowedForPlayer(target))
if (!item.AllowedForPlayer(target, true))
msg = InventoryResult.CantEquipEver;
if (msg != InventoryResult.Ok)
{
@@ -532,7 +532,6 @@ namespace Game
else
_player.SendLootError(req.Object, ObjectGuid.Empty, LootError.MasterOther);
target.SendEquipError(msg, null, null, item.itemid);
return;
}