Discord bot that performs various functions.

Overview

rikka-bot Support me on Patreon!

A Discord bot that performs various functions.

Python 3.6 Discord Bots Discord Bots

Table of Contents

  1. Commands
  2. In The Works
  3. Special Thanks

Commands

Right now, this bot's prefix is ;.

Main Commands

Utility Commands

  • @mention help - Returns a command list, along with your server's prefix.
  • ;help - Returns a command list.
  • ;info - Returns information about the bot.
  • ;paypal - Returns donation link to contribute to server hosting.
  • ;vote - Returns this server's vote link on discordbots.org.
  • ;clever (text) - Returns the cleverbot response to the given text.
  • ;gizoogle (text) - Translates a given text with gizoogle.
  • ;translate (text) - Translates the specified text to English.
  • ;suggest (suggestion) - Adds a completely anonymous suggestion to better the bot.
  • ;quickvote (vote) - Creates a message with thumbs up and thumbs down, in a pretty text embed.
  • ;sayd (message) - Allows you to say an anonymous message by saying what you tell it to, and then deleting your message. Prevents @everyone, of course.
  • ;wolfram (query) - Queries a response to Wolfram Alpha.

Admin Commands

  • ;prefix (prefix) - Changes the prefix to a set custom prefix. (Must be admin)
  • ;clear (number) - Clears a set number of messages from the given channel. (Must have manage message permission)
  • ;clear (user) - Clears any messages authored by the specified user in the channel. (Must have manage message permission)
  • ;mute / ;unmute (user) - Mutes/unmutes specified user. (Must have manage message permission)
  • ;kick (user) - Kicks the specified user. (Must have kick permission)
  • ;ban (user) - Bans the specified user. (Must have ban permission)
  • ;add (points) (user(s)) - Adds a set number of points to mentioned user(s). (Must be admin)
  • ;subtract (points) (user(s)) - Subtracts a set number of points from mentioned user(s). (Must be admin)

Self-Assignable Roles

NOTE: In order to do this, Rikka must be placed above the users you would like to enable assigning to. Failure to do so will fail to assign the roles.

Rikka has a self-assignable roles system. If it is enabled for your server, you can create roles to assign yourself and other users. For these commands to work, the role names must match perfectly.

Enabling/Disabling/Listing

  • ;iamlist - Lists the assignable roles.
  • ;assign enable (role name) - Enables assignability for the given role. (Must have Manage Roles permission)
  • ;assign disable (role name)- Disables assignability for the given role. (Must have Manage Roles permission)

Assigning/Unassigning Roles

  • ;iam (role name) - Assigns yourself the role.
  • ;iamnot (role name) - Unassigns yourself the role.

Color Role System

NOTE: In order to do this, Rikka must be placed above the roles whose colors you would like to override. Failure to do so will just create and assign the role without any effect.

Rikka has a color role system. If it is enabled for your server, you can set your own color from the image below.

Color Chart

Setup

Setup requires manage roles permission.

  • ;colors (enable/disable) - enables or disables the color role mode for your server.

Usage

  • ;color (color) - Sets your color to the specified color.
  • ;color reset - Removes all of your color roles, resetting you to your original color.

Economy System

Rikka's economy system consists of a global leaderboard. Currently, you can get points in two ways: Getting questions right with the ;trivia command, and collecting points daily.

  • ;score - Displays your score, or another user's score, globally.
  • ;collect daily - Gets your daily collections.
  • ;leaderboard global - View the global leaderboard across all of rikka's servers.
  • ;leaderboard local - View the local leaderboard across all of the users on the current server.
  • ;give (points) (user) - donate points to another user.

Fun Commands

  • ;insult (user) - Sends a random insult to the given user.
  • ;ramsay - Returns a random Gordon Ramsay quote.
  • ;gay - no u
  • ;rate (thing to rate) - Rates whatever you tell it to rate on a scale of 1-10.
  • ;ping - For that annoying person who keeps @everyoneing.
  • ;beemovie - Returns a random bee movie quote.

