mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-26 23:26:23 +00:00
Playerbot fixes and functionnality to talk in channels
This commit is contained in:
@@ -4955,6 +4955,15 @@ void Player::CleanupChannels()
|
||||
}
|
||||
}
|
||||
|
||||
// Playerbot helper if bot talks in a different locale
|
||||
bool Player::IsInChannel(const Channel* c)
|
||||
{
|
||||
return std::any_of(m_channels.begin(), m_channels.end(), [c](const Channel* chan)
|
||||
{
|
||||
return c->GetChannelId() == chan->GetChannelId();
|
||||
});
|
||||
}
|
||||
|
||||
void Player::ClearChannelWatch()
|
||||
{
|
||||
for (JoinedChannelsList::iterator itr = m_channels.begin(); itr != m_channels.end(); ++itr)
|
||||
|
||||
@@ -2043,6 +2043,7 @@ public:
|
||||
|
||||
void JoinedChannel(Channel* c);
|
||||
void LeftChannel(Channel* c);
|
||||
bool IsInChannel(const Channel* c);
|
||||
void CleanupChannels();
|
||||
void ClearChannelWatch();
|
||||
void UpdateLocalChannels(uint32 newZone);
|
||||
|
||||
Reference in New Issue
Block a user