Files
Syntrel/cogs/miscellaneous/silly.py

31 lines
883 B
Python
Raw Normal View History

from discord.ext import commands
def silly_command():
@commands.hybrid_command(
name="silly",
description="Sends a silly message :3",
)
async def silly(self, context, message_type: str = "regular"):
if message_type == "animated":
message = "https://yes.nighty.works/raw/LX4nqt.gif"
else:
message = ":3"
2025-11-02 23:32:52 -05:00
interaction = getattr(context, "interaction", None)
if interaction is not None:
await interaction.response.defer(ephemeral=True)
await context.channel.send(message)
try:
await interaction.delete_original_response()
except:
pass
else:
try:
await context.message.delete()
except:
pass
await context.channel.send(message)
2025-11-02 23:32:52 -05:00
return silly