MAL Commands

  • ;mal (anime) - Returns the result of the anime search.
  • ;mal m/(manga) - Returns the result of the manga search.
  • ;malqa (anime) - Returns the result of the anime search.
  • ;malqm (manga) - Returns the result of the manga search.
  • ;mal id a/(anime id) - Returns the result of the anime ID search.
  • ;mal id m/(manga id) - Returns the result of the manga ID search.

XKCD Commands

  • ;xkcd - Returns a random XKCD comic.
  • ;xkcd (number) - Returns a specific XKCD comic.
  • ;xkcd latest - Returns the latest XKCD comic.

Gif Commands

  • ;hello - Says hi.
  • ;hugme - Hugs you.
  • ;hug @user - Hugs the specified user.

Emotes

Note: All emotes are entirely SFW.

  • shocked, smile, hentai, blush, bdsm, rekt, boop, fuckoff, sanic, dreamy, kys

Gelbooru Commands

These commands require the channel to be marked as NSFW.

  • ;gelbooru random - Fetches a random gelbooru post.
  • ;gelbooru latest - Fetches the latest gelbooru post.
  • ;gelbooru tags (tags, comma separated) - Fetches a post that matches the specified tags.

Game Commands

Trivia Commands

  • ;trivia - Returns the help menu for trivia.
  • ;ask - Returns a randomly selected question.
  • ;a (attempt) - Tests the given attempt to see if it is correct. If it is correct, you are granted a point.
  • ;reveal - Reveals the answer, removing the ability to score for that specific question.

Casino Commands

  • ;roll - Rolls a die.
  • ;flip - Flips a coin.
  • ;8ball (question) - Tells you the future.
  • ;raffle - Select a random (non-bot) user from your server

Board Functionality

This feature is currently not functional. Sorry!

The board functionality allows popular messages to be posted on a special channel, titled board. To use this functionality, you must first run ;board enable. Afterwards, every message with 3 reactions with the "" will get posted to the board.

In the works

  • Improved, proprietary AI, instead of cleverbot.
  • Aliases for Self-Assignable Roles
  • Minecraft Server Status

Special Thanks

