mirror of
https://github.com/liyunfan1223/mod-playerbots.git
synced 2026-02-20 18:10:02 +01:00
drink & food noncombat only
This commit is contained in:
parent
176b6f2bf1
commit
0d851002f2
@ -60,7 +60,7 @@ bool DrinkAction::isUseful()
|
|||||||
|
|
||||||
bool DrinkAction::isPossible()
|
bool DrinkAction::isPossible()
|
||||||
{
|
{
|
||||||
return sPlayerbotAIConfig->freeFood || UseItemAction::isPossible();
|
return !bot->IsInCombat() && (sPlayerbotAIConfig->freeFood || UseItemAction::isPossible());
|
||||||
}
|
}
|
||||||
|
|
||||||
bool EatAction::Execute(Event event)
|
bool EatAction::Execute(Event event)
|
||||||
@ -112,5 +112,5 @@ bool EatAction::isUseful()
|
|||||||
|
|
||||||
bool EatAction::isPossible()
|
bool EatAction::isPossible()
|
||||||
{
|
{
|
||||||
return sPlayerbotAIConfig->freeFood || UseItemAction::isPossible();
|
return !bot->IsInCombat() && (sPlayerbotAIConfig->freeFood || UseItemAction::isPossible());
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user