Skip to content

Commit

Permalink
playerbots: Fix chat commands for group to not be sent into all the r…
Browse files Browse the repository at this point in the history
…aid members
  • Loading branch information
davidonete committed Apr 27, 2024
1 parent e3796fc commit 8a569a9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/game/Chat/ChatHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ void WorldSession::HandleMessagechatOpcode(WorldPacket& recv_data)
for (GroupReference* itr = group->GetFirstMember(); itr != NULL; itr = itr->next())
{
Player* player = itr->getSource();
if (player && player->GetPlayerbotAI())
if (player && player->GetPlayerbotAI() && player->IsInGroup(GetPlayer(), true))
{
player->GetPlayerbotAI()->HandleCommand(type, msg, *GetPlayer(), lang);
GetPlayer()->m_speakTime = 0;
Expand Down

0 comments on commit 8a569a9

Please sign in to comment.