Comments
  • Give Points Command

    Give Points Command

    Implement a ;give points <user> <amount> command with the following spec:

    • If a user's balance >= amount, give amount points to user.
    • If a user's balance < amount, throw an error.
    • Function must use Economy.addPoints and not implement another function.
    enhancement good first issue 
    opened by LeoSaucedo 2
  • XKCD Cog Breaks Program

    XKCD Cog Breaks Program

    When Cogs.Xkcd is included in the cogs for Rikka, this error is thrown:

    Jul 18 22:12:37 ip-172-31-80-202 python[45745]: Traceback (most recent call last):
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/opt/rikka/rikka-bot/.env/lib/python3.8/site-packages/discord/ext/commands/bot.py", line 607, in _load_from_module_spec
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:     spec.loader.exec_module(lib)
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "<frozen importlib._bootstrap_external>", line 848, in exec_module
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/opt/rikka/rikka-bot/Cogs/Xkcd.py", line 10, in <module>
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:     class Xkcd(commands.Cog):
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/opt/rikka/rikka-bot/Cogs/Xkcd.py", line 11, in Xkcd
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:     required_response_fields: list[str] = ['year', 'month', 'day', 'alt', 'num']
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]: TypeError: 'type' object is not subscriptable
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]: The above exception was the direct cause of the following exception:
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]: Traceback (most recent call last):
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/opt/rikka/rikka-bot/robot.py", line 111, in <module>
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:     bot.load_extension(cog)
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/opt/rikka/rikka-bot/.env/lib/python3.8/site-packages/discord/ext/commands/bot.py", line 664, in load_extension
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:     self._load_from_module_spec(spec, name)
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/opt/rikka/rikka-bot/.env/lib/python3.8/site-packages/discord/ext/commands/bot.py", line 610, in _load_from_module_spec
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:     raise errors.ExtensionFailed(key, e) from e
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]: discord.ext.commands.errors.ExtensionFailed: Extension 'Cogs.Xkcd' raised an error: TypeError: 'type' object is not subscriptable
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]: Exception ignored in: <function ClientSession.__del__ at 0x7fed9fa20af0>Jul 18 22:12:37 ip-172-31-80-202 python[45745]: Traceback (most recent call last):
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/opt/rikka/rikka-bot/.env/lib/python3.8/site-packages/aiohttp/client.py", line 314, in __del__
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/usr/lib/python3.8/asyncio/base_events.py", line 1740, in call_exception_handler
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/usr/lib/python3.8/logging/__init__.py", line 1475, in error
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/usr/lib/python3.8/logging/__init__.py", line 1589, in _log
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/usr/lib/python3.8/logging/__init__.py", line 1599, in handle
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/usr/lib/python3.8/logging/__init__.py", line 1661, in callHandlers
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/usr/lib/python3.8/logging/__init__.py", line 954, in handle
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/usr/lib/python3.8/logging/__init__.py", line 1186, in emit
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]:   File "/usr/lib/python3.8/logging/__init__.py", line 1176, in _open
    Jul 18 22:12:37 ip-172-31-80-202 python[45745]: NameError: name 'open' is not defined
    Jul 18 22:12:37 ip-172-31-80-202 systemd[1]: rikka.service: Main process exited, code=exited, status=1/FAILURE
    Jul 18 22:12:37 ip-172-31-80-202 systemd[1]: rikka.service: Failed with result 'exit-code'.
    

    Environment Details:

    Python 3.8.10 (default, Jun  2 2021, 10:49:15)
    [GCC 9.4.0] on linux
    

    We should make sure our changes are consistent with the current python version being used by the bot.

    bug 
    opened by LeoSaucedo 1
  • View Other User's Inventory

    View Other User's Inventory

    Implement ;inv <user> with the following spec:

    • If the parameter mentioned is a valid user, display their inventory.
    • If the parameter is not a valid user, throw an error.
    • Must use existing getInventory functions.
    enhancement 
    opened by LeoSaucedo 1
  • XKCD Command

    XKCD Command

    Implement the XKCD command with the following spec:

    • Command must respond to ;xkcd.
    • If ;xkcd or ;xkcd random is given, return a random XKCD comic.
    • If ;xkcd 123 is given, return a XKCD comic 123, etc.
    • If ;kxcd latest is given, return the lastest XKCD comic.
    • Include image, title, and description in the embed.
    • All calls must be made with aiohttp.
    enhancement good first issue 
    opened by LeoSaucedo 1
  • Answer command sometimes is not interpreted

    Answer command sometimes is not interpreted

    Screenshot_20210717-163108

    The answer command is sometimes not triggered when a user attempts to answer an active trivia question. Normal behavior always prompts a response from the bot, whether it is correct or not, and in the attached example no message was returned.

    We must investigate why the answer isn't returning and what we can do to resolve it.

    bug 
    opened by LeoSaucedo 1
  • ;leaderboard global breaks on non-existent user

    ;leaderboard global breaks on non-existent user

    image Rikka returns this error whenever the user inside of the leaderboard is not valid.

    A try-catch is the easy fix, but there could be another, better fix that removes the null user from the leaderboard, which should be integrated once the sql branch is released.

    bug 
    opened by LeoSaucedo 1
  • Trivia answer attempt is triggered whenever a message starts with ;a.

    Trivia answer attempt is triggered whenever a message starts with ;a.

    In this example, two separate functions are called: image

    There needs to be a way to sort out attempts, perhaps by renaming the attempt call or rewriting the code with the if statements.

    bug 
    opened by LeoSaucedo 1
  • Some insults are grammatically incorrect

    Some insults are grammatically incorrect

    When selecting a random insult with the SFW insult command, the program does not make any effort to be grammatically correct, and uses the "a" article instead of selecting "a" or "an" depending on the word the article is referencing. image

    bug 
    opened by LeoSaucedo 1
  • UnboundLocalError when CleverBot fails

    UnboundLocalError when CleverBot fails

    When CleverBot fails, when returning the "failed" message, it results in an UnboundLocal error. This is because it is sending a new message when it fails, instead of defining "msg" upon its success.

    bug 
    opened by LeoSaucedo 1
  • Change from Deprecated Library and Handle Discord Intents Update

    Change from Deprecated Library and Handle Discord Intents Update

    DBL was obviously deprecated, causing rikka-bot to no longer function. The Discord update messed with a few other things as well with the introduction of Intents. Toppggpy appears to be DBL's successor and seems to run when the proper changes are made.

    I would like some review on this, perhaps maybe a bit more refined pickings of the Intents, but this allows for the bot code to compile and run.

    image

    image

    opened by SirTarragon 1
  • Add opt-out of bot function

    Add opt-out of bot function

    To make a message contents privileged intent to Rikka, we must implement a way for a user to opt out of having their message information read. This should be done via DMing the bot, and we should keep a database of User IDs that have opted out of using Rikka within a server. This requires us having a new database column or table containing this information as well as a function implementation for receiving DMs. This action should be reversible and should be able to be reversed via DMs as well.

    enhancement 
    opened by LeoSaucedo 0
  • Add privacy policy command

    Add privacy policy command

    To request the message content privileged gateway, we need to implement a command that spits out a generic privacy policy.

    This requires:

    • Upload a generic privacy policy to the repository
    • Link to it within Rikka via a command
    enhancement 
    opened by LeoSaucedo 0
  • Eval Command

    Eval Command

    Implement an admin-only ;eval args Command with the following spec:

    • When a user supplies a valid argument, we shall execute the python command that is given and return it in a formatted string.
    • Errors in executing the command should not fail the bot running.
    • This command must be non-ocking.

    Admin-only is to be defined as users contained within a config.json object of trusted people.

    enhancement 
    opened by LeoSaucedo 0
  • Compare only alphanumeric characters for Trivia

    Compare only alphanumeric characters for Trivia

    The format command must be updated so that it only preserves alphanumeric characters and removes "a", "an" and "the" from the beginning of the answers and attempts. This is to resolve most issues with the comparison.

    bug 
    opened by LeoSaucedo 0
  • Give Items Command

    Give Items Command

    Implement a ;give item <user> <item> <amount> feature with the following spec:

    • If a user owns >= amount items, give amount items to user.
    • If a user owns < amount items, inform the user that there is not enough of the item to give.
    • Use the addItem on both the donor and receiver to prevent item inflation.
    enhancement 
    opened by LeoSaucedo 0
