Merge branch 'master' into conquest_develop
# Conflicts: # conquest/info.json
This commit is contained in:
		
						commit
						aadd9a61a8
					
				@ -38,6 +38,10 @@ class AnnounceDaily(Cog):
 | 
				
			|||||||
        self.config.register_global(**default_global)
 | 
					        self.config.register_global(**default_global)
 | 
				
			||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    async def _get_msgs(self):
 | 
					    async def _get_msgs(self):
 | 
				
			||||||
        return DEFAULT_MESSAGES + await self.config.messages()
 | 
					        return DEFAULT_MESSAGES + await self.config.messages()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -2,15 +2,12 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Send daily announcements to all servers at a specified times",
 | 
					  "description": "Send daily announcements to all servers at a specified times",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing AnnounceDaily! Get started with `[p]load announcedaily` and `[p]help AnnounceDaily`",
 | 
					  "install_msg": "Thank you for installing AnnounceDaily! Get started with `[p]load announcedaily` and `[p]help AnnounceDaily`",
 | 
				
			||||||
  "short": "Send daily announcements",
 | 
					  "short": "Send daily announcements",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy"
 | 
					    "bobloy"
 | 
				
			||||||
  ]
 | 
					  ]
 | 
				
			||||||
 | 
				
			|||||||
@ -2,15 +2,12 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Start an Audio Trivia game",
 | 
					  "description": "Start an Audio Trivia game",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing Audio trivia!\n You **MUST** unload trivia to use this (`[p]unload trivia`)\n Then you can get started with `[p]load audiotrivia` and `[p]help AudioTrivia`",
 | 
					  "install_msg": "Thank you for installing Audio trivia!\n You **MUST** unload trivia to use this (`[p]unload trivia`)\n Then you can get started with `[p]load audiotrivia` and `[p]help AudioTrivia`",
 | 
				
			||||||
  "short": "Start an Audio Trivia game",
 | 
					  "short": "Start an Audio Trivia game",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog expands the core Audio and Trivia cogs without collecting any additional End User Data.\nSee the core End User Data storage for more information",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "fox",
 | 
					    "fox",
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
 | 
				
			|||||||
