AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

This commit is contained in:
nin0dev 2024-10-04 08:01:42 -04:00
parent 5d4538cd50
commit be5c916a69
Signed by: nin0
GPG key ID: 3FA8F96ABAE04214
6 changed files with 325 additions and 279 deletions

View file

@ -1,8 +1,11 @@
import asyncio
import discord
from discord import app_commands
from discord.ext import commands
import os
import util
import constants
class DerangedCommands(commands.Cog):
def __init__(self, bot: commands.Bot) -> None:
@ -14,9 +17,9 @@ class DerangedCommands(commands.Cog):
async def token(self, interaction: discord.Interaction) -> None:
embed = discord.Embed()
embed.title = "My token"
embed.description = os.getenv("TOKEN") if util.is_owner(interaction.user.id) else "[object Object]"
embed.description = constants.TOKEN if util.is_owner(interaction.user.id) else "[object Object]"
embed.color = 0x00EAFF
await interaction.response.send_message(embed=embed, ephemeral=True)
await interaction.response.send_message(embed=embed)
@app_commands.command(name="sync", description="This will sync slash commands")
@app_commands.allowed_installs(guilds=False, users=True)
@ -43,5 +46,13 @@ class DerangedCommands(commands.Cog):
async def javaer(self, interaction: discord.Interaction) -> None:
await interaction.response.send_message(content=f"https://files.catbox.moe/yeirho.mp4")
@app_commands.command(name="cook", description="Cooking show magic :meowlien:")
@app_commands.allowed_installs(guilds=False, users=True)
@app_commands.allowed_contexts(guilds=True, dms=True, private_channels=True)
async def cook(self, interaction: discord.Interaction, victim: discord.User) -> None:
await interaction.response.send_message(content=f"Cooking {victim.mention} 👨‍🍳")
await asyncio.sleep(4);
await interaction.followup.send(content=f"Cooked {victim.mention}")
async def setup(bot: commands.Bot) -> None:
await bot.add_cog(DerangedCommands(bot))

58
cogs/tags.py Normal file
View file

@ -0,0 +1,58 @@
import discord
from discord import app_commands
from discord.ext import commands
import os
import util
import constants
class Tags(commands.Cog):
def __init__(self, bot: commands.Bot) -> None:
self.bot = bot
@app_commands.command(name="tag-forwarding", description="Show a thing about forwarding")
@app_commands.allowed_installs(guilds=False, users=True)
@app_commands.allowed_contexts(guilds=True, dms=True, private_channels=True)
async def forward(self, interaction: discord.Interaction, target: discord.User = None) -> None:
await interaction.response.send_message(content=f"Hey {target.mention}, take a look at this!" if target else "",
embed=discord.Embed(
title="Forwarding",
description="If you do not have forwarding natively, without messing with Experiments, enabling it won't do anything. The experiment is server side locked.",
color=0x00AEFF
))
@app_commands.command(name="tag-dev", description="Show a thing about Vencord plugin dev")
@app_commands.allowed_installs(guilds=False, users=True)
@app_commands.allowed_contexts(guilds=True, dms=True, private_channels=True)
async def dev(self, interaction: discord.Interaction, target: discord.User = None) -> None:
await interaction.response.send_message(content=f"Hey {target.mention}, take a look at this!" if target else "",
embed=discord.Embed(
title="Plugin development",
description="Want to get started with plugin development? Some things are there to help you!\n\n**Documentation**\n- https://docs.vencord.dev\n- Just look on the Vencord repo for code\n\n**Channels**\n<#1032770730703716362>, but read <#1032770730703716362> first.",
color=0x00AEFF
))
@app_commands.command(name="tag-dev", description="Show a thing about Vencord plugin dev")
@app_commands.allowed_installs(guilds=False, users=True)
@app_commands.allowed_contexts(guilds=True, dms=True, private_channels=True)
async def dev(self, interaction: discord.Interaction, target: discord.User = None) -> None:
await interaction.response.send_message(content=f"Hey {target.mention}, take a look at this!" if target else "",
embed=discord.Embed(
title="Plugin development",
description="Want to get started with plugin development? Some things are there to help you!\n\n**Documentation**\n- https://docs.vencord.dev\n- Just look on the Vencord repo for code\n\n**Channels**\n<#1032770730703716362>, but read <#1032770730703716362> first.",
color=0x00AEFF
))
@app_commands.command(name="tag-cant-read", description="You can't read")
@app_commands.allowed_installs(guilds=False, users=True)
@app_commands.allowed_contexts(guilds=True, dms=True, private_channels=True)
async def dev2(self, interaction: discord.Interaction, target: discord.User = None) -> None:
await interaction.response.send_message(content=f"Hey {target.mention}, take a look at this!" if target else "",
embed=discord.Embed(
title="Wrong channel!",
description="Currently, you are in modmail. Your question is a support question, not a question only a staff member could answer.\n*Because you couldn't read the huge WARNING on the modmail channel, you have been banned from opening tickets. Go to <#1026515880080842772>.*",
color=0xFF8989
))
async def setup(bot: commands.Bot) -> None:
await bot.add_cog(Tags(bot))

View file

@ -1,24 +0,0 @@
import discord
from discord import app_commands
from discord.ext import commands
import os
import util
class Victimization(commands.Cog):
def __init__(self, bot: commands.Bot) -> None:
self.bot = bot
@app_commands.command(name="cook", description="Cooking show magic :meowlien:")
@app_commands.allowed_installs(guilds=False, users=True)
@app_commands.allowed_contexts(guilds=True, dms=True, private_channels=True)
async def cook(self, interaction: discord.Interaction, victim: discord.User) -> None:
embed = discord.Embed()
embed.title = "My token"
embed.description = os.getenv("TOKEN") if util.is_owner(interaction.user.id) else "[object Object]"
embed.color = 0x00EAFF
await interaction.response.send_message(embed=embed, ephemeral=True)
async def setup(bot: commands.Bot) -> None:
await bot.add_cog(Victimization(bot))

11
main.py
View file

@ -3,15 +3,15 @@ import os
from discord import app_commands
from discord.ext import commands
from cogs.deranged_commands import DerangedCommands
from cogs.victimization import Victimization
from dotenv import load_dotenv
import selfcord
#import selfcord
from cogs.tags import Tags
import constants
load_dotenv()
client = commands.Bot(intents=discord.Intents.all(), command_prefix=".")
user = selfcord.Client()
#user = selfcord.Client()
@client.event
@ -26,9 +26,10 @@ async def on_message(message):
@client.event
async def on_ready():
print("Logged in as bot")
await user.login(constants.USER_TOKEN)
print("Logged in as user")
#await user.login(constants.USER_TOKEN)
#print("Logged in as user")
await client.add_cog(DerangedCommands(client))
await client.add_cog(Tags(client))
print("Loaded all cogs")
client.run(constants.TOKEN)

View file

@ -4,4 +4,4 @@ def is_owner(id: int):
return True if id == 886685857560539176 else False
success = 0x77b255
error = 0xdd2e44
fuckoff_embed = Embed(title="No permissions", description="You can't use this.", color=error)
fuckoff_embed = Embed(title="You are an idiot", description="You can't use this.", color=error)