By far the most difficult part is getting the OBS scripting console to work. Download the script from GitHub or the OBS resource page and follow the instructions in the README. If you’d like to use the script yourself, it’s quite easy. This is to alert the user if there is a problem during setup, but otherwise hide issues to avoid interruptions during streaming. All messages are rate-limited to the global limit based on the system time, which prevents the user from accidentally receiving a temporary site-wide chat ban for spam.Īny network errors are raised as exceptions if a test button is pressed, but are suppressed if triggered from a hotkey message. With version 1.0, this connection is released after a short period to avoid overhead and let repeated messages through without re-authenticating. Twitch chat is just IRC, so I’m using Python 3’s built-in socket library to handle all of the networking.Īfter a hotkey has been pressed, the script will open a connection to the Twitch server, authenticate, and then send a message. Talking to Twitch ChatĪside from the OBS API functions, the real meat of the script is the code for communicating with Twitch chat itself. Reordering the message list will also reorder how items appear in the OBS hotkey settings. The list of messages is extensible, and will add / remove hotkeys as list items are changed. These work like any other hotkey in the program and are saved with their message in the script settings. ( Note: I wanted the test message button to use the user-selected message in the list, but that property doesn’t appear to be exposed by the API, at least not yet.) Hotkey HookingĮach message added to the message list gets its own custom hotkey that can be modified in the OBS settings window. There are also two buttons on the bottom of the panel for testing authentication and test sending the first message in the list. These settings are stored with the rest of your OBS settings and are reloaded on startup. Messages: the custom list of messages that can be sent.Oauth: the access key required for authentication to Twitch servers.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |