1.4.4 • Published 6 years ago
twitch-sentry v1.4.4
TwitchSentry
Twitch bot, running Node.js using RxJS, TypeScript, lowdb and tmi.
- Betting system.
- Storing user information in local JSON database.
- Event Based.
- Configure custom commands and responses.
- Configure custom periodic messages.
📖 Wiki
For detailed information on installation and all the available commands go to Wiki
Installation
npm
$ npm install twitch-sentryOr build it yourself:
$ git clone https://github.com/spnq/twitch-sentry.git
$ cd twitch-sentry
$ npm installConfigure the bot and run
$ npm run buildConfiguring the bot
Go to src/config.ts and change it accordingly:
{
auth: "",
botName: "",
channels: [""],
defaultChannel: ""
}- auth - Oauth you got from twitchapps.com/tmi.
- botName - Bot's nickname from twitch.com.
- channels - Channels bot connects to.
- defaultChannel - Value with a channel, bot interacts with
Build the bot with
$ npm run buildThen start Sentry with
npm startYou should see a message from your bot in the chat.
Add custom commands and responses
Go to src/custom_messages.ts and add you own messages:
{
"!github":"https://github.com/spnq/twitch-sentry",
"!email":"spnq@riseup.net"
}Add custom periodic messages
Go to src/periodics.ts and add your messages and intervals for them to appear with in the array, for example:
[
{
message: "Give a Star @https://github.com/spnq/twitch-sentry",
interval: {
hours : 0,
minutes: 0,
seconds: 10
}
}
]Betting
- Once you want to start a betting cycle type
!startBetin the chat. - Then bet with
!betcommand. Guess value goes first, bet value goes second. - When all the bets are placed, stop betting process with
!stopBetcommand. - When you got your result type
!resultand it's value to determine the winners.
License
Licensed under MIT License. View the file for the full text.