Cyber28 / ktanecord-1

KTaNE Discord Bot

Home Page:https://discord.gg/gJVy2Rt

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

KTaNE Discord Bot

Invite

Setup

Compile the bot

Dependencies

-axios

-discord.js - v11

-enum

-larg

-lodash

-wumpfetch

Run

Run the following commands to clone the repo and get into its directory:

-git clone https://github.com/qkrisi/ktanecord

-cd ktanecord


In that directory create a file called `config.json`

Paste these lines in it, and replace the values with the proper ones:

{
    "discord": "token",
    "token": "prefix",
    "prod": false,
    "tpServerIP": "IP",
    "tpServerPort": "port",
    "tpServerPass": "yourpwd",
    "ScoreSheet": "sheetID",
    "TwitchID": "AppID",
    "TwitchSecret": "AppSecret",
    "ScoreLog": "ChannelID",
    "Invite": "Invite link",
    "SimPort": "port",
    "EnableSimulator": false
}
Name Description
discord The token of the bot
token The prefix of the bot, that it'll use before commands (help, etc.)
prod Should always be false!
tpServerIP The address of the WebSocket server in the KTaNE Simulator and the ip of the server that stores Twitch Plays scores (if needed), more about that below (can be "localhost")
tpServerPort The port of the server that stores Twitch Plays scores (if needed), more about that below
tpServerPass A password to block false scores (if needed)
ScoreSheet The ID of the Google Spreadsheet that stores module scores (if needed)
TwitchID ID of Twitch application (if needed, for streamer stats)
TwitchSecret Secret of Twitch application (if needed, for streamer stats)
ScoreLog ID of the score logging channel (if needed)
Invite Invite link of the bot with the applications.commands scope
SimPort Port of the WebSocket server in the KTaNE Simulator
EnableSimulator Boolean value indicating the usage of the KTaNE Simulator bot

KTaNE Simulator: https://github.com/Qkrisi/ktanesim

To run the bot, run the command node src/main.js

Compile the TP server

Dependencies

-Flask

-gspread

-oauth2client

-Levenshtein

You also need Python3.8+

Run

Create a Google Application with the Spreadsheet API enabled.

Create credentials for the Spreadsheet API, save that as a JSON to stats_server/credentials.json

To run the server, run the following command: python ./stats_server/__main__.py

To send scores to the server, use this mod. (More about it in the readme of its repo)

Contributions

Contributions are highly appreciated, but under the following rule(s):

-Do not submit pull requests for the master, nor the Beta branch! Pull requests are only accepted for the Test branch, which will be merged with the Beta branch later on. To switch to the Test branch, simply run git checkout Test

Support

Join our Discord Server to test out new feauters, give feedback about the bot!

If you're a streamer and wish to be the part of the tp stats system, ping me on Disord (Qkrisi#4982)



Bot made by Cyber28 and Qkrisi, maintained by Qkrisi

About

KTaNE Discord Bot

https://discord.gg/gJVy2Rt

License:MIT License


Languages

Language:JavaScript 85.9%Language:Python 14.1%