import datetime import discord from discord.ext import commands import pytz from bot.utilities.tio import Tio from bot.utilities import get_yaml_val cst = pytz.timezone("US/Central") colors = get_yaml_val("config.yml", "colors")["colors"] poplangs = get_yaml_val("bot/resources/eval/poplangs.yml", "poplangs")["poplangs"] wrapping = get_yaml_val("bot/resources/eval/wrapping.yml", "wrapping")["wrapping"] class Fun(commands.Cog): def __init__(self, bot): self.bot = bot @commands.command(aliases=["elist", "el"]) async def evallist(self, ctx: commands.Context): """Lists popular Eval languages.""" embed = discord.Embed(title="Popular Eval Languages", color=colors["green"]) for key, value in poplangs.items(): embed.add_field(name=key, value=value, inline=False) await ctx.send(embed=embed)
import random import discord from discord.ext import commands from typing import Optional from bot.constants import NECATIVE_REPLIES from bot.utilities import get_yaml_val from collections import OrderedDict COLORS = get_yaml_val("config.yml", "colors")["colors"] ZEN = [ "Elegant cattiness is better than ugly.", "Explicat is better than implicat.", "SimpleCat is better than catplex.", "Catplex is better than catplicated.", "Fat:cat2: is better than nested:cat2:.", "ᓚᘏᗢ is better than sadcat.", "Catification counts.", "Special cats aren't special enough to be better than ᓚᘏᗢ.", "Although practicatity beats purity.", "Cats should never pass silently.", "Not even when explicatly silenced.", "In the face of ᓚᘏᗢ, refuse the tempcation to guess.", "There should be one-- and always only one --supreme ᓚᘏᗢ.", "Although that may not be obvious at first unless you're ᓚᘏᗢ itself.", "NowCat:tm: is better than NeverCat:tm:.", "Although NeverCat:tm: is often better than **Right**NowCat:tm:.",
from datetime import datetime, timedelta import json import discord from discord.ext import commands, tasks from bot.constants import Channels from bot.constants import DURATION_DICT from bot.utilities import get_yaml_val GUILD_ID = get_yaml_val("config.yml", "guild.id") class Moderation(commands.Cog): """Cog for moderation commands.""" def __init__(self, bot: commands.Bot): self.bot = bot self.unmute_check.start() @commands.command(aliases=["exile"]) @commands.has_role("Cat Devs") async def pban( self, ctx: commands.Context, user: discord.User = None, *, reason: str = "Badly behaved", ): if user == self.bot.user: