From fecffeb0013a26867ed445d476b076667a3090f2 Mon Sep 17 00:00:00 2001 From: Joshua Liu Date: Sun, 9 Nov 2025 15:38:29 -0500 Subject: feat: rewrote main.py to just call bigresult.py --- .gitignore | 1 + .idea/misc.xml | 3 +++ .idea/workspace.xml | 48 +++++++++++++++++++++++++++++++++++++++----- bigresult.py | 57 ++++++++++++++++++++++++++++++++++++++++++++++------- commands/funny.py | 40 +++++++++++++++++++++++++++++++++++++ main.py | 11 +++++++++++ 6 files changed, 148 insertions(+), 12 deletions(-) create mode 100644 commands/funny.py diff --git a/.gitignore b/.gitignore index 483de3d..d688a56 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ .venv .idea +.env diff --git a/.idea/misc.xml b/.idea/misc.xml index b5789dd..46c98db 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,4 +1,7 @@ + + \ No newline at end of file diff --git a/.idea/workspace.xml b/.idea/workspace.xml index eaf4df8..ccd56e3 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -1,15 +1,35 @@ + + - + + + + + + + + - + + + + + + { + "associatedIndex": 4 +} \ No newline at end of file diff --git a/bigresult.py b/bigresult.py index 80fb67e..fbd3dd6 100644 --- a/bigresult.py +++ b/bigresult.py @@ -3,27 +3,70 @@ import dotenv from discord.ext import commands import random import threading +import time +from main import client +from commands.funny import BigCommands class BigResultPlus(commands.Bot): def __init__(self): - self.cmds = {} - - def initialize_commands(self): - return + self.snipe_active = False + pass + + @client.command(name="snipe") + async def snipe(self, ctx): + await ctx.reply("watch yourself") + self.snipe_active = True + pass + + @client.command(name="bigresult") + async def teach(self, ctx): + await ctx.reply( + "https://cdn.discordapp.com/attachments/427176475406630914/1302392181448900649/image.png?ex=6727f2bd&is=6726a13d&hm=6092f4fba06412feac26a16a6900bf6e6122d66506f60bfcc0bc7101ecede4db&") + + @client.command(name="mod") + async def mod(self, ctx): + await ctx.reply( + ">>> *pees in ur ass*\nI am a bot and this action was performed automatically. Please contact the moderators of this server if you have any questions or concerns.") + + @client.command(name="1984") + async def orwell(self, ctx): + if (random.randint(1, 5) == 2): + await ctx.reply(f">>> {ctx.author} has been warned: \n\nBad word usage") + else: + await ctx.reply( + "https://media.discordapp.net/attachments/865417026519957526/866575047459209236/video0-1-1.mov?ex=672d0e27&is=672bbca7&hm=3c80837685cb800ad817855b6463e4e1875dc009c6fc4540eff749c7387c4241&") + + @client.command(name="teachmethebigresult") + async def teachbigresult(self, ctx): + await ctx.reply("take b36 with Nick Cheng. join the 'Big Result' club") + + @client.command(name="ivotedfor") + async def voot(self, ctx): + if (random.randint(1, 2) == 2): + await ctx.reply("Donald trump sweeep") + else: + await ctx.reply("Kamala harris sweeep") async def on_ready(self): print("The big result plus bot is ready!") - for guild in self.guilds: - break await self.send_msg("Hurlo") - async def on_message(self, message): self.state = 0 roblox = discord.utils.get(self.emojis, name="roblos") await self.process_commands(message) fuckyou = message.content.lower() + channel_sent = message.channel + + if (self.snipe_active): + if (random.randint(1, 400) == 333): + saved = message.content + await channel_sent.send("BOOM :sunglasses: :fire:") + await message.delete() + time.sleep(2) + await channel_sent.send(saved) + self.snipe_active = False """ I want these statements moved into a function diff --git a/commands/funny.py b/commands/funny.py new file mode 100644 index 0000000..4766e33 --- /dev/null +++ b/commands/funny.py @@ -0,0 +1,40 @@ +from discord.ext import commands +import discord +import random +from main import client + + +class BigCommands: + @client.command(name="snipe") + async def snipe(self, ctx): + await ctx.reply("watch yourself") + pass + + @client.command(name="bigresult") + async def teach(self, ctx): + await ctx.reply( + "https://cdn.discordapp.com/attachments/427176475406630914/1302392181448900649/image.png?ex=6727f2bd&is=6726a13d&hm=6092f4fba06412feac26a16a6900bf6e6122d66506f60bfcc0bc7101ecede4db&") + + @client.command(name="mod") + async def mod(self, ctx): + await ctx.reply( + ">>> *pees in ur ass*\nI am a bot and this action was performed automatically. Please contact the modertators of this server if you have any questions or concerns.") + + @client.command(name="1984") + async def orwell(self, ctx): + if (random.randint(1, 5) == 2): + await ctx.reply(f">>> {ctx.author} has been warned: \n\nBad word usage") + else: + await ctx.reply( + "https://media.discordapp.net/attachments/865417026519957526/866575047459209236/video0-1-1.mov?ex=672d0e27&is=672bbca7&hm=3c80837685cb800ad817855b6463e4e1875dc009c6fc4540eff749c7387c4241&") + + @client.command(name="teachmethebigresult") + async def teachbigresult(self, ctx): + await ctx.reply("take b36 with Nick Cheng. join the 'Big Result' club") + + @client.command(name="ivotedfor") + async def voot(self, ctx): + if (random.randint(1, 2) == 2): + await ctx.reply("Donald trump sweeep") + else: + await ctx.reply("Kamala harris sweeep") \ No newline at end of file diff --git a/main.py b/main.py index c918f67..4c3e312 100644 --- a/main.py +++ b/main.py @@ -1,4 +1,15 @@ +import os import discord import dotenv +from bigresult import BigResultPlus +import random +from discord.ext import commands +dotenv.load_dotenv() +TOKEN = os.getenv('TOKEN') +intents = discord.Intents.all() + +client = BigResultPlus(intents=intents, command_prefix="!") # This represents our connection with Discord + +client.run(TOKEN) # This actually starts our bot -- cgit v1.2.3