summaryrefslogtreecommitdiff
path: root/src/moyai_bot/bot.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/moyai_bot/bot.py')
-rw-r--r--src/moyai_bot/bot.py20
1 files changed, 19 insertions, 1 deletions
diff --git a/src/moyai_bot/bot.py b/src/moyai_bot/bot.py
index b2fceca..8ba5ac0 100644
--- a/src/moyai_bot/bot.py
+++ b/src/moyai_bot/bot.py
@@ -1,8 +1,10 @@
import discord
+from discord import app_commands
from discord.ext import commands
-from moyai_bot.lib import get_random_response
+from moyai_bot.lib import get_copypasta, get_random_response
+SERVER_ID = discord.Object(id=1055663552679137310)
intents = discord.Intents.default()
intents.message_content = True # pylint: disable=assigning-non-slot
moyai = commands.Bot(command_prefix="m!", description="moyai", intents=intents)
@@ -11,6 +13,8 @@ moyai = commands.Bot(command_prefix="m!", description="moyai", intents=intents)
@moyai.event
async def on_ready():
print(f"logged in as {moyai.user}")
+ await moyai.tree.sync(guild=SERVER_ID)
+ print("ready!")
@moyai.event
@@ -41,3 +45,17 @@ async def moyaispam(ctx: commands.Context):
for _ in range(30):
msg += str(discord.utils.get(moyai.emojis, name="moyai"))
await ctx.send(msg)
+
+
[email protected](name="copypasta",
+ description="send funni copypasta",
+ guild=SERVER_ID)
+@app_commands.choices(choices=[
+ app_commands.Choice(name="happymeal", value="happymeal"),
+ app_commands.Choice(name="ismah", value="ismah"),
+ app_commands.Choice(name="sus", value="sus"),
+ app_commands.Choice(name="ticktock", value="ticktock")
+])
+async def copypasta(i: discord.Interaction, choices: app_commands.Choice[str]):
+ msg = get_copypasta(choices.value)
+ await i.response.send_message(msg)