@ -22,6 +22,10 @@ class CCRole(commands.Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.guild_only()
 | 
					    @commands.guild_only()
 | 
				
			||||||
    @commands.group()
 | 
					    @commands.group()
 | 
				
			||||||
    async def ccrole(self, ctx: commands.Context):
 | 
					    async def ccrole(self, ctx: commands.Context):
 | 
				
			||||||
 | 
				
			|||||||
@ -2,15 +2,12 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Creates custom commands to adjust roles and send custom messages",
 | 
					  "description": "Creates custom commands to adjust roles and send custom messages",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing Custom Commands w/ Roles. Get started with `[p]load ccrole` and `[p]help CCRole`",
 | 
					  "install_msg": "Thank you for installing Custom Commands w/ Roles. Get started with `[p]load ccrole` and `[p]help CCRole`",
 | 
				
			||||||
  "short": "Creates commands that adjust roles",
 | 
					  "short": "Creates commands that adjust roles",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "fox",
 | 
					    "fox",
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
 | 
				
			|||||||
@ -3,6 +3,7 @@ import logging
 | 
				
			|||||||
import os
 | 
					import os
 | 
				
			||||||
import pathlib
 | 
					import pathlib
 | 
				
			||||||
from datetime import datetime, timedelta
 | 
					from datetime import datetime, timedelta
 | 
				
			||||||
 | 
					from typing import Literal
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import discord
 | 
					import discord
 | 
				
			||||||
from chatterbot import ChatBot
 | 
					from chatterbot import ChatBot
 | 
				
			||||||
@ -13,6 +14,7 @@ from redbot.core import Config, commands
 | 
				
			|||||||
from redbot.core.commands import Cog
 | 
					from redbot.core.commands import Cog
 | 
				
			||||||
from redbot.core.data_manager import cog_data_path
 | 
					from redbot.core.data_manager import cog_data_path
 | 
				
			||||||
from redbot.core.utils.predicates import MessagePredicate
 | 
					from redbot.core.utils.predicates import MessagePredicate
 | 
				
			||||||
 | 
					from redbot.core.utils import AsyncIter
 | 
				
			||||||
 | 
					
 | 
				
			||||||
log = logging.getLogger("red.fox_v3.chat")
 | 
					log = logging.getLogger("red.fox_v3.chat")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -65,6 +67,10 @@ class Chatter(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        self.loop = asyncio.get_event_loop()
 | 
					        self.loop = asyncio.get_event_loop()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def _create_chatbot(self):
 | 
					    def _create_chatbot(self):
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        return ChatBot(
 | 
					        return ChatBot(
 | 
				
			||||||
@ -107,7 +113,7 @@ class Chatter(Cog):
 | 
				
			|||||||
        for channel in ctx.guild.text_channels:
 | 
					        for channel in ctx.guild.text_channels:
 | 
				
			||||||
            if in_channel:
 | 
					            if in_channel:
 | 
				
			||||||
                channel = in_channel
 | 
					                channel = in_channel
 | 
				
			||||||
            await ctx.send("Gathering {}".format(channel.mention))
 | 
					            await ctx.maybe_send_embed("Gathering {}".format(channel.mention))
 | 
				
			||||||
            user = None
 | 
					            user = None
 | 
				
			||||||
            i = 0
 | 
					            i = 0
 | 
				
			||||||
            send_time = after - timedelta(days=100)  # Makes the first message a new message
 | 
					            send_time = after - timedelta(days=100)  # Makes the first message a new message
 | 
				
			||||||
@ -188,7 +194,7 @@ class Chatter(Cog):
 | 
				
			|||||||
        """
 | 
					        """
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if not confirm:
 | 
					        if not confirm:
 | 
				
			||||||
            await ctx.send(
 | 
					            await ctx.maybe_send_embed(
 | 
				
			||||||
                "Warning, this command will erase all your training data and reset your configuration\n"
 | 
					                "Warning, this command will erase all your training data and reset your configuration\n"
 | 
				
			||||||
                "If you want to proceed, run the command again as `[p]chatter cleardata True`"
 | 
					                "If you want to proceed, run the command again as `[p]chatter cleardata True`"
 | 
				
			||||||
            )
 | 
					            )
 | 
				
			||||||
@ -314,7 +320,7 @@ class Chatter(Cog):
 | 
				
			|||||||
        Backup your training data to a json for later use
 | 
					        Backup your training data to a json for later use
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        await ctx.send("Backing up data, this may take a while")
 | 
					        await ctx.maybe_send_embed("Backing up data, this may take a while")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        path: pathlib.Path = cog_data_path(self)
 | 
					        path: pathlib.Path = cog_data_path(self)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -325,9 +331,9 @@ class Chatter(Cog):
 | 
				
			|||||||
        )
 | 
					        )
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if future:
 | 
					        if future:
 | 
				
			||||||
            await ctx.send(f"Backup successful! Look in {path} for your backup")
 | 
					            await ctx.maybe_send_embed(f"Backup successful! Look in {path} for your backup")
 | 
				
			||||||
        else:
 | 
					        else:
 | 
				
			||||||
            await ctx.send("Error occurred :(")
 | 
					            await ctx.maybe_send_embed("Error occurred :(")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @chatter.command(name="trainubuntu")
 | 
					    @chatter.command(name="trainubuntu")
 | 
				
			||||||
    async def chatter_train_ubuntu(self, ctx: commands.Context, confirmation: bool = False):
 | 
					    async def chatter_train_ubuntu(self, ctx: commands.Context, confirmation: bool = False):
 | 
				
			||||||
@ -359,9 +365,9 @@ class Chatter(Cog):
 | 
				
			|||||||
            future = await self.loop.run_in_executor(None, self._train_english)
 | 
					            future = await self.loop.run_in_executor(None, self._train_english)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if future:
 | 
					        if future:
 | 
				
			||||||
            await ctx.send("Training successful!")
 | 
					            await ctx.maybe_send_embed("Training successful!")
 | 
				
			||||||
        else:
 | 
					        else:
 | 
				
			||||||
            await ctx.send("Error occurred :(")
 | 
					            await ctx.maybe_send_embed("Error occurred :(")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @chatter.command()
 | 
					    @chatter.command()
 | 
				
			||||||
    async def train(self, ctx: commands.Context, channel: discord.TextChannel):
 | 
					    async def train(self, ctx: commands.Context, channel: discord.TextChannel):
 | 
				
			||||||
@ -369,7 +375,7 @@ class Chatter(Cog):
 | 
				
			|||||||
        Trains the bot based on language in this guild
 | 
					        Trains the bot based on language in this guild
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        await ctx.send(
 | 
					        await ctx.maybe_send_embed(
 | 
				
			||||||
            "Warning: The cog may use significant RAM or CPU if trained on large data sets.\n"
 | 
					            "Warning: The cog may use significant RAM or CPU if trained on large data sets.\n"
 | 
				
			||||||
            "Additionally, large sets will use more disk space to save the trained data.\n\n"
 | 
					            "Additionally, large sets will use more disk space to save the trained data.\n\n"
 | 
				
			||||||
            "If you experience issues, clear your trained data and train again on a smaller scope."
 | 
					            "If you experience issues, clear your trained data and train again on a smaller scope."
 | 
				
			||||||
@ -379,10 +385,10 @@ class Chatter(Cog):
 | 
				
			|||||||
            conversation = await self._get_conversation(ctx, channel)
 | 
					            conversation = await self._get_conversation(ctx, channel)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if not conversation:
 | 
					        if not conversation:
 | 
				
			||||||
            await ctx.send("Failed to gather training data")
 | 
					            await ctx.maybe_send_embed("Failed to gather training data")
 | 
				
			||||||
            return
 | 
					            return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        await ctx.send(
 | 
					        await ctx.maybe_send_embed(
 | 
				
			||||||
            "Gather successful! Training begins now\n"
 | 
					            "Gather successful! Training begins now\n"
 | 
				
			||||||
            "(**This will take a long time, be patient. See console for progress**)"
 | 
					            "(**This will take a long time, be patient. See console for progress**)"
 | 
				
			||||||
        )
 | 
					        )
 | 
				
			||||||
@ -397,9 +403,9 @@ class Chatter(Cog):
 | 
				
			|||||||
            pass
 | 
					            pass
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if future:
 | 
					        if future:
 | 
				
			||||||
            await ctx.send("Training successful!")
 | 
					            await ctx.maybe_send_embed("Training successful!")
 | 
				
			||||||
        else:
 | 
					        else:
 | 
				
			||||||
            await ctx.send("Error occurred :(")
 | 
					            await ctx.maybe_send_embed("Error occurred :(")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.Cog.listener()
 | 
					    @commands.Cog.listener()
 | 
				
			||||||
    async def on_message_without_command(self, message: discord.Message):
 | 
					    async def on_message_without_command(self, message: discord.Message):
 | 
				
			||||||
 | 
				
			|||||||
@ -2,11 +2,7 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.10",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    10
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Create an offline chatbot that talks like your average member using Machine Learning",
 | 
					  "description": "Create an offline chatbot that talks like your average member using Machine Learning",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing Chatter! Get started ith `[p]load chatter` and `[p]help Chatter`",
 | 
					  "install_msg": "Thank you for installing Chatter! Get started ith `[p]load chatter` and `[p]help Chatter`",
 | 
				
			||||||
@ -24,6 +20,7 @@
 | 
				
			|||||||
    "spacy>=2.3,<2.4"
 | 
					    "spacy>=2.3,<2.4"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "short": "Local Chatbot run on machine learning",
 | 
					  "short": "Local Chatbot run on machine learning",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog only stores anonymous conversations data; no End User Data is stored.",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "chat",
 | 
					    "chat",
 | 
				
			||||||
    "chatbot",
 | 
					    "chatbot",
 | 
				
			||||||
 | 
				
			|||||||
@ -28,6 +28,10 @@ class CogLint(Cog):
 | 
				
			|||||||
        self.config.register_global(**default_global)
 | 
					        self.config.register_global(**default_global)
 | 
				
			||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.command()
 | 
					    @commands.command()
 | 
				
			||||||
    async def autolint(self, ctx: commands.Context):
 | 
					    async def autolint(self, ctx: commands.Context):
 | 
				
			||||||
        """Toggles automatically linting code"""
 | 
					        """Toggles automatically linting code"""
 | 
				
			||||||
@ -35,7 +39,7 @@ class CogLint(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        self.do_lint = not curr
 | 
					        self.do_lint = not curr
 | 
				
			||||||
        await self.config.lint.set(not curr)
 | 
					        await self.config.lint.set(not curr)
 | 
				
			||||||
        await ctx.send("Autolinting is now set to {}".format(not curr))
 | 
					        await ctx.maybe_send_embed("Autolinting is now set to {}".format(not curr))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.command()
 | 
					    @commands.command()
 | 
				
			||||||
    async def lint(self, ctx: commands.Context, *, code):
 | 
					    async def lint(self, ctx: commands.Context, *, code):
 | 
				
			||||||
@ -44,7 +48,7 @@ class CogLint(Cog):
 | 
				
			|||||||
        Toggle autolinting with `[p]autolint`
 | 
					        Toggle autolinting with `[p]autolint`
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
        await self.lint_message(ctx.message)
 | 
					        await self.lint_message(ctx.message)
 | 
				
			||||||
        await ctx.send("Hello World")
 | 
					        await ctx.maybe_send_embed("Hello World")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    async def lint_code(self, code):
 | 
					    async def lint_code(self, code):
 | 
				
			||||||
        self.counter += 1
 | 
					        self.counter += 1
 | 
				
			||||||
 | 
				
			|||||||
@ -2,16 +2,15 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Lint python code posted in chat",
 | 
					  "description": "Lint python code posted in chat",
 | 
				
			||||||
  "hidden": true,
 | 
					  "hidden": true,
 | 
				
			||||||
  "install_msg": "Thank you for installing CogLint! Get started with `[p]load coglint` and `[p]help CogLint`",
 | 
					  "install_msg": "Thank you for installing CogLint! Get started with `[p]load coglint` and `[p]help CogLint`",
 | 
				
			||||||
  "requirements": ["pylint"],
 | 
					  "requirements": [
 | 
				
			||||||
 | 
					    "pylint"
 | 
				
			||||||
 | 
					  ],
 | 
				
			||||||
  "short": "Python cog linter",
 | 
					  "short": "Python cog linter",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "utils",
 | 
					    "utils",
 | 
				
			||||||
 | 
				
			|||||||
@ -32,6 +32,10 @@ class Dad(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        self.cooldown = defaultdict(datetime.now)
 | 
					        self.cooldown = defaultdict(datetime.now)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.command()
 | 
					    @commands.command()
 | 
				
			||||||
    async def dadjoke(self, ctx: commands.Context):
 | 
					    async def dadjoke(self, ctx: commands.Context):
 | 
				
			||||||
        headers = {
 | 
					        headers = {
 | 
				
			||||||
 | 
				
			|||||||
@ -2,15 +2,12 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Tell dad jokes and give out bad nicknames",
 | 
					  "description": "Tell dad jokes and give out bad nicknames",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing Dad. Get started with `[p]load dad`, then `[p]help Dad`",
 | 
					  "install_msg": "Thank you for installing Dad. Get started with `[p]load dad`, then `[p]help Dad`",
 | 
				
			||||||
  "short": "Dad joke bot",
 | 
					  "short": "Dad joke bot",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "utils",
 | 
					    "utils",
 | 
				
			||||||
 | 
				
			|||||||
@ -18,6 +18,10 @@ class ExclusiveRole(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.guild_only()
 | 
					    @commands.guild_only()
 | 
				
			||||||
    @commands.group(aliases=["exclusiverole"])
 | 
					    @commands.group(aliases=["exclusiverole"])
 | 
				
			||||||
    async def exclusive(self, ctx):
 | 
					    async def exclusive(self, ctx):
 | 
				
			||||||
 | 
				
			|||||||
@ -2,15 +2,12 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Assign roles to be exclusive, preventing other roles from being added",
 | 
					  "description": "Assign roles to be exclusive, preventing other roles from being added",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing ExclusiveRole. Get started with `[p]load exclusiverole` and `[p]help ExclusiveRole`",
 | 
					  "install_msg": "Thank you for installing ExclusiveRole. Get started with `[p]load exclusiverole` and `[p]help ExclusiveRole`",
 | 
				
			||||||
  "short": "Set roles to be exclusive",
 | 
					  "short": "Set roles to be exclusive",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "fox",
 | 
					    "fox",
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										31
									
								
								flag/flag.py
									
									
									
									
									
								
							
							
						
						
									
										31
									
								
								flag/flag.py
									
									
									
									
									
								
							@ -1,9 +1,11 @@
 | 
				
			|||||||
from datetime import date, timedelta
 | 
					from datetime import date, timedelta
 | 
				
			||||||
 | 
					from typing import Literal
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import discord
 | 
					import discord
 | 
				
			||||||
from redbot.core import Config, checks, commands
 | 
					from redbot.core import Config, checks, commands
 | 
				
			||||||
from redbot.core.bot import Red
 | 
					from redbot.core.bot import Red
 | 
				
			||||||
from redbot.core.commands import Cog
 | 
					from redbot.core.commands import Cog
 | 
				
			||||||
 | 
					from redbot.core.utils import AsyncIter
 | 
				
			||||||
from redbot.core.utils.chat_formatting import pagify
 | 
					from redbot.core.utils.chat_formatting import pagify
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -22,6 +24,21 @@ class Flag(Cog):
 | 
				
			|||||||
        self.config.register_global(**default_global)
 | 
					        self.config.register_global(**default_global)
 | 
				
			||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(
 | 
				
			||||||
 | 
					        self,
 | 
				
			||||||
 | 
					        *,
 | 
				
			||||||
 | 
					        requester: Literal["discord_deleted_user", "owner", "user", "user_strict"],
 | 
				
			||||||
 | 
					        user_id: int,
 | 
				
			||||||
 | 
					    ):
 | 
				
			||||||
 | 
					        if requester not in ["discord_deleted_user", "owner"]:
 | 
				
			||||||
 | 
					            return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        all_guilds = await self.config.all_guilds()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        async for guild_id, guild_data in AsyncIter(all_guilds.items(), steps=100):
 | 
				
			||||||
 | 
					            if user_id in guild_data["flags"]:
 | 
				
			||||||
 | 
					                await self.config.guild_from_id(guild_id).flags.clear_raw(user_id)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @checks.is_owner()
 | 
					    @checks.is_owner()
 | 
				
			||||||
    @commands.guild_only()
 | 
					    @commands.guild_only()
 | 
				
			||||||
    @commands.command()
 | 
					    @commands.command()
 | 
				
			||||||
@ -29,7 +46,7 @@ class Flag(Cog):
 | 
				
			|||||||
        """Clears all flags for all members in this server"""
 | 
					        """Clears all flags for all members in this server"""
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        await self.config.guild(ctx.guild).flags.clear()
 | 
					        await self.config.guild(ctx.guild).flags.clear()
 | 
				
			||||||
        await ctx.send("Done")
 | 
					        await ctx.maybe_send_embed("Done")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @checks.mod_or_permissions(manage_roles=True)
 | 
					    @checks.mod_or_permissions(manage_roles=True)
 | 
				
			||||||
    @commands.guild_only()
 | 
					    @commands.guild_only()
 | 
				
			||||||
@ -49,7 +66,7 @@ class Flag(Cog):
 | 
				
			|||||||
        Set the number of days for flags to expire after for server
 | 
					        Set the number of days for flags to expire after for server
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
        await self.config.guild(ctx.guild).days.set(days)
 | 
					        await self.config.guild(ctx.guild).days.set(days)
 | 
				
			||||||
        await ctx.send("Number of days for new flags to expire is now {} days".format(days))
 | 
					        await ctx.maybe_send_embed("Number of days for new flags to expire is now {} days".format(days))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @flagset.command(name="dm")
 | 
					    @flagset.command(name="dm")
 | 
				
			||||||
    async def flagset_dm(self, ctx: commands.Context):
 | 
					    async def flagset_dm(self, ctx: commands.Context):
 | 
				
			||||||
@ -58,7 +75,7 @@ class Flag(Cog):
 | 
				
			|||||||
        dm = await self.config.guild(ctx.guild).dm()
 | 
					        dm = await self.config.guild(ctx.guild).dm()
 | 
				
			||||||
        await self.config.guild(ctx.guild).dm.set(not dm)
 | 
					        await self.config.guild(ctx.guild).dm.set(not dm)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        await ctx.send("DM-ing members when they get a flag is now set to **{}**".format(not dm))
 | 
					        await ctx.maybe_send_embed("DM-ing members when they get a flag is now set to **{}**".format(not dm))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @staticmethod
 | 
					    @staticmethod
 | 
				
			||||||
    def _flag_template():
 | 
					    def _flag_template():
 | 
				
			||||||
@ -97,9 +114,9 @@ class Flag(Cog):
 | 
				
			|||||||
                try:
 | 
					                try:
 | 
				
			||||||
                    await member.send(embed=outembed)
 | 
					                    await member.send(embed=outembed)
 | 
				
			||||||
                except discord.Forbidden:
 | 
					                except discord.Forbidden:
 | 
				
			||||||
                    await ctx.send("DM-ing user failed")
 | 
					                    await ctx.maybe_send_embed("DM-ing user failed")
 | 
				
			||||||
        else:
 | 
					        else:
 | 
				
			||||||
            await ctx.send("This member has no flags.. somehow..")
 | 
					            await ctx.maybe_send_embed("This member has no flags.. somehow..")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.guild_only()
 | 
					    @commands.guild_only()
 | 
				
			||||||
    @checks.mod_or_permissions(manage_roles=True)
 | 
					    @checks.mod_or_permissions(manage_roles=True)
 | 
				
			||||||
@ -111,7 +128,7 @@ class Flag(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        await self.config.guild(guild).flags.set_raw(str(member.id), value=[])
 | 
					        await self.config.guild(guild).flags.set_raw(str(member.id), value=[])
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        await ctx.send("Success!")
 | 
					        await ctx.maybe_send_embed("Success!")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.guild_only()
 | 
					    @commands.guild_only()
 | 
				
			||||||
    @commands.command(aliases=["flaglist"])
 | 
					    @commands.command(aliases=["flaglist"])
 | 
				
			||||||
@ -125,7 +142,7 @@ class Flag(Cog):
 | 
				
			|||||||
        if outembed:
 | 
					        if outembed:
 | 
				
			||||||
            await ctx.send(embed=outembed)
 | 
					            await ctx.send(embed=outembed)
 | 
				
			||||||
        else:
 | 
					        else:
 | 
				
			||||||
            await ctx.send("This member has no flags!")
 | 
					            await ctx.maybe_send_embed("This member has no flags!")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.guild_only()
 | 
					    @commands.guild_only()
 | 
				
			||||||
    @commands.command(aliases=["flagall"])
 | 
					    @commands.command(aliases=["flagall"])
 | 
				
			||||||
 | 
				
			|||||||
@ -2,15 +2,12 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Add expiring flags on members to track warnings or incidents",
 | 
					  "description": "Add expiring flags on members to track warnings or incidents",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing Flag! Get started with `[p]load flag` and `[p]help Flag`",
 | 
					  "install_msg": "Thank you for installing Flag! Get started with `[p]load flag` and `[p]help Flag`",
 | 
				
			||||||
  "short": "Add expiring flags to members",
 | 
					  "short": "Add expiring flags to members",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog stores user IDs listed along with a provided explanation for being flagged",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "warning",
 | 
					    "warning",
 | 
				
			||||||
 | 
				
			|||||||
@ -21,6 +21,10 @@ class ForceMention(Cog):
 | 
				
			|||||||
        self.config.register_global(**default_global)
 | 
					        self.config.register_global(**default_global)
 | 
				
			||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @checks.admin_or_permissions(manage_roles=True)
 | 
					    @checks.admin_or_permissions(manage_roles=True)
 | 
				
			||||||
    @commands.command()
 | 
					    @commands.command()
 | 
				
			||||||
    async def forcemention(self, ctx: commands.Context, role: str, *, message=""):
 | 
					    async def forcemention(self, ctx: commands.Context, role: str, *, message=""):
 | 
				
			||||||
 | 
				
			|||||||
@ -2,15 +2,12 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Mentions roles that are unmentionable",
 | 
					  "description": "Mentions roles that are unmentionable",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing ForceMention! Get started with `[p]load forcemention`, then `[p]forcemention`",
 | 
					  "install_msg": "Thank you for installing ForceMention! Get started with `[p]load forcemention`, then `[p]forcemention`",
 | 
				
			||||||
  "short": "Mention unmentionables",
 | 
					  "short": "Mention unmentionables",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "utils"
 | 
					    "utils"
 | 
				
			||||||
 | 
				
			|||||||
@ -14,6 +14,7 @@ class Hangman(Cog):
 | 
				
			|||||||
    letters = "🇦🇧🇨🇩🇪🇫🇬🇭🇮🇯🇰🇱🇲🇳🇴🇵🇶🇷🇸🇹🇺🇻🇼🇽🇾🇿"
 | 
					    letters = "🇦🇧🇨🇩🇪🇫🇬🇭🇮🇯🇰🇱🇲🇳🇴🇵🇶🇷🇸🇹🇺🇻🇼🇽🇾🇿"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def __init__(self, bot):
 | 
					    def __init__(self, bot):
 | 
				
			||||||
 | 
					        super().__init__()
 | 
				
			||||||
        self.bot = bot
 | 
					        self.bot = bot
 | 
				
			||||||
        self.config = Config.get_conf(self, identifier=1049711010310997110)
 | 
					        self.config = Config.get_conf(self, identifier=1049711010310997110)
 | 
				
			||||||
        default_guild = {"theface": ":thinking:", "emojis": True}
 | 
					        default_guild = {"theface": ":thinking:", "emojis": True}
 | 
				
			||||||
@ -39,6 +40,10 @@ class Hangman(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        self.hanglist = {}
 | 
					        self.hanglist = {}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    async def _update_hanglist(self):
 | 
					    async def _update_hanglist(self):
 | 
				
			||||||
        for guild in self.bot.guilds:
 | 
					        for guild in self.bot.guilds:
 | 
				
			||||||
            theface = await self.config.guild(guild).theface()
 | 
					            theface = await self.config.guild(guild).theface()
 | 
				
			||||||
@ -154,19 +159,19 @@ class Hangman(Cog):
 | 
				
			|||||||
            theface = self.bot.get_emoji(int(theface.split(":")[2][:-1]))
 | 
					            theface = self.bot.get_emoji(int(theface.split(":")[2][:-1]))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if theface is None:
 | 
					        if theface is None:
 | 
				
			||||||
            await ctx.send("I could not find that emoji")
 | 
					            await ctx.maybe_send_embed("I could not find that emoji")
 | 
				
			||||||
            return
 | 
					            return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        try:
 | 
					        try:
 | 
				
			||||||
            # Use the face as reaction to see if it's valid (THANKS FLAPJACK <3)
 | 
					            # Use the face as reaction to see if it's valid (THANKS FLAPJACK <3)
 | 
				
			||||||
            await message.add_reaction(theface)
 | 
					            await message.add_reaction(theface)
 | 
				
			||||||
        except discord.errors.HTTPException:
 | 
					        except discord.errors.HTTPException:
 | 
				
			||||||
            await ctx.send("That's not an emoji I recognize.")
 | 
					            await ctx.maybe_send_embed("That's not an emoji I recognize.")
 | 
				
			||||||
            return
 | 
					            return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        await self.config.guild(ctx.guild).theface.set(str(theface))
 | 
					        await self.config.guild(ctx.guild).theface.set(str(theface))
 | 
				
			||||||
        await self._update_hanglist()
 | 
					        await self._update_hanglist()
 | 
				
			||||||
        await ctx.send("Face has been updated!")
 | 
					        await ctx.maybe_send_embed("Face has been updated!")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @hangset.command()
 | 
					    @hangset.command()
 | 
				
			||||||
    async def toggleemoji(self, ctx: commands.Context):
 | 
					    async def toggleemoji(self, ctx: commands.Context):
 | 
				
			||||||
@ -174,26 +179,26 @@ class Hangman(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        current = await self.config.guild(ctx.guild).emojis()
 | 
					        current = await self.config.guild(ctx.guild).emojis()
 | 
				
			||||||
        await self.config.guild(ctx.guild).emojis.set(not current)
 | 
					        await self.config.guild(ctx.guild).emojis.set(not current)
 | 
				
			||||||
        await ctx.send("Emoji Letter reactions have been set to {}".format(not current))
 | 
					        await ctx.maybe_send_embed("Emoji Letter reactions have been set to {}".format(not current))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.command(aliases=["hang"])
 | 
					    @commands.command(aliases=["hang"])
 | 
				
			||||||
    async def hangman(self, ctx, guess: str = None):
 | 
					    async def hangman(self, ctx, guess: str = None):
 | 
				
			||||||
        """Play a game of hangman against the bot!"""
 | 
					        """Play a game of hangman against the bot!"""
 | 
				
			||||||
        if guess is None:
 | 
					        if guess is None:
 | 
				
			||||||
            if self.the_data[ctx.guild]["running"]:
 | 
					            if self.the_data[ctx.guild]["running"]:
 | 
				
			||||||
                await ctx.send("Game of hangman is already running!\nEnter your guess!")
 | 
					                await ctx.maybe_send_embed("Game of hangman is already running!\nEnter your guess!")
 | 
				
			||||||
                await self._printgame(ctx.channel)
 | 
					                await self._printgame(ctx.channel)
 | 
				
			||||||
                """await self.bot.send_cmd_help(ctx)"""
 | 
					                """await self.bot.send_cmd_help(ctx)"""
 | 
				
			||||||
            else:
 | 
					            else:
 | 
				
			||||||
                await ctx.send("Starting a game of hangman!")
 | 
					                await ctx.maybe_send_embed("Starting a game of hangman!")
 | 
				
			||||||
                self._startgame(ctx.guild)
 | 
					                self._startgame(ctx.guild)
 | 
				
			||||||
                await self._printgame(ctx.channel)
 | 
					                await self._printgame(ctx.channel)
 | 
				
			||||||
        elif not self.the_data[ctx.guild]["running"]:
 | 
					        elif not self.the_data[ctx.guild]["running"]:
 | 
				
			||||||
            await ctx.send("Game of hangman is not yet running!\nStarting a game of hangman!")
 | 
					            await ctx.maybe_send_embed("Game of hangman is not yet running!\nStarting a game of hangman!")
 | 
				
			||||||
            self._startgame(ctx.guild)
 | 
					            self._startgame(ctx.guild)
 | 
				
			||||||
            await self._printgame(ctx.channel)
 | 
					            await self._printgame(ctx.channel)
 | 
				
			||||||
        else:
 | 
					        else:
 | 
				
			||||||
            await ctx.send("Guess by reacting to the message")
 | 
					            await ctx.maybe_send_embed("Guess by reacting to the message")
 | 
				
			||||||
            # await self._guessletter(guess, ctx.channel)
 | 
					            # await self._guessletter(guess, ctx.channel)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def _startgame(self, guild):
 | 
					    def _startgame(self, guild):
 | 
				
			||||||
 | 
				
			|||||||
@ -2,16 +2,13 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Play Hangman with your friends",
 | 
					  "description": "Play Hangman with your friends",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing Hangman! Get started with `[p]load hangman`, then `[p]help Hangman`",
 | 
					  "install_msg": "Thank you for installing Hangman! Get started with `[p]load hangman`, then `[p]help Hangman`",
 | 
				
			||||||
  "requirements": [],
 | 
					  "requirements": [],
 | 
				
			||||||
  "short": "Play Hangman",
 | 
					  "short": "Play Hangman",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "game",
 | 
					    "game",
 | 
				
			||||||
    "fun",
 | 
					    "fun",
 | 
				
			||||||
 | 
				
			|||||||
@ -2,15 +2,12 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Create a channel with updating server info",
 | 
					  "description": "Create a channel with updating server info",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing InfoChannel. Get started with `[p]load infochannel`, then `[p]help InfoChannel`",
 | 
					  "install_msg": "Thank you for installing InfoChannel. Get started with `[p]load infochannel`, then `[p]help InfoChannel`",
 | 
				
			||||||
  "short": "Updating server info channel",
 | 
					  "short": "Updating server info channel",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "utils"
 | 
					    "utils"
 | 
				
			||||||
 | 
				
			|||||||
@ -41,6 +41,10 @@ class InfoChannel(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        self._critical_section_wooah_ = 0
 | 
					        self._critical_section_wooah_ = 0
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.command()
 | 
					    @commands.command()
 | 
				
			||||||
    @checks.admin()
 | 
					    @checks.admin()
 | 
				
			||||||
    async def infochannel(self, ctx: commands.Context):
 | 
					    async def infochannel(self, ctx: commands.Context):
 | 
				
			||||||
 | 
				
			|||||||
@ -2,15 +2,12 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Keeps track of when people leave the server, and posts a message notifying",
 | 
					  "description": "Keeps track of when people leave the server, and posts a message notifying",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing Leaver. Get started with `[p]load leaver`, then `[p]help Leaver`",
 | 
					  "install_msg": "Thank you for installing Leaver. Get started with `[p]load leaver`, then `[p]help Leaver`",
 | 
				
			||||||
  "short": "Send message on leave",
 | 
					  "short": "Send message on leave",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "utils",
 | 
					    "utils",
 | 
				
			||||||
 | 
				
			|||||||
@ -10,12 +10,17 @@ class Leaver(Cog):
 | 
				
			|||||||
    """
 | 
					    """
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def __init__(self, bot: Red):
 | 
					    def __init__(self, bot: Red):
 | 
				
			||||||
 | 
					        super().__init__()
 | 
				
			||||||
        self.bot = bot
 | 
					        self.bot = bot
 | 
				
			||||||
        self.config = Config.get_conf(self, identifier=9811198108111121, force_registration=True)
 | 
					        self.config = Config.get_conf(self, identifier=9811198108111121, force_registration=True)
 | 
				
			||||||
        default_guild = {"channel": ""}
 | 
					        default_guild = {"channel": ""}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.group(aliases=["setleaver"])
 | 
					    @commands.group(aliases=["setleaver"])
 | 
				
			||||||
    @checks.mod_or_permissions(administrator=True)
 | 
					    @checks.mod_or_permissions(administrator=True)
 | 
				
			||||||
    async def leaverset(self, ctx):
 | 
					    async def leaverset(self, ctx):
 | 
				
			||||||
@ -28,7 +33,7 @@ class Leaver(Cog):
 | 
				
			|||||||
        """Choose the channel to send leave messages to"""
 | 
					        """Choose the channel to send leave messages to"""
 | 
				
			||||||
        guild = ctx.guild
 | 
					        guild = ctx.guild
 | 
				
			||||||
        await self.config.guild(guild).channel.set(ctx.channel.id)
 | 
					        await self.config.guild(guild).channel.set(ctx.channel.id)
 | 
				
			||||||
        await ctx.send("Channel set to " + ctx.channel.name)
 | 
					        await ctx.maybe_send_embed("Channel set to " + ctx.channel.name)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.Cog.listener()
 | 
					    @commands.Cog.listener()
 | 
				
			||||||
    async def on_member_remove(self, member: discord.Member):
 | 
					    async def on_member_remove(self, member: discord.Member):
 | 
				
			||||||
 | 
				
			|||||||
@ -3,11 +3,7 @@
 | 
				
			|||||||
    "Bobloy",
 | 
					    "Bobloy",
 | 
				
			||||||
    "SnappyDragon"
 | 
					    "SnappyDragon"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Calculate the love percentage for two users",
 | 
					  "description": "Calculate the love percentage for two users",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing LoveCalculator. Love is in the air.\n Get started with `[p]load lovecalculator`, then `[p]help LoveCalculator`",
 | 
					  "install_msg": "Thank you for installing LoveCalculator. Love is in the air.\n Get started with `[p]load lovecalculator`, then `[p]help LoveCalculator`",
 | 
				
			||||||
@ -15,6 +11,7 @@
 | 
				
			|||||||
    "beautifulsoup4"
 | 
					    "beautifulsoup4"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "short": "Calculate love percentage",
 | 
					  "short": "Calculate love percentage",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog uses the core Bank cog. It store no End User Data otherwise.",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "fun",
 | 
					    "fun",
 | 
				
			||||||
 | 
				
			|||||||
@ -9,8 +9,13 @@ class LoveCalculator(Cog):
 | 
				
			|||||||
    """Calculate the love percentage for two users!"""
 | 
					    """Calculate the love percentage for two users!"""
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def __init__(self, bot):
 | 
					    def __init__(self, bot):
 | 
				
			||||||
 | 
					        super().__init__()
 | 
				
			||||||
        self.bot = bot
 | 
					        self.bot = bot
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.command(aliases=["lovecalc"])
 | 
					    @commands.command(aliases=["lovecalc"])
 | 
				
			||||||
    async def lovecalculator(
 | 
					    async def lovecalculator(
 | 
				
			||||||
            self, ctx: commands.Context, lover: discord.Member, loved: discord.Member
 | 
					            self, ctx: commands.Context, lover: discord.Member, loved: discord.Member
 | 
				
			||||||
 | 
				
			|||||||
@ -2,16 +2,15 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Keep track of when users were last seen online",
 | 
					  "description": "Keep track of when users were last seen online",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing LastSeen. Get started with `[p]load lseen`, then `[p]help LastSeen`",
 | 
					  "install_msg": "Thank you for installing LastSeen. Get started with `[p]load lseen`, then `[p]help LastSeen`",
 | 
				
			||||||
  "requirements": ["python-dateutil"],
 | 
					  "requirements": [
 | 
				
			||||||
 | 
					    "python-dateutil"
 | 
				
			||||||
 | 
					  ],
 | 
				
			||||||
  "short": "Last seen tracker",
 | 
					  "short": "Last seen tracker",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog stores user IDs along with a time they were last online per guild",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "utils",
 | 
					    "utils",
 | 
				
			||||||
 | 
				
			|||||||
@ -1,10 +1,12 @@
 | 
				
			|||||||
from datetime import datetime
 | 
					from datetime import datetime
 | 
				
			||||||
 | 
					from typing import Literal
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import dateutil.parser
 | 
					import dateutil.parser
 | 
				
			||||||
import discord
 | 
					import discord
 | 
				
			||||||
from redbot.core import Config, commands
 | 
					from redbot.core import Config, commands
 | 
				
			||||||
from redbot.core.bot import Red
 | 
					from redbot.core.bot import Red
 | 
				
			||||||
from redbot.core.commands import Cog
 | 
					from redbot.core.commands import Cog
 | 
				
			||||||
 | 
					from redbot.core.utils import AsyncIter
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
class LastSeen(Cog):
 | 
					class LastSeen(Cog):
 | 
				
			||||||
@ -28,6 +30,19 @@ class LastSeen(Cog):
 | 
				
			|||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
        self.config.register_member(**default_member)
 | 
					        self.config.register_member(**default_member)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(
 | 
				
			||||||
 | 
					        self,
 | 
				
			||||||
 | 
					        *,
 | 
				
			||||||
 | 
					        requester: Literal["discord_deleted_user", "owner", "user", "user_strict"],
 | 
				
			||||||
 | 
					        user_id: int,
 | 
				
			||||||
 | 
					    ):
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        all_members = await self.config.all_members()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        async for guild_id, guild_data in AsyncIter(all_members.items(), steps=100):
 | 
				
			||||||
 | 
					            if user_id in guild_data:
 | 
				
			||||||
 | 
					                await self.config.member_from_ids(guild_id, user_id).clear()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @staticmethod
 | 
					    @staticmethod
 | 
				
			||||||
    def get_date_time(s):
 | 
					    def get_date_time(s):
 | 
				
			||||||
        d = dateutil.parser.parse(s)
 | 
					        d = dateutil.parser.parse(s)
 | 
				
			||||||
@ -45,7 +60,7 @@ class LastSeen(Cog):
 | 
				
			|||||||
        enabled = not await self.config.guild(ctx.guild).enabled()
 | 
					        enabled = not await self.config.guild(ctx.guild).enabled()
 | 
				
			||||||
        await self.config.guild(ctx.guild).enabled.set(enabled)
 | 
					        await self.config.guild(ctx.guild).enabled.set(enabled)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        await ctx.send(
 | 
					        await ctx.maybe_send_embed(
 | 
				
			||||||
            "Seen for this server is now {}".format("Enabled" if enabled else "Disabled")
 | 
					            "Seen for this server is now {}".format("Enabled" if enabled else "Disabled")
 | 
				
			||||||
        )
 | 
					        )
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -60,7 +75,7 @@ class LastSeen(Cog):
 | 
				
			|||||||
        else:
 | 
					        else:
 | 
				
			||||||
            last_seen = await self.config.member(member).seen()
 | 
					            last_seen = await self.config.member(member).seen()
 | 
				
			||||||
            if last_seen is None:
 | 
					            if last_seen is None:
 | 
				
			||||||
                await ctx.send(embed=discord.Embed(description="I've never seen this user"))
 | 
					                await ctx.maybe_send_embed(embed=discord.Embed(description="I've never seen this user"))
 | 
				
			||||||
                return
 | 
					                return
 | 
				
			||||||
            last_seen = self.get_date_time(last_seen)
 | 
					            last_seen = self.get_date_time(last_seen)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -2,11 +2,7 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "min_bot_version": [
 | 
					  "min_bot_version": "3.3.11",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    11
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Monitor images for NSFW content and moves them to a nsfw channel if possible",
 | 
					  "description": "Monitor images for NSFW content and moves them to a nsfw channel if possible",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing Nudity. Get started with `[p]load nudity`, then `[p]help Nudity`",
 | 
					  "install_msg": "Thank you for installing Nudity. Get started with `[p]load nudity`, then `[p]help Nudity`",
 | 
				
			||||||
 | 
				
			|||||||
@ -4,16 +4,13 @@
 | 
				
			|||||||
    "SnappyDragon",
 | 
					    "SnappyDragon",
 | 
				
			||||||
    "PaddoInWonderland"
 | 
					    "PaddoInWonderland"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Grow your own plants! Be sure to take care of it. Do `[p]gardening` to get started",
 | 
					  "description": "Grow your own plants! Be sure to take care of it. Do `[p]gardening` to get started",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing PlantTycoon. Check out all the commands with `[p]help PlantTycoon`",
 | 
					  "install_msg": "Thank you for installing PlantTycoon. Check out all the commands with `[p]help PlantTycoon`",
 | 
				
			||||||
  "requirements": [],
 | 
					  "requirements": [],
 | 
				
			||||||
  "short": "Grow your own plants! Do `[p]gardening` to get started.",
 | 
					  "short": "Grow your own plants! Do `[p]gardening` to get started.",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog stores user IDs along with their progress in the PlantTycoon game",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "games",
 | 
					    "games",
 | 
				
			||||||
 | 
				
			|||||||
@ -5,18 +5,19 @@ import datetime
 | 
				
			|||||||
import json
 | 
					import json
 | 
				
			||||||
import time
 | 
					import time
 | 
				
			||||||
from random import choice
 | 
					from random import choice
 | 
				
			||||||
 | 
					from typing import Literal
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import discord
 | 
					import discord
 | 
				
			||||||
from redbot.core import Config, bank, commands
 | 
					from redbot.core import Config, bank, commands
 | 
				
			||||||
from redbot.core.bot import Red
 | 
					from redbot.core.bot import Red
 | 
				
			||||||
from redbot.core.data_manager import bundled_data_path
 | 
					from redbot.core.data_manager import bundled_data_path
 | 
				
			||||||
 | 
					from redbot.core.utils import AsyncIter
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
class Gardener(commands.Cog):
 | 
					class Gardener:
 | 
				
			||||||
    """Gardener class"""
 | 
					    """Gardener class"""
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def __init__(self, user: discord.User, config: Config):
 | 
					    def __init__(self, user: discord.User, config: Config):
 | 
				
			||||||
        super().__init__()
 | 
					 | 
				
			||||||
        self.user = user
 | 
					        self.user = user
 | 
				
			||||||
        self.config = config
 | 
					        self.config = config
 | 
				
			||||||
        self.badges = []
 | 
					        self.badges = []
 | 
				
			||||||
@ -180,7 +181,17 @@ class PlantTycoon(commands.Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        # self.bank = bot.get_cog('Economy').bank
 | 
					        # self.bank = bot.get_cog('Economy').bank
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(
 | 
				
			||||||
 | 
					        self,
 | 
				
			||||||
 | 
					        *,
 | 
				
			||||||
 | 
					        requester: Literal["discord_deleted_user", "owner", "user", "user_strict"],
 | 
				
			||||||
 | 
					        user_id: int,
 | 
				
			||||||
 | 
					    ):
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        await self.config.user_from_id(user_id).clear()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    async def _load_plants_products(self):
 | 
					    async def _load_plants_products(self):
 | 
				
			||||||
 | 
					        """Runs in __init__.py before cog is added to the bot"""
 | 
				
			||||||
        plant_path = bundled_data_path(self) / "plants.json"
 | 
					        plant_path = bundled_data_path(self) / "plants.json"
 | 
				
			||||||
        product_path = bundled_data_path(self) / "products.json"
 | 
					        product_path = bundled_data_path(self) / "products.json"
 | 
				
			||||||
        with plant_path.open() as json_data:
 | 
					        with plant_path.open() as json_data:
 | 
				
			||||||
 | 
				
			|||||||
@ -2,11 +2,7 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Create a QR code invite for the server",
 | 
					  "description": "Create a QR code invite for the server",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing QRInvite! Get started with `[p]load qrinvite`, then `[p]help QRInvite`",
 | 
					  "install_msg": "Thank you for installing QRInvite! Get started with `[p]load qrinvite`, then `[p]help QRInvite`",
 | 
				
			||||||
@ -14,6 +10,7 @@
 | 
				
			|||||||
    "MyQR"
 | 
					    "MyQR"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "short": "Create a QR code invite",
 | 
					  "short": "Create a QR code invite",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "tools",
 | 
					    "tools",
 | 
				
			||||||
 | 
				
			|||||||
@ -25,6 +25,10 @@ class QRInvite(Cog):
 | 
				
			|||||||
        self.config.register_global(**default_global)
 | 
					        self.config.register_global(**default_global)
 | 
				
			||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.command()
 | 
					    @commands.command()
 | 
				
			||||||
    async def qrinvite(
 | 
					    async def qrinvite(
 | 
				
			||||||
        self,
 | 
					        self,
 | 
				
			||||||
@ -44,7 +48,7 @@ class QRInvite(Cog):
 | 
				
			|||||||
                    invite = await ctx.channel.invites()
 | 
					                    invite = await ctx.channel.invites()
 | 
				
			||||||
                    invite = invite[0]
 | 
					                    invite = invite[0]
 | 
				
			||||||
                except discord.Forbidden:
 | 
					                except discord.Forbidden:
 | 
				
			||||||
                    await ctx.send("No permission to get an invite, please provide one")
 | 
					                    await ctx.maybe_send_embed("No permission to get an invite, please provide one")
 | 
				
			||||||
                    return
 | 
					                    return
 | 
				
			||||||
            invite = invite.code
 | 
					            invite = invite.code
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -52,7 +56,7 @@ class QRInvite(Cog):
 | 
				
			|||||||
            image_url = str(ctx.guild.icon_url)
 | 
					            image_url = str(ctx.guild.icon_url)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if image_url == "":  # Still
 | 
					        if image_url == "":  # Still
 | 
				
			||||||
            await ctx.send(
 | 
					            await ctx.maybe_send_embed(
 | 
				
			||||||
                "Could not get an image, please provide one. *(`{}help qrinvite` for details)*".format(
 | 
					                "Could not get an image, please provide one. *(`{}help qrinvite` for details)*".format(
 | 
				
			||||||
                    ctx.prefix
 | 
					                    ctx.prefix
 | 
				
			||||||
                )
 | 
					                )
 | 
				
			||||||
@ -73,12 +77,12 @@ class QRInvite(Cog):
 | 
				
			|||||||
        if extension == "webp":
 | 
					        if extension == "webp":
 | 
				
			||||||
            new_path = convert_webp_to_png(str(image_path))
 | 
					            new_path = convert_webp_to_png(str(image_path))
 | 
				
			||||||
        elif extension == "gif":
 | 
					        elif extension == "gif":
 | 
				
			||||||
            await ctx.send("gif is not supported yet, stay tuned")
 | 
					            await ctx.maybe_send_embed("gif is not supported yet, stay tuned")
 | 
				
			||||||
            return
 | 
					            return
 | 
				
			||||||
        elif extension == "png":
 | 
					        elif extension == "png":
 | 
				
			||||||
            new_path = str(image_path)
 | 
					            new_path = str(image_path)
 | 
				
			||||||
        else:
 | 
					        else:
 | 
				
			||||||
            await ctx.send(f"{extension} is not supported yet, stay tuned")
 | 
					            await ctx.maybe_send_embed(f"{extension} is not supported yet, stay tuned")
 | 
				
			||||||
            return
 | 
					            return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        myqr.run(
 | 
					        myqr.run(
 | 
				
			||||||
 | 
				
			|||||||
@ -2,15 +2,12 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Cog to prevent reactions on specific messages from certain users",
 | 
					  "description": "Cog to prevent reactions on specific messages from certain users",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing ReactRestrict.",
 | 
					  "install_msg": "Thank you for installing ReactRestrict.",
 | 
				
			||||||
  "short": "Prevent reactions to messages",
 | 
					  "short": "Prevent reactions to messages",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "react",
 | 
					    "react",
 | 
				
			||||||
    "reaction",
 | 
					    "reaction",
 | 
				
			||||||
 | 
				
			|||||||
@ -35,6 +35,10 @@ class ReactRestrict(Cog):
 | 
				
			|||||||
        )
 | 
					        )
 | 
				
			||||||
        self.config.register_global(registered_combos=[])
 | 
					        self.config.register_global(registered_combos=[])
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    async def combo_list(self) -> List[ReactRestrictCombo]:
 | 
					    async def combo_list(self) -> List[ReactRestrictCombo]:
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
        Returns a list of reactrestrict combos.
 | 
					        Returns a list of reactrestrict combos.
 | 
				
			||||||
@ -209,7 +213,7 @@ class ReactRestrict(Cog):
 | 
				
			|||||||
        """
 | 
					        """
 | 
				
			||||||
        message = await self._get_message(ctx, message_id)
 | 
					        message = await self._get_message(ctx, message_id)
 | 
				
			||||||
        if message is None:
 | 
					        if message is None:
 | 
				
			||||||
            await ctx.send("That message doesn't seem to exist.")
 | 
					            await ctx.maybe_send_embed("That message doesn't seem to exist.")
 | 
				
			||||||
            return
 | 
					            return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        # try:
 | 
					        # try:
 | 
				
			||||||
@ -228,7 +232,7 @@ class ReactRestrict(Cog):
 | 
				
			|||||||
        # noinspection PyTypeChecker
 | 
					        # noinspection PyTypeChecker
 | 
				
			||||||
        await self.add_reactrestrict(message_id, role)
 | 
					        await self.add_reactrestrict(message_id, role)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        await ctx.send("Message|Role combo added.")
 | 
					        await ctx.maybe_send_embed("Message|Role combo added.")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @reactrestrict.command()
 | 
					    @reactrestrict.command()
 | 
				
			||||||
    async def remove(self, ctx: commands.Context, message_id: int, role: discord.Role):
 | 
					    async def remove(self, ctx: commands.Context, message_id: int, role: discord.Role):
 | 
				
			||||||
 | 
				
			|||||||
@ -3,15 +3,12 @@
 | 
				
			|||||||
    "Bobloy",
 | 
					    "Bobloy",
 | 
				
			||||||
    "SnappyDragon"
 | 
					    "SnappyDragon"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Apply for a job at the recycling plant! Sort out the garbage!",
 | 
					  "description": "Apply for a job at the recycling plant! Sort out the garbage!",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing RecyclingPlant. Start recycling today with `[p]load recyclingplant`, then `[p]recyclingplant`",
 | 
					  "install_msg": "Thank you for installing RecyclingPlant. Start recycling today with `[p]load recyclingplant`, then `[p]recyclingplant`",
 | 
				
			||||||
  "short": "Apply for a job at the recycling plant!",
 | 
					  "short": "Apply for a job at the recycling plant!",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog used the core",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "environment",
 | 
					    "environment",
 | 
				
			||||||
 | 
				
			|||||||
@ -15,6 +15,10 @@ class RecyclingPlant(Cog):
 | 
				
			|||||||
        self.bot = bot
 | 
					        self.bot = bot
 | 
				
			||||||
        self.junk = None
 | 
					        self.junk = None
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def load_junk(self):
 | 
					    def load_junk(self):
 | 
				
			||||||
        junk_path = bundled_data_path(self) / "junk.json"
 | 
					        junk_path = bundled_data_path(self) / "junk.json"
 | 
				
			||||||
        with junk_path.open() as json_data:
 | 
					        with junk_path.open() as json_data:
 | 
				
			||||||
 | 
				
			|||||||
@ -3,16 +3,13 @@
 | 
				
			|||||||
    "Bobloy",
 | 
					    "Bobloy",
 | 
				
			||||||
    "SnappyDragon"
 | 
					    "SnappyDragon"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Play Rock Papers Scissor Lizard Spock by Sam Kass in Discord!",
 | 
					  "description": "Play Rock Papers Scissor Lizard Spock by Sam Kass in Discord!",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing RPSLS. Get started with `[p]load rpsls`, then `[p]rpsls`",
 | 
					  "install_msg": "Thank you for installing RPSLS. Get started with `[p]load rpsls`, then `[p]rpsls`",
 | 
				
			||||||
  "requirements": [],
 | 
					  "requirements": [],
 | 
				
			||||||
  "short": "Play Rock Papers Scissor Lizard Spock in Discord!",
 | 
					  "short": "Play Rock Papers Scissor Lizard Spock in Discord!",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "star trek",
 | 
					    "star trek",
 | 
				
			||||||
 | 
				
			|||||||
@ -21,6 +21,10 @@ class RPSLS(Cog):
 | 
				
			|||||||
        super().__init__()
 | 
					        super().__init__()
 | 
				
			||||||
        self.bot = bot
 | 
					        self.bot = bot
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.command()
 | 
					    @commands.command()
 | 
				
			||||||
    async def rpsls(self, ctx: commands.Context, choice: str):
 | 
					    async def rpsls(self, ctx: commands.Context, choice: str):
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
 | 
				
			|||||||
@ -2,16 +2,15 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Convert any website into text and post it in chat",
 | 
					  "description": "Convert any website into text and post it in chat",
 | 
				
			||||||
  "hidden": true,
 | 
					  "hidden": true,
 | 
				
			||||||
  "install_msg": "Thank you for installing SayUrl! Get started with `[p]load sayurl`, then `[p]help SayUrl",
 | 
					  "install_msg": "Thank you for installing SayUrl! Get started with `[p]load sayurl`, then `[p]help SayUrl",
 | 
				
			||||||
  "requirements": ["html2text"],
 | 
					  "requirements": [
 | 
				
			||||||
 | 
					    "html2text"
 | 
				
			||||||
 | 
					  ],
 | 
				
			||||||
  "short": "Convert URL to text",
 | 
					  "short": "Convert URL to text",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "tools"
 | 
					    "tools"
 | 
				
			||||||
 | 
				
			|||||||
@ -27,6 +27,10 @@ class SayUrl(Cog):
 | 
				
			|||||||
        self.config.register_global(**default_global)
 | 
					        self.config.register_global(**default_global)
 | 
				
			||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.command()
 | 
					    @commands.command()
 | 
				
			||||||
    async def sayurl(self, ctx: commands.Context, url):
 | 
					    async def sayurl(self, ctx: commands.Context, url):
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
 | 
				
			|||||||
@ -3,16 +3,13 @@
 | 
				
			|||||||
    "Bobloy",
 | 
					    "Bobloy",
 | 
				
			||||||
    "SnappyDragon"
 | 
					    "SnappyDragon"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Look up SCP articles. Warning: Some of them may be too creepy or gruesome.",
 | 
					  "description": "Look up SCP articles. Warning: Some of them may be too creepy or gruesome.",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "You are now connected to the SCP database. You may now proceed to access the data using `[p]load scp`, then `[p]help SCP`",
 | 
					  "install_msg": "You are now connected to the SCP database. You may now proceed to access the data using `[p]load scp`, then `[p]help SCP`",
 | 
				
			||||||
  "requirements": [],
 | 
					  "requirements": [],
 | 
				
			||||||
  "short": "Look up SCP articles.",
 | 
					  "short": "Look up SCP articles.",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "gruesom"
 | 
					    "gruesom"
 | 
				
			||||||
 | 
				
			|||||||
@ -11,6 +11,10 @@ class SCP(Cog):
 | 
				
			|||||||
        super().__init__()
 | 
					        super().__init__()
 | 
				
			||||||
        self.bot = bot
 | 
					        self.bot = bot
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.command()
 | 
					    @commands.command()
 | 
				
			||||||
    async def scp(self, ctx: commands.Context, num: int):
 | 
					    async def scp(self, ctx: commands.Context, num: int):
 | 
				
			||||||
        """Look up SCP articles.
 | 
					        """Look up SCP articles.
 | 
				
			||||||
 | 
				
			|||||||
@ -2,16 +2,13 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Steals custom emojis the bot sees and moves them to an emoji server",
 | 
					  "description": "Steals custom emojis the bot sees and moves them to an emoji server",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing StealEmoji",
 | 
					  "install_msg": "Thank you for installing StealEmoji",
 | 
				
			||||||
  "requirements": [],
 | 
					  "requirements": [],
 | 
				
			||||||
  "short": "Steals custom emojis",
 | 
					  "short": "Steals custom emojis",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog gathers custom emojis from all sources, but stores no End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "utils",
 | 
					    "utils",
 | 
				
			||||||
 | 
				
			|||||||
@ -49,6 +49,10 @@ class StealEmoji(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        self.is_on = None
 | 
					        self.is_on = None
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.group()
 | 
					    @commands.group()
 | 
				
			||||||
    async def stealemoji(self, ctx: commands.Context):
 | 
					    async def stealemoji(self, ctx: commands.Context):
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
@ -100,14 +104,14 @@ class StealEmoji(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        if not curr_setting:
 | 
					        if not curr_setting:
 | 
				
			||||||
            await self.config.notify.set(1)
 | 
					            await self.config.notify.set(1)
 | 
				
			||||||
            await ctx.send("Bot owner will now be notified when an emoji is stolen")
 | 
					            await ctx.maybe_send_embed("Bot owner will now be notified when an emoji is stolen")
 | 
				
			||||||
        elif curr_setting == 1:
 | 
					        elif curr_setting == 1:
 | 
				
			||||||
            channel: discord.TextChannel = ctx.channel
 | 
					            channel: discord.TextChannel = ctx.channel
 | 
				
			||||||
            await self.config.notify.set(channel.id)
 | 
					            await self.config.notify.set(channel.id)
 | 
				
			||||||
            await ctx.send("This channel will now be notified when an emoji is stolen")
 | 
					            await ctx.maybe_send_embed("This channel will now be notified when an emoji is stolen")
 | 
				
			||||||
        else:
 | 
					        else:
 | 
				
			||||||
            await self.config.notify.set(0)
 | 
					            await self.config.notify.set(0)
 | 
				
			||||||
            await ctx.send("Notifications are now off")
 | 
					            await ctx.maybe_send_embed("Notifications are now off")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @checks.is_owner()
 | 
					    @checks.is_owner()
 | 
				
			||||||
    @stealemoji.command(name="collect")
 | 
					    @stealemoji.command(name="collect")
 | 
				
			||||||
@ -118,7 +122,7 @@ class StealEmoji(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        self.is_on = await self.config.on()
 | 
					        self.is_on = await self.config.on()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        await ctx.send("Collection is now " + str(not curr_setting))
 | 
					        await ctx.maybe_send_embed("Collection is now " + str(not curr_setting))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @checks.is_owner()
 | 
					    @checks.is_owner()
 | 
				
			||||||
    @commands.guild_only()
 | 
					    @commands.guild_only()
 | 
				
			||||||
@ -136,12 +140,12 @@ class StealEmoji(Cog):
 | 
				
			|||||||
        already_a_guildbank = ctx.guild.id in (await self.config.guildbanks())
 | 
					        already_a_guildbank = ctx.guild.id in (await self.config.guildbanks())
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if already_a_guildbank:
 | 
					        if already_a_guildbank:
 | 
				
			||||||
            await ctx.send(
 | 
					            await ctx.maybe_send_embed(
 | 
				
			||||||
                "This is already an emoji bank\n"
 | 
					                "This is already an emoji bank\n"
 | 
				
			||||||
                "Are you sure you want to remove the current server from the emoji bank list? (y/n)"
 | 
					                "Are you sure you want to remove the current server from the emoji bank list? (y/n)"
 | 
				
			||||||
            )
 | 
					            )
 | 
				
			||||||
        else:
 | 
					        else:
 | 
				
			||||||
            await ctx.send(
 | 
					            await ctx.maybe_send_embed(
 | 
				
			||||||
                "This will upload custom emojis to this server\n"
 | 
					                "This will upload custom emojis to this server\n"
 | 
				
			||||||
                "Are you sure you want to make the current server an emoji bank? (y/n)"
 | 
					                "Are you sure you want to make the current server an emoji bank? (y/n)"
 | 
				
			||||||
            )
 | 
					            )
 | 
				
			||||||
@ -149,7 +153,7 @@ class StealEmoji(Cog):
 | 
				
			|||||||
        msg = await self.bot.wait_for("message", check=check)
 | 
					        msg = await self.bot.wait_for("message", check=check)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if msg.content.upper() in ["N", "NO"]:
 | 
					        if msg.content.upper() in ["N", "NO"]:
 | 
				
			||||||
            await ctx.send("Cancelled")
 | 
					            await ctx.maybe_send_embed("Cancelled")
 | 
				
			||||||
            return
 | 
					            return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        async with self.config.guildbanks() as guildbanks:
 | 
					        async with self.config.guildbanks() as guildbanks:
 | 
				
			||||||
@ -159,9 +163,9 @@ class StealEmoji(Cog):
 | 
				
			|||||||
                guildbanks.append(ctx.guild.id)
 | 
					                guildbanks.append(ctx.guild.id)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if already_a_guildbank:
 | 
					        if already_a_guildbank:
 | 
				
			||||||
            await ctx.send("This server has been removed from being an emoji bank")
 | 
					            await ctx.maybe_send_embed("This server has been removed from being an emoji bank")
 | 
				
			||||||
        else:
 | 
					        else:
 | 
				
			||||||
            await ctx.send("This server has been added to be an emoji bank")
 | 
					            await ctx.maybe_send_embed("This server has been added to be an emoji bank")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.Cog.listener()
 | 
					    @commands.Cog.listener()
 | 
				
			||||||
    async def on_reaction_add(self, reaction: discord.Reaction, user: discord.User):
 | 
					    async def on_reaction_add(self, reaction: discord.Reaction, user: discord.User):
 | 
				
			||||||
 | 
				
			|||||||
@ -2,15 +2,12 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Apply roles based on the # of days on server",
 | 
					  "description": "Apply roles based on the # of days on server",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing timerole.\nGet started with `[p]load timerole`. Configure with `[p]timerole`",
 | 
					  "install_msg": "Thank you for installing timerole.\nGet started with `[p]load timerole`. Configure with `[p]timerole`",
 | 
				
			||||||
  "short": "Apply roles after # of days",
 | 
					  "short": "Apply roles after # of days",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "utilities",
 | 
					    "utilities",
 | 
				
			||||||
 | 
				
			|||||||
@ -22,6 +22,10 @@ class Timerole(Cog):
 | 
				
			|||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
        self.updating = self.bot.loop.create_task(self.check_day())
 | 
					        self.updating = self.bot.loop.create_task(self.check_day())
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def cog_unload(self):
 | 
					    def cog_unload(self):
 | 
				
			||||||
        self.updating.cancel()
 | 
					        self.updating.cancel()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -2,11 +2,7 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Send Text2Speech messages as an uploaded mp3",
 | 
					  "description": "Send Text2Speech messages as an uploaded mp3",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "Thank you for installing TTS. Get started with `[p]load tts`, then `[p]help TTS`",
 | 
					  "install_msg": "Thank you for installing TTS. Get started with `[p]load tts`, then `[p]help TTS`",
 | 
				
			||||||
@ -14,6 +10,7 @@
 | 
				
			|||||||
    "gTTS"
 | 
					    "gTTS"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "short": "Send TTS messages as uploaded mp3",
 | 
					  "short": "Send TTS messages as uploaded mp3",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "utils",
 | 
					    "utils",
 | 
				
			||||||
 | 
				
			|||||||
@ -23,6 +23,10 @@ class TTS(Cog):
 | 
				
			|||||||
        self.config.register_global(**default_global)
 | 
					        self.config.register_global(**default_global)
 | 
				
			||||||
        self.config.register_guild(**default_guild)
 | 
					        self.config.register_guild(**default_guild)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.command(aliases=["t2s", "text2"])
 | 
					    @commands.command(aliases=["t2s", "text2"])
 | 
				
			||||||
    async def tts(self, ctx: commands.Context, *, text: str):
 | 
					    async def tts(self, ctx: commands.Context, *, text: str):
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
 | 
				
			|||||||
@ -3,16 +3,13 @@
 | 
				
			|||||||
    "Bobloy",
 | 
					    "Bobloy",
 | 
				
			||||||
    "SnappyDragon"
 | 
					    "SnappyDragon"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Encode/Decode Unicode characters!",
 | 
					  "description": "Encode/Decode Unicode characters!",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": false,
 | 
				
			||||||
  "install_msg": "\u0048\u0065\u006c\u006c\u006f\u0021 \u0054\u0068\u0069\u0073 \u006d\u0065\u0073\u0073\u0061\u0067\u0065 \u0077\u0061\u0073 \u0077\u0072\u0069\u0074\u0074\u0065\u006e \u0069\u006e \u0055\u004e\u0049\u0043\u004f\u0044\u0045\u002e",
 | 
					  "install_msg": "\u0048\u0065\u006c\u006c\u006f\u0021 \u0054\u0068\u0069\u0073 \u006d\u0065\u0073\u0073\u0061\u0067\u0065 \u0077\u0061\u0073 \u0077\u0072\u0069\u0074\u0074\u0065\u006e \u0069\u006e \u0055\u004e\u0049\u0043\u004f\u0044\u0045\u002e",
 | 
				
			||||||
  "requirements": [],
 | 
					  "requirements": [],
 | 
				
			||||||
  "short": "Encode/Decode Unicode characters!",
 | 
					  "short": "Encode/Decode Unicode characters!",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This cog does not store any End User Data",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "bobloy",
 | 
					    "bobloy",
 | 
				
			||||||
    "utility",
 | 
					    "utility",
 | 
				
			||||||
 | 
				
			|||||||
@ -12,6 +12,10 @@ class Unicode(Cog):
 | 
				
			|||||||
        super().__init__()
 | 
					        super().__init__()
 | 
				
			||||||
        self.bot = bot
 | 
					        self.bot = bot
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @commands.group(name="unicode", pass_context=True)
 | 
					    @commands.group(name="unicode", pass_context=True)
 | 
				
			||||||
    async def unicode(self, ctx):
 | 
					    async def unicode(self, ctx):
 | 
				
			||||||
        """Encode/Decode a Unicode character."""
 | 
					        """Encode/Decode a Unicode character."""
 | 
				
			||||||
 | 
				
			|||||||
@ -97,7 +97,7 @@ class Game:
 | 
				
			|||||||
            await self.get_roles(ctx)
 | 
					            await self.get_roles(ctx)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if len(self.players) != len(self.roles):
 | 
					        if len(self.players) != len(self.roles):
 | 
				
			||||||
            await ctx.send("Player count does not match role count, cannot start\n"
 | 
					            await ctx.maybe_send_embed("Player count does not match role count, cannot start\n"
 | 
				
			||||||
                           "Currently **{} / {}**\n"
 | 
					                           "Currently **{} / {}**\n"
 | 
				
			||||||
                           "Use `{}ww code` to pick a new game"
 | 
					                           "Use `{}ww code` to pick a new game"
 | 
				
			||||||
                           "".format(len(self.players), len(self.roles), ctx.prefix))
 | 
					                           "".format(len(self.players), len(self.roles), ctx.prefix))
 | 
				
			||||||
@ -112,7 +112,7 @@ class Game:
 | 
				
			|||||||
                                                             reason="(BOT) Werewolf game role")
 | 
					                                                             reason="(BOT) Werewolf game role")
 | 
				
			||||||
                self.to_delete.add(self.game_role)
 | 
					                self.to_delete.add(self.game_role)
 | 
				
			||||||
            except (discord.Forbidden, discord.HTTPException):
 | 
					            except (discord.Forbidden, discord.HTTPException):
 | 
				
			||||||
                await ctx.send("Game role not configured and unable to generate one, cannot start")
 | 
					                await ctx.maybe_send_embed("Game role not configured and unable to generate one, cannot start")
 | 
				
			||||||
                self.roles = []
 | 
					                self.roles = []
 | 
				
			||||||
                return False
 | 
					                return False
 | 
				
			||||||
            try:
 | 
					            try:
 | 
				
			||||||
 | 
				
			|||||||
@ -2,16 +2,13 @@
 | 
				
			|||||||
  "author": [
 | 
					  "author": [
 | 
				
			||||||
    "Bobloy"
 | 
					    "Bobloy"
 | 
				
			||||||
  ],
 | 
					  ],
 | 
				
			||||||
  "bot_version": [
 | 
					  "min_bot_version": "3.3.0",
 | 
				
			||||||
    3,
 | 
					 | 
				
			||||||
    0,
 | 
					 | 
				
			||||||
    0
 | 
					 | 
				
			||||||
  ],
 | 
					 | 
				
			||||||
  "description": "Customizable Werewolf Game",
 | 
					  "description": "Customizable Werewolf Game",
 | 
				
			||||||
  "hidden": false,
 | 
					  "hidden": true,
 | 
				
			||||||
  "install_msg": "Thank you for installing Werewolf! Get started with `[p]load werewolf`\n Use `[p]wwset` to run inital setup",
 | 
					  "install_msg": "Thank you for installing Werewolf! Get started with `[p]load werewolf`\n Use `[p]wwset` to run inital setup",
 | 
				
			||||||
  "requirements": [],
 | 
					  "requirements": [],
 | 
				
			||||||
  "short": "Werewolf Game",
 | 
					  "short": "Werewolf Game",
 | 
				
			||||||
 | 
					  "end_user_data_statement": "This store user IDs in memory while they're actively using the cog, and store no persistent End User Data.",
 | 
				
			||||||
  "tags": [
 | 
					  "tags": [
 | 
				
			||||||
    "mafia",
 | 
					    "mafia",
 | 
				
			||||||
    "werewolf",
 | 
					    "werewolf",
 | 
				
			||||||
 | 
				
			|||||||
@ -20,6 +20,7 @@ class Werewolf(Cog):
 | 
				
			|||||||
    """
 | 
					    """
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def __init__(self, bot: Red):
 | 
					    def __init__(self, bot: Red):
 | 
				
			||||||
 | 
					        super().__init__()
 | 
				
			||||||
        self.bot = bot
 | 
					        self.bot = bot
 | 
				
			||||||
        self.config = Config.get_conf(
 | 
					        self.config = Config.get_conf(
 | 
				
			||||||
            self, identifier=87101114101119111108102, force_registration=True
 | 
					            self, identifier=87101114101119111108102, force_registration=True
 | 
				
			||||||
@ -37,6 +38,10 @@ class Werewolf(Cog):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        self.games = {}  # Active games stored here, id is per guild
 | 
					        self.games = {}  # Active games stored here, id is per guild
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    async def red_delete_data_for_user(self, **kwargs):
 | 
				
			||||||
 | 
					        """Nothing to delete"""
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def __unload(self):
 | 
					    def __unload(self):
 | 
				
			||||||
        print("Unload called")
 | 
					        print("Unload called")
 | 
				
			||||||
        for game in self.games.values():
 | 
					        for game in self.games.values():
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user