Releases(0.0.1)
Owner
Carlos Saucedo
Computer Science at Florida State University. Software Engineering at Grainhouse.
Carlos Saucedo
A little proxy tool based on Tencent Cloud Function Service.

SCFProxy 一个基于腾讯云函数服务的免费代理池。 安装 python3 -m venv .venv source .venv/bin/activate pip3 install -r requirements.txt 项目配置 函数配置 开通腾讯云函数服务 在 函数服务 新建 中使用自定义

Mio 716 Dec 26, 2022
:electric_plug: Generating short urls with python has never been easier

pyshorteners A simple URL shortening API wrapper Python library. Installing pip install pyshorteners Documentation https://pyshorteners.readthedocs.i

Ellison 351 Jan 03, 2023
Ice-Userbot adalah userbot Telegram modular yang berjalan di Python3 dengan database sqlalchemy

Ice-Userbot Telegram Ice-Userbot adalah userbot Telegram modular yang berjalan di Python3 dengan database sqlalchemy. Berbasis Paperplane dan ProjectB

6 Apr 29, 2022
Quickly visualize docker networks with graphviz.

Docker Network Graph Visualize the relationship between Docker networks and containers as a neat graphviz graph. Example Usage usage: docker-net-graph

Leo Verto 43 Dec 12, 2022
This will create new discord accounts and add them to your server

Discord-Botter This tool will create new discord accounts add them to your server, this tool needs a captcha api like capmonster.cloud or anti-captcha

Shahzain 27 Nov 30, 2022
Ghost-toolbox - Ghost's official Discord raid tool

Ghost Toolbox Ghost's official Discord raid tool. How to use Clone this repo int

G H Ø S T 10 Oct 31, 2022
Yet another Wahrheit-oder-Pflicht bot for Telegram, because all the others suck.

Der WoPperBot Yet another Wahrheit-oder-Pflicht bot for Telegram, because all the others suck. The existing bots are all defunct or incomplete. So I w

Ben Wiederhake 9 Nov 15, 2022
Drop-in Replacement of pychallonge

pychal Pychal is a drop-in replacement of pychallonge with some extra features and support for new Python versions. Pychal provides python bindings fo

ZED 29 Nov 28, 2022
Criando Lambda Functions para Ingerir Dados de APIs com AWS CDK

LIVE001 - AWS Lambda para Ingerir Dados de APIs Fazer o deploy de uma função lambda com infraestrutura como código Lambda vai numa API externa e extra

Andre Sionek 12 Nov 20, 2022
Export Statistics for a Telegram Group Chat

Telegram Statistics Export Statistics for a Telegram Group Chat How to Run First, in main repo directory, run the following code to add src to your PY

Ali Hejazizo 22 Dec 05, 2022
Fully undetected auto skillcheck hack for dead by daylight that works decently well

Auto-skillcheck was made by Love ❌ code ✅ ❔ ・How to use Start off by installing python ofc Open cmd in the same directory and type pip install -r requ

Rdimo 10 Aug 13, 2022
Create Multiple CF entry for multiple websites

AWS-CloudFront Problem: Deploy multiple CloudFront for account with multiple domains. Functionality: Running this script in loop and deploy CloudFront

Giten Mitra 5 Nov 18, 2022
Prime Mega is a modular bot running on python3 with autobots theme and have a lot features.

PRIME MEGA Prime Mega is a modular bot running on python3 with autobots theme and have a lot features. Easiest Way To Deploy On Heroku This Bot is Cre

『TØNIC』 乂 ₭ILLΣR 45 Dec 15, 2022
OKEX数字货币自动交易python语言SDK

okex-py OKEx数字货币自动交易python语言SDK (非官方) OKEx Cryptocurrency Exchange python SDK (Unofficial) 本项目基于V5 API 使用例子 Example import okex.v5.account_api as acco

43 Dec 01, 2022
Bagas Mirror&Leech Bot is a multipurpose Telegram Bot written in Python for mirroring files on the Internet to our beloved Google Drive. Based on python-aria-mirror-bot

- [ MAYBE UPDATE & ADD MORE MODULE ] Bagas Mirror&Leech Bot Bagas Mirror&Leech Bot is a multipurpose Telegram Bot written in Python for mirroring file

4 Nov 23, 2021
New discord token grabber, password and general information

New discord token grabber, password and general information

Monstered 6 Nov 09, 2022
Python client and module for BGP Ranking

Python client and module for BGP Ranking THis project will make querying BGP Ranking easier. Installation pip install pybgpranking Usage Command line

D4 project 3 Dec 16, 2021
🤖 Automated follow/unfollow bot for GitHub. Uses GitHub API. Written in python.

GitHub Follow Bot Table of Contents Disclaimer How to Use Install requirements Authenticate Get a GitHub Personal Access Token Add your GitHub usernam

João Correia 37 Dec 27, 2022
Price checker windows application

Price-Checker price checker windows application This application monitors the prices of selected products and displays a notification if the price has

Danila Tsareff 1 Nov 29, 2021
A Telegram Userbot to play Audio and Video songs / files in Telegram Voice Chats.

VC UserBot A Telegram Userbot to play Audio and Video songs / files in Telegram Voice Chats. It's made with PyTgCalls and Pyrogram Requirements Python

조던 1 Nov 29, 2021