Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor chat connections and allow dynamically joining chats #392

Merged
merged 22 commits into from
Feb 22, 2024

Conversation

Felk
Copy link
Member

@Felk Felk commented Feb 6, 2024

  • entire co-stream-inputs feature can be enabled using CoStreamInputsEnabled (inside twitch connection config) (default false)
  • !join and !leave are implemented
  • !join only works when the user is live (configurable via CoStreamInputsOnlyLive, default true)
  • if CoStreamInputsOnlyLive is set to true, automatically leaves channgels that are no longer live
  • channels joined this way are only monitored for mode-specific tasks, for runmode this means only inputs. No modbot or commands.
  • only a message after !join and a message after !leave are posted in the target chats, otherwise the bot is quiet there
  • inputs from TPP-banned users are ignored from all channels
  • anarchy inputs got a new "channel" field that is null for tpp and populated with a channel name for foreign inputs
  • !join and !leave are persisted across core restarts
  • It ignores co-stream inputs while the main channel is in emote-only mode
  • channel icon URLs for the channels provided
  • (?) !leaveall command
    • could just set CoStreamInputsEnabled to false after the event and it stops joining other channels
  • if TPP’s channel is in slow mode, it should not accept inputs at higher speed from anywhere else
  • !left and !right still work

@Felk Felk marked this pull request as draft February 6, 2024 20:59
@Felk Felk changed the title Draft: refactor chat connections and allow dynamically joining chats refactor chat connections and allow dynamically joining chats Feb 6, 2024
Comment on lines +102 to +104
// TODO https://github.com/TwitchLib/TwitchLib.Api/pull/386
await twitchApi.Helix.Chat.SendChatMessage(reply.ChannelId, _senderUserId, reply.Message /*, replyParentMessageId: reply.ReplyToId*/);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need to fix this bit if/when TwitchLib/TwitchLib.Api#386 is merged and available on nuget via a prerelease

Copy link
Member Author

@Felk Felk Feb 12, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've disabled twitch-native replies for now in 620b440 until we can use the API for them again. So we need to also revert 620b440 once this is fixed

@Felk Felk force-pushed the chat_connection_updates branch from f288002 to afa5556 Compare February 12, 2024 16:14
@Felk Felk marked this pull request as ready for review February 12, 2024 19:59
@m4-used-rollout m4-used-rollout merged commit f946a77 into master Feb 22, 2024
8 checks passed
@m4-used-rollout m4-used-rollout deleted the chat_connection_updates branch February 22, 2024 20:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants