mirror of
https://github.com/mod-playerbots/mod-playerbots
synced 2025-11-29 15:58:20 +08:00
Loot when moving
This commit is contained in:
@@ -84,6 +84,11 @@ bool OpenLootAction::DoLoot(LootObject& lootObject)
|
||||
return true;
|
||||
}
|
||||
|
||||
if (bot->isMoving())
|
||||
{
|
||||
bot->StopMoving();
|
||||
}
|
||||
|
||||
if (creature)
|
||||
{
|
||||
SkillType skill = creature->GetCreatureTemplate()->GetRequiredLootSkill();
|
||||
@@ -119,7 +124,7 @@ bool OpenLootAction::DoLoot(LootObject& lootObject)
|
||||
uint32 spellId = GetOpeningSpell(lootObject);
|
||||
if (!spellId)
|
||||
return false;
|
||||
|
||||
|
||||
return botAI->CastSpell(spellId, bot);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user