Extend SummonWhenGroup to auto-added bots (#2034)

### Summary
Extend AiPlayerbot.SummonWhenGroup to apply when bots are auto-added to
a group (e.g., addclass bots or raidus style auto invites).

### Motivation
Bots added automatically to a group never accept a normal invite, so
they do not trigger the summon-on-accept path. When SummonWhenGroup is
enabled, these bots should also be teleported next to the master to
match expected behavior.

### Implementation details
Hook the summon behavior right after automatic group addition.
This commit is contained in:
Alex Dcnh
2026-02-06 23:20:31 +01:00
committed by GitHub
parent 026df0dabe
commit 76b6df9ea3
2 changed files with 12 additions and 1 deletions

View File

@@ -17,9 +17,9 @@ public:
SummonAction(PlayerbotAI* botAI, std::string const name = "summon") : MovementAction(botAI, name) {}
bool Execute(Event event) override;
bool Teleport(Player* summoner, Player* player, bool preserveAuras);
protected:
bool Teleport(Player* summoner, Player* player, bool preserveAuras);
bool SummonUsingGos(Player* summoner, Player* player, bool preserveAuras);
bool SummonUsingNpcs(Player* summoner, Player* player, bool preserveAuras);
};