Giter Site home page Giter Site logo

d0p3t / d0p3tbot Goto Github PK

View Code? Open in Web Editor NEW
6.0 3.0 0.0 6.21 MB

OUTDATED! A Lightweight Chat Bot For Twitch and Discord using NodeJS =PRE-ALPHA=

License: MIT License

JavaScript 85.76% Shell 0.01% HTML 1.92% CSS 12.32%
twitch discord nodejs bot tmijs discordjs chatbot lightweight

d0p3tbot's Introduction

d0p3tbot (v0.0.2-alpha)

A lightweight chat bot for Twitch and Discord using NodeJS.

Version Build Status Discord license

A lot of the current features are specifically designed for the demo environment and are currently in development!

This bot works on Windows, OSX and Linux as long as you have NodeJS, NPM and MongoDB installed.

Demo

A working demo can be found running on Twitch and on Discord. Keep in mind that the demo does not run the latest version and access to the demo frontend is not allowed (yet).

  • Type !commands to get a list of the available chat commands on Twitch

Features

  • Twitch: Basic commands (i.e. !uptime, !subcount, !commands, !so)
  • Twitch: Custom commands
  • Twitch: Automatic chat alerts on subscription/resubscription
  • Twitch: Notices every X messages
  • Twitch: Whitelist URLs and Blacklist words
  • Twitch: Permit a user to post links for 60 seconds
  • Discord: Live announcements. example
  • Persistent Database using mongoDB data storage
  • Frontend dashboard and control panel

Setup

You must have nodejs and npm installed as well as a running instance of mongodb.

Clone this repo and run npm install to install all the dependencies.

Next, copy and rename config_sample.js to config.js and edit it according to instructions found inside.


Usage

After cloning the repository, installing all dependencies and creating a config file you can run the application with gulp serve. The bot will join the configured Twitch/Discord channel and listen for events/messages.

Available basic commands include: !uptime, !followage, !subcount, !so, !permit

Frontend: Go to http://localhost:3000 and login with username equal to your Twitch name and password as defaultpassword. You can then add commands, notices, blacklist words, whitelist URLs etc.


Upcoming Features

  • Frontend In Progress
  • Multi-user support
  • Security Improvements
  • AI chat (conversational bot)
  • Create own API for !subcount !followage !uptime to reduce beta.decapi.me dependancy
  • Commands for Discord
  • And lots more...

Implementation of these features is streamed live every Saturday & Sunday at twitch.tv/d0p3t


Special Thanks

I'd like to give a special thanks to the following Github users who's projects made this bot possible.


License

You can check out the full license here

This project is licensed under the terms of the MIT license.

d0p3tbot's People

Contributors

d0p3t avatar remcotroost avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

d0p3tbot's Issues

Basic Commands not working

Current Behavior: Last update included the addition of categorizing commands. The basic commands do not work currently.

Expected Behavior: The basic commands should be inserted into the database so that the bot can recognize them.

Currently, on first setup, the bot does not insert the basic commands into the database. This will be a quick and easy fix that has to be done in utils/twitch.js.

Support for Cheers/Bits

Give the user the ability to enable bit/cheer support for chat alerts. This has been requested multiple times in SubNotifier and as such should also be included in here once a decision on this feature is made.

Very easy to implement due to tmi.js's support for a Cheers event listener.`

Sub and Resub alerts don't display username, month and message correctly

Expected Behavior: Whenever someone subscribes or resubscribes to the channel, a message should pop up thanking them and displaying their username and message.

Current Behavior: Alert gets triggered but the username, message, months etc do not get displayed (see screenshot)
screenshot

This issue is due to the string that gets sent via client.say does not recognize the passed variables in the event listener client.on. Probably has to do with scope. A solution could be to use a different way of anotating the variables inside the database and then replacing them accordingly before emitting the chat message to Twitch.

For example:

  • Database: "Thank you for subscribing {username}!"
  • Backend: Replace {username} with " + username + "

This issue has high priority as it's an issue with one of the core features of the product. The proposed solution may also complete the task to support variables in commands!

bitmoji

Frontend socket does not connect to Backend

Current Behavior: The frontend dashboard should connect to the backend. Unfortunately the frontend socket has a timeout due to trying to connect to localhost:3000

Expected Behavior: Socket.IO connects from the frontend to the backend so that a websocket is established between them.

This will not be an issue if the bot is self hosted, but can cause issues if you're trying to access the dashboard remotely (if the bot is running on a VPS, for example). This will require some changes to the frontend code. Perhaps mention this in the README.md or Wiki

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.