Modified bot command 'pull' to ignore engaged targets

This commit is contained in:
Uleat 2019-12-24 14:57:58 -05:00
parent 72f4f10dbb
commit 7678a905c8
2 changed files with 7 additions and 1 deletions

View File

@ -2825,7 +2825,7 @@ void Bot::AI_Process()
return;
}
else if (HasTargetReflection()) {
else if (GetTarget()->GetHateList().size()) {
WipeHateList();
SetTarget(nullptr);

View File

@ -4264,6 +4264,12 @@ void bot_command_pull(Client *c, const Seperator *sep)
return;
}
if (target_mob->IsNPC() && target_mob->GetHateList().size()) {
c->Message(m_fail, "Your current target is already engaged!");
return;
}
Bot* bot_puller = nullptr;
for (auto bot_iter : sbl) {