feat: indicate which mods start and cancel raids (#5563)
This commit is contained in:
@@ -648,6 +648,40 @@ void TwitchIrcServer::initialize()
|
||||
});
|
||||
});
|
||||
|
||||
this->connections_.managedConnect(
|
||||
getApp()->getTwitchPubSub()->moderation.raidStarted,
|
||||
[this](const auto &action) {
|
||||
auto chan = this->getChannelOrEmptyByID(action.roomID);
|
||||
|
||||
if (chan->isEmpty())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
auto msg = MessageBuilder(action).release();
|
||||
|
||||
postToThread([chan, msg] {
|
||||
chan->addMessage(msg, MessageContext::Original);
|
||||
});
|
||||
});
|
||||
|
||||
this->connections_.managedConnect(
|
||||
getApp()->getTwitchPubSub()->moderation.raidCanceled,
|
||||
[this](const auto &action) {
|
||||
auto chan = this->getChannelOrEmptyByID(action.roomID);
|
||||
|
||||
if (chan->isEmpty())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
auto msg = MessageBuilder(action).release();
|
||||
|
||||
postToThread([chan, msg] {
|
||||
chan->addMessage(msg, MessageContext::Original);
|
||||
});
|
||||
});
|
||||
|
||||
this->connections_.managedConnect(
|
||||
getApp()->getTwitchPubSub()->pointReward.redeemed, [this](auto &data) {
|
||||
QString channelId = data.value("channel_id").toString();
|
||||
|
||||
Reference in New Issue
Block a user