mirror of
https://github.com/liyunfan1223/mod-playerbots.git
synced 2026-02-21 02:20:00 +01:00
Increase ammo count for hunter
This commit is contained in:
parent
8854f7e9b2
commit
e09b871d94
@ -2815,11 +2815,11 @@ void PlayerbotFactory::InitAmmo()
|
|||||||
|
|
||||||
uint32 entry = sRandomItemMgr->GetAmmo(level, subClass);
|
uint32 entry = sRandomItemMgr->GetAmmo(level, subClass);
|
||||||
uint32 count = bot->GetItemCount(entry);
|
uint32 count = bot->GetItemCount(entry);
|
||||||
uint32 maxCount = 6000;
|
uint32 maxCount = bot->getClass() == CLASS_HUNTER ? 6000 : 1000;
|
||||||
|
|
||||||
if (count < maxCount / 2)
|
if (count < maxCount)
|
||||||
{
|
{
|
||||||
if (Item* newItem = StoreNewItemInInventorySlot(bot, entry, maxCount / 2))
|
if (Item* newItem = StoreNewItemInInventorySlot(bot, entry, maxCount - count))
|
||||||
{
|
{
|
||||||
newItem->AddToUpdateQueueOf(bot);
|
newItem->AddToUpdateQueueOf(bot);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user