mirror of
https://github.com/mod-playerbots/mod-playerbots
synced 2025-11-29 15:58:20 +08:00
[Equip score] Skip can take more check
This commit is contained in:
@@ -4408,11 +4408,12 @@ InventoryResult PlayerbotAI::CanEquipItem(uint8 slot, uint16& dest, Item* pItem,
|
||||
|
||||
if (pItem->IsBindedNotWith(bot))
|
||||
return EQUIP_ERR_DONT_OWN_THAT_ITEM;
|
||||
|
||||
// check count of items (skip for auto move for same player from bank)
|
||||
InventoryResult res = bot->CanTakeMoreSimilarItems(pItem);
|
||||
if (res != EQUIP_ERR_OK)
|
||||
return res;
|
||||
|
||||
// Yunfan: skip it
|
||||
// // check count of items (skip for auto move for same player from bank)
|
||||
// InventoryResult res = bot->CanTakeMoreSimilarItems(pItem);
|
||||
// if (res != EQUIP_ERR_OK)
|
||||
// return res;
|
||||
|
||||
ScalingStatDistributionEntry const* ssd = pProto->ScalingStatDistribution ? sScalingStatDistributionStore.LookupEntry(pProto->ScalingStatDistribution) : 0;
|
||||
// check allowed level (extend range to upper values if MaxLevel more or equal max player level, this let GM set high level with 1...max range items)
|
||||
@@ -4427,7 +4428,7 @@ InventoryResult PlayerbotAI::CanEquipItem(uint8 slot, uint16& dest, Item* pItem,
|
||||
if (!bot->CanUseAttackType(bot->GetAttackBySlot(eslot)))
|
||||
return EQUIP_ERR_NOT_WHILE_DISARMED;
|
||||
|
||||
res = bot->CanUseItem(pItem, not_loading);
|
||||
InventoryResult res = bot->CanUseItem(pItem, not_loading);
|
||||
if (res != EQUIP_ERR_OK)
|
||||
return res;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user