Simple Twitch Bot for Frank's Twitch Stream, build with Comfy.JS.
First it was a pretext to learn (or refresh) my JavaScript knowledge, but it became quickly fun to add more and more feature to it. Have a look customize it. make suggestion... this is pure fun. :)
Games:
- !stats: Display current user stats
Sounds:
- !bonjour: play sound "Bonjour Hi"
- !bad: play sound "Bonjour Hi"
- !yeah: play sound "Yeeeeeeaaaah!"
Only Broadcaster:
- !scores: display table of highest scores
- !clean: hide/ clean all previous text in the screen
- !load: Load the file containing the previous session data.
- !save: Save in a local file
streamSession.json
the current session data. - !talk: The bot will repete the message
- lift
- etc.
The Cloudbot now required a server. A tiny one but it's not a static hmtl web page anymore. It's using Node.js. You can run it locally or host it somewhere (ex: Azure).
If you decide to run it locally execute: npm start
from inside the folder src
.
Make a new browser source overlay into your streaming tools (ex: OBS, StreamLabs OBS) and connect it to the root url where the server is running. (ex: http://localhost:3000
.
Create a file secret.js
with the following code in it:
const authToken = "oauth:xxxxxxxxxxxxxxxxxxxxxxxxxxxxx";
Replace the token by the value found on: https://twitchapps.com/tmi/
Finally replace fboucheros by the name of your Twitch Channel on the last line.
ComfyJS.Init( "fboucheros", authToken );
~ Have fun!
Thanks goes to these wonderful people (emoji key):
Frank Boucher 📖 💻 🤔 |
SurlyDev 🤔 |
This project follows the all-contributors specification. Contributions of any kind welcome!