Update project configuration files, and API routes accordingly. Add SQLite runtime file ignores to .gitignore for better file management.
Some checks failed
CI / Bot (Python) (push) Failing after 49s
CI / Dashboard (Next.js) (push) Failing after 11s

This commit is contained in:
TheOnlyMace
2026-07-21 17:11:38 +02:00
parent 5f34db4f3b
commit b4110c3d66
297 changed files with 2657 additions and 2768 deletions

View File

@@ -1,21 +1,22 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from __future__ import annotations
from core import zyrox
from colorama import Fore, Style, init
from colorama import Fore, Style
from core import HexaHost
from utils.config import BotName
from .commands.help import Help
from .commands.general import General
@@ -25,7 +26,7 @@ from .commands.welcome import Welcomer
from .commands.fun import Fun
from .commands.Games import Games
from .commands.extra import Extra
from .commands.owner import Owner
from .commands.owner import Owner, Badges
from .commands.voice import Voice
from .commands.afk import afk
from .commands.ignore import Ignore
@@ -39,8 +40,6 @@ from .commands.blacklist import Blacklist
from .commands.block import Block
from .commands.nightmode import Nightmode
from .commands.tracking import Tracking
from .commands.owner import Badges
#from .commands.map import Map
from .commands.autoresponder import AutoResponder
from .commands.customrole import Customrole
from .commands.autorole import AutoRole
@@ -64,12 +63,12 @@ from .commands.filters import FilterCog
from .commands.owner2 import Global
from .commands.qr import QR
from .commands.vanityroles import VanityRoles
from .commands.reactionroles import ReactionRoles
from .commands.reactionroles import ReactionRoles
from .commands.messages import Messages
from .commands.fastgreet import FastGreet
from .commands.counting import Counting
from .commands.j2c import JoinToCreate
from .commands.ai import AI
from .commands.ai import AI
from .commands.dms import StaffDMCog
from .commands.booster import Booster
from .commands.leveling import Leveling
@@ -83,9 +82,7 @@ from .commands.Birthday import Birthdays
from .commands.nitro import Nitro
from .commands.image import ImageCommands
from .commands.youtube import Youtube
#____________ Events _____________
#from .events.autoblacklist import AutoBlacklist
from .events.Errors import Errors
from .events.on_guild import Guild
from .events.autorole import Autorole2
@@ -94,43 +91,37 @@ from .events.greet2 import greet
from .events.mention import Mention
from .events.react import React
from .events.autoreact import AutoReactListener
#from .events.topgg import TopGG
from .events.ai import AIResponses
from .events.ai import AIResponses
from .events.stickymessage import StickyMessageListener
########-------HELP-------########
from .zyrox.antinuke import _antinuke
from .zyrox.extra import _extra
from .zyrox.general import _general
from .zyrox.automod import _automod
from .zyrox.moderation import _moderation
#from .zyrox.inviteTracker import _inviteTracker
from .zyrox.music import _music
from .zyrox.fun import _fun
from .zyrox.games import _games
from .zyrox.ignore import _ignore
from .zyrox.server import _server
from .zyrox.voice import _voice
from .zyrox.welcome import _welcome
from .zyrox.giveaway import _giveaway
from .zyrox.ticket import _ticket
#from .axon.vanityroles import Vanityroles69999
from .zyrox.logging import _logging
from .zyrox.vanity import _vanity
from .zyrox.inviteTracker import inviteTracker
from .zyrox.counting import _Counting
from .zyrox.j2c import _J2C
from .zyrox.ai import _ai
from .zyrox.booster import __boost
from .zyrox.leveling import _leveling
from .zyrox.sticky import _sticky
from .zyrox.verify import _verify
from .zyrox.encryption import _encrypt
from .zyrox.mc import _mc
from .zyrox.joindm import _joindm
from .zyrox.birth import _birth
#########ANTINUKE#########
from .hexahost.antinuke import _antinuke
from .hexahost.extra import _extra
from .hexahost.general import _general
from .hexahost.automod import _automod
from .hexahost.moderation import _moderation
from .hexahost.music import _music
from .hexahost.fun import _fun
from .hexahost.games import _games
from .hexahost.ignore import _ignore
from .hexahost.server import _server
from .hexahost.voice import _voice
from .hexahost.welcome import _welcome
from .hexahost.giveaway import _giveaway
from .hexahost.ticket import _ticket
from .hexahost.logging import _logging
from .hexahost.vanity import _vanity
from .hexahost.inviteTracker import inviteTracker
from .hexahost.counting import _Counting
from .hexahost.j2c import _J2C
from .hexahost.ai import _ai
from .hexahost.booster import __boost
from .hexahost.leveling import _leveling
from .hexahost.sticky import _sticky
from .hexahost.verify import _verify
from .hexahost.encryption import _encrypt
from .hexahost.mc import _mc
from .hexahost.joindm import _joindm
from .hexahost.birth import _birth
from .antinuke.anti_member_update import AntiMemberUpdate
from .antinuke.antiban import AntiBan
@@ -150,15 +141,6 @@ from .antinuke.antiwebhook import AntiWebhookUpdate
from .antinuke.antiwebhookcr import AntiWebhookCreate
from .antinuke.antiwebhookdl import AntiWebhookDelete
#Extra Optional Events
#from .antinuke.antiemocr import AntiEmojiCreate
#from .antinuke.antiemodl import AntiEmojiDelete
#from .antinuke.antiemoup import AntiEmojiUpdate
#from .antinuke.antisticker import AntiSticker
#from .antinuke.antiunban import AntiUnban
############ AUTOMOD ############
from .automod.antispam import AntiSpam
from .automod.anticaps import AntiCaps
from .automod.antilink import AntiLink
@@ -166,7 +148,6 @@ from .automod.anti_invites import AntiInvite
from .automod.anti_mass_mention import AntiMassMention
from .automod.anti_emoji_spam import AntiEmojiSpam
from .moderation.ban import Ban
from .moderation.unban import Unban
from .moderation.timeout import Mute
@@ -183,194 +164,36 @@ from .moderation.moderation import Moderation
from .moderation.topcheck import TopCheck
from .moderation.snipe import Snipe
from utils.config import BotName
async def setup(bot: zyrox):
cogs_to_load = [
Help, General, Moderation, Automod, Welcomer, Fun, Games, Extra,
Voice, Owner, Customrole, afk, Embed, Media, Ignore, TicketCog, Logging,
Invcrole, Steal, Timer,
Blacklist, Block, Nightmode, Badges, Antinuke, Whitelist,
Unwhitelist, Extraowner, Blackjack, Slots, Guild, Errors, Autorole2, Autorole, greet, AutoResponder,
Mention, AutoRole, React, AntiMemberUpdate, AntiBan, AntiBotAdd,
AntiChannelCreate, AntiChannelDelete, AntiChannelUpdate, AntiEveryone, AntiGuildUpdate,
AntiIntegration, AntiKick, AntiPrune, AntiRoleCreate, AntiRoleDelete,
AntiRoleUpdate, AntiWebhookUpdate, AntiWebhookCreate,
AntiWebhookDelete, AntiSpam, AntiCaps, AntiLink, AntiInvite, AntiMassMention, Stats, Status, NoPrefix, FilterCog, AutoReaction, AutoReactListener, Ban, Unban, Mute, Unmute, Lock, Unlock, Hide, Unhide, Kick, Warn, Role, Message, Moderation, TopCheck, Snipe, Global, QR, VanityRoles, ReactionRoles, Messages, TranslateCog, FastGreet, Jail, inviteTracker,Counting,AI
]
# Load order preserved from legacy manual registration.
COG_CLASSES: tuple[type, ...] = (
Help, General, Music, Automod, Welcomer, Fun, Tracking, Games, Extra,
Voice, Owner, Customrole, afk, Embed, Media, Ignore, Invcrole, Giveaway,
Steal, Booster, Timer, Blacklist, Block, Nightmode, Badges, Antinuke,
Whitelist, Unwhitelist, Extraowner, Slots, Blackjack, Stats, Emergency,
Status, NoPrefix, FilterCog, Global, TicketCog, Logging, QR, VanityRoles,
ReactionRoles, Messages, TranslateCog, FastGreet, Jail, JoinToCreate, AI,
StaffDMCog, Leveling, StickyMessage, Verification, Minecraft, encryption,
calculator, joindm, Birthdays, Nitro, ImageCommands, Youtube,
_antinuke, _extra, _general, _automod, _moderation, _music, _fun, _games,
_ignore, _server, _voice, _welcome, _giveaway, _ticket, _logging, _vanity,
inviteTracker, Counting, _Counting, _J2C, _ai, __boost, _leveling, _sticky,
_verify, _encrypt, _mc, _joindm, _birth,
Guild, Errors, Autorole2, Autorole, greet, AutoResponder, Mention, AutoRole,
React, AutoReaction, AutoReactListener, NotifCommands, StickyMessageListener,
AIResponses,
AntiMemberUpdate, AntiBan, AntiBotAdd, AntiChannelCreate, AntiChannelDelete,
AntiChannelUpdate, AntiEveryone, AntiGuildUpdate, AntiIntegration, AntiKick,
AntiPrune, AntiRoleCreate, AntiRoleDelete, AntiRoleUpdate, AntiWebhookUpdate,
AntiWebhookCreate, AntiWebhookDelete,
AntiSpam, AntiCaps, AntiInvite, AntiLink, AntiMassMention, AntiEmojiSpam,
Ban, Unban, Mute, Unmute, Lock, Unlock, Hide, Unhide, Kick, Warn, Role,
Message, Moderation, TopCheck, Snipe,
)
await bot.add_cog(Help(bot))
await bot.add_cog(General(bot))
await bot.add_cog(Music(bot))
await bot.add_cog(Automod(bot))
await bot.add_cog(Welcomer(bot))
await bot.add_cog(Fun(bot))
await bot.add_cog(Tracking(bot))
await bot.add_cog(Games(bot))
await bot.add_cog(Extra(bot))
await bot.add_cog(Voice(bot))
await bot.add_cog(Owner(bot))
await bot.add_cog(Customrole(bot))
await bot.add_cog(afk(bot))
await bot.add_cog(Embed(bot))
await bot.add_cog(Media(bot))
await bot.add_cog(Ignore(bot))
await bot.add_cog(Invcrole(bot))
await bot.add_cog(Giveaway(bot))
await bot.add_cog(Steal(bot))
await bot.add_cog(Booster(bot))
await bot.add_cog(Timer(bot))
await bot.add_cog(Blacklist(bot))
await bot.add_cog(Block(bot))
await bot.add_cog(Nightmode(bot))
await bot.add_cog(Badges(bot))
await bot.add_cog(Antinuke(bot))
await bot.add_cog(Whitelist(bot))
await bot.add_cog(Unwhitelist(bot))
await bot.add_cog(Extraowner(bot))
await bot.add_cog(Slots(bot))
await bot.add_cog(Blackjack(bot))
await bot.add_cog(Stats(bot))
await bot.add_cog(Emergency(bot))
await bot.add_cog(Status(bot))
await bot.add_cog(NoPrefix(bot))
await bot.add_cog(FilterCog(bot))
await bot.add_cog(Global(bot))
# await bot.add_cog(Map(bot))
await bot.add_cog(TicketCog(bot))
await bot.add_cog(Logging(bot))
await bot.add_cog(QR(bot))
await bot.add_cog(VanityRoles(bot))
await bot.add_cog(ReactionRoles(bot))
await bot.add_cog(Messages(bot))
await bot.add_cog(TranslateCog(bot))
await bot.add_cog(FastGreet(bot))
await bot.add_cog(Jail(bot))
await bot.add_cog(JoinToCreate(bot))
await bot.add_cog(AI(bot))
await bot.add_cog(StaffDMCog(bot))
await bot.add_cog(Leveling(bot))
await bot.add_cog(StickyMessage(bot))
await bot.add_cog(Verification(bot))
await bot.add_cog(Minecraft(bot))
await bot.add_cog(encryption(bot))
await bot.add_cog(calculator(bot))
await bot.add_cog(joindm(bot))
await bot.add_cog(Birthdays(bot))
await bot.add_cog(Nitro(bot))
await bot.add_cog(ImageCommands(bot))
await bot.add_cog(Youtube(bot))
async def setup(bot: HexaHost) -> None:
for cog_cls in COG_CLASSES:
await bot.add_cog(cog_cls(bot))
print(Fore.RED + Style.BRIGHT + f"Loaded cog: {cog_cls.__name__}")
await bot.add_cog(_antinuke(bot))
await bot.add_cog(_extra(bot))
await bot.add_cog(_general(bot))
await bot.add_cog(_automod(bot))
await bot.add_cog(_moderation(bot))
await bot.add_cog(_music(bot))
await bot.add_cog(_fun(bot))
await bot.add_cog(_games(bot))
await bot.add_cog(_ignore(bot))
await bot.add_cog(_server(bot))
await bot.add_cog(_voice(bot))
await bot.add_cog(_welcome(bot))
await bot.add_cog(_giveaway(bot))
await bot.add_cog(_ticket(bot))
await bot.add_cog(_logging(bot))
await bot.add_cog(_vanity(bot))
await bot.add_cog(inviteTracker(bot))
await bot.add_cog(Counting(bot))
await bot.add_cog(_Counting(bot))
await bot.add_cog(_J2C(bot))
await bot.add_cog(_ai(bot))
await bot.add_cog(__boost(bot))
await bot.add_cog(_leveling(bot))
await bot.add_cog(_sticky(bot))
await bot.add_cog(_verify(bot))
await bot.add_cog(_encrypt(bot))
await bot.add_cog(_mc(bot))
await bot.add_cog(_joindm(bot))
await bot.add_cog(_birth(bot))
#await bot.add_cog(AutoBlacklist(bot))
await bot.add_cog(Guild(bot))
await bot.add_cog(Errors(bot))
await bot.add_cog(Autorole2(bot))
await bot.add_cog(Autorole(bot))
await bot.add_cog(greet(bot))
await bot.add_cog(AutoResponder(bot))
await bot.add_cog(Mention(bot))
await bot.add_cog(AutoRole(bot))
await bot.add_cog(React(bot))
await bot.add_cog(AutoReaction(bot))
await bot.add_cog(AutoReactListener(bot))
await bot.add_cog(NotifCommands(bot))
await bot.add_cog(StickyMessageListener(bot))
await bot.add_cog(AIResponses(bot))
await bot.add_cog(AntiMemberUpdate(bot))
await bot.add_cog(AntiBan(bot))
await bot.add_cog(AntiBotAdd(bot))
await bot.add_cog(AntiChannelCreate(bot))
await bot.add_cog(AntiChannelDelete(bot))
await bot.add_cog(AntiChannelUpdate(bot))
await bot.add_cog(AntiEveryone(bot))
await bot.add_cog(AntiGuildUpdate(bot))
await bot.add_cog(AntiIntegration(bot))
await bot.add_cog(AntiKick(bot))
await bot.add_cog(AntiPrune(bot))
await bot.add_cog(AntiRoleCreate(bot))
await bot.add_cog(AntiRoleDelete(bot))
await bot.add_cog(AntiRoleUpdate(bot))
await bot.add_cog(AntiWebhookUpdate(bot))
await bot.add_cog(AntiWebhookCreate(bot))
await bot.add_cog(AntiWebhookDelete(bot))
#Extra Optional Events
#await bot.add_cog(AntiEmojiCreate(bot))
#await bot.add_cog(AntiEmojiDelete(bot))
#await bot.add_cog(AntiEmojiUpdate(bot))
#await bot.add_cog(AntiSticker(bot))
#await bot.add_cog(AntiUnban(bot))
await bot.add_cog(AntiSpam(bot))
await bot.add_cog(AntiCaps(bot))
await bot.add_cog(AntiInvite(bot))
await bot.add_cog(AntiLink(bot))
await bot.add_cog(AntiMassMention(bot))
await bot.add_cog(AntiEmojiSpam(bot))
await bot.add_cog(Ban(bot))
await bot.add_cog(Unban(bot))
await bot.add_cog(Mute(bot))
await bot.add_cog(Unmute(bot))
await bot.add_cog(Lock(bot))
await bot.add_cog(Unlock(bot))
await bot.add_cog(Hide(bot))
await bot.add_cog(Unhide(bot))
await bot.add_cog(Kick(bot))
await bot.add_cog(Warn(bot))
await bot.add_cog(Role(bot))
await bot.add_cog(Message(bot))
await bot.add_cog(Moderation(bot))
await bot.add_cog(TopCheck(bot))
await bot.add_cog(Snipe(bot))
for cog in cogs_to_load:
print(Fore.RED + Style.BRIGHT + f"Loaded cog: {cog.__name__}")
print(Fore.RED + Style.BRIGHT + f"All {BotName} Cogs loaded successfully.")
print(Fore.RED + Style.BRIGHT + f"All {BotName} Cogs loaded successfully.")

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -61,7 +61,7 @@ class AntiIntegration(commands.Cog):
return True
async def is_blacklisted_guild(self, guild_id):
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
cursor = await block_db.execute("SELECT 1 FROM guild_blacklist WHERE guild_id = ?", (str(guild_id),))
return await cursor.fetchone() is not None
@@ -70,7 +70,7 @@ class AntiIntegration(commands.Cog):
if await self.is_blacklisted_guild(guild.id):
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
@@ -89,7 +89,7 @@ class AntiIntegration(commands.Cog):
if executor.id in {guild.owner_id, self.bot.user.id}:
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT owner_id FROM extraowners WHERE guild_id = ? AND owner_id = ?",
(guild.id, executor.id)) as cursor:
extraowner_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -26,7 +26,7 @@ class AntiMemberUpdate(commands.Cog):
self.cooldowns = {}
async def is_blacklisted_guild(self, guild_id):
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
cursor = await block_db.execute("SELECT 1 FROM guild_blacklist WHERE guild_id = ?", (str(guild_id),))
return await cursor.fetchone() is not None
@@ -71,7 +71,7 @@ class AntiMemberUpdate(commands.Cog):
if await self.is_blacklisted_guild(guild.id):
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
if not antinuke_status or not antinuke_status[0]:
@@ -88,7 +88,7 @@ class AntiMemberUpdate(commands.Cog):
if executor.id in {guild.owner_id, self.bot.user.id}:
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT owner_id FROM extraowners WHERE guild_id = ? AND owner_id = ?",
(guild.id, executor.id)) as cursor:
extra_owner_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -59,7 +59,7 @@ class AntiBan(commands.Cog):
@commands.Cog.listener()
async def on_member_ban(self, guild, user):
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
if not antinuke_status or not antinuke_status[0]:

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -63,7 +63,7 @@ class AntiBotAdd(commands.Cog):
return
guild = member.guild
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -89,7 +89,7 @@ class AntiChannelCreate(commands.Cog):
async def on_guild_channel_create(self, channel):
guild = channel.guild
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
if not antinuke_status or not antinuke_status[0]:

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -60,7 +60,7 @@ class AntiChannelDelete(commands.Cog):
@commands.Cog.listener()
async def on_guild_channel_delete(self, channel):
guild = channel.guild
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
if not antinuke_status or not antinuke_status[0]:

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -60,7 +60,7 @@ class AntiChannelUpdate(commands.Cog):
@commands.Cog.listener()
async def on_guild_channel_update(self, before, after):
guild = before.guild
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
if not antinuke_status or not antinuke_status[0]:

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -44,7 +44,7 @@ class AntiEveryone(commands.Cog):
guild = message.guild
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -61,7 +61,7 @@ class AntiGuildUpdate(commands.Cog):
return True
async def is_blacklisted_guild(self, guild_id):
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
cursor = await block_db.execute("SELECT 1 FROM guild_blacklist WHERE guild_id = ?", (str(guild_id),))
return await cursor.fetchone() is not None
@@ -71,7 +71,7 @@ class AntiGuildUpdate(commands.Cog):
if await self.is_blacklisted_guild(guild.id):
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
@@ -93,7 +93,7 @@ class AntiGuildUpdate(commands.Cog):
if executor.id in {guild.owner_id, self.bot.user.id}:
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT serverup FROM whitelisted_users WHERE guild_id = ? AND user_id = ?",
(guild.id, executor.id)) as cursor:
whitelist_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -26,7 +26,7 @@ class AntiKick(commands.Cog):
self.cooldowns = {}
async def is_blacklisted_guild(self, guild_id):
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
cursor = await block_db.execute("SELECT 1 FROM guild_blacklist WHERE guild_id = ?", (str(guild_id),))
return await cursor.fetchone() is not None
@@ -70,7 +70,7 @@ class AntiKick(commands.Cog):
if await self.is_blacklisted_guild(member.guild.id):
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (member.guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
if not antinuke_status or not antinuke_status[0]:
@@ -87,7 +87,7 @@ class AntiKick(commands.Cog):
if executor.id in {member.guild.owner_id, self.bot.user.id}:
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT owner_id FROM extraowners WHERE guild_id = ? AND owner_id = ?",
(member.guild.id, executor.id)) as cursor:
extraowner_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -42,7 +42,7 @@ class AntiPrune(commands.Cog):
@commands.Cog.listener()
async def on_member_remove(self, member):
guild = member.guild
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -26,7 +26,7 @@ class AntiRoleCreate(commands.Cog):
self.cooldowns = {}
async def is_blacklisted_guild(self, guild_id):
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
cursor = await block_db.execute("SELECT 1 FROM guild_blacklist WHERE guild_id = ?", (str(guild_id),))
return await cursor.fetchone() is not None
@@ -71,7 +71,7 @@ class AntiRoleCreate(commands.Cog):
if await self.is_blacklisted_guild(guild.id):
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
if not antinuke_status or not antinuke_status[0]:
@@ -89,7 +89,7 @@ class AntiRoleCreate(commands.Cog):
if executor.id in {guild.owner_id, self.bot.user.id}:
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT owner_id FROM extraowners WHERE guild_id = ? AND owner_id = ?",
(guild.id, executor.id)) as cursor:
extra_owner_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -26,7 +26,7 @@ class AntiRoleDelete(commands.Cog):
self.cooldowns = {}
async def is_blacklisted_guild(self, guild_id):
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
cursor = await block_db.execute("SELECT 1 FROM guild_blacklist WHERE guild_id = ?", (str(guild_id),))
return await cursor.fetchone() is not None
@@ -71,7 +71,7 @@ class AntiRoleDelete(commands.Cog):
if await self.is_blacklisted_guild(guild.id):
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
if not antinuke_status or not antinuke_status[0]:
@@ -89,7 +89,7 @@ class AntiRoleDelete(commands.Cog):
if executor.id in {guild.owner_id, self.bot.user.id}:
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT owner_id FROM extraowners WHERE guild_id = ? AND owner_id = ?",
(guild.id, executor.id)) as cursor:
extra_owner_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -26,7 +26,7 @@ class AntiRoleUpdate(commands.Cog):
self.cooldowns = {}
async def is_blacklisted_guild(self, guild_id):
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
cursor = await block_db.execute("SELECT 1 FROM guild_blacklist WHERE guild_id = ?", (str(guild_id),))
return await cursor.fetchone() is not None
@@ -71,7 +71,7 @@ class AntiRoleUpdate(commands.Cog):
if await self.is_blacklisted_guild(guild.id):
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
if not antinuke_status or not antinuke_status[0]:
@@ -89,7 +89,7 @@ class AntiRoleUpdate(commands.Cog):
if executor.id in {guild.owner_id, self.bot.user.id}:
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT rlup FROM whitelisted_users WHERE guild_id = ? AND user_id = ?",
(guild.id, executor.id)) as cursor:
whitelist_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -58,7 +58,7 @@ class AntiWebhookUpdate(commands.Cog):
return True
async def is_blacklisted_guild(self, guild_id):
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
cursor = await block_db.execute("SELECT 1 FROM guild_blacklist WHERE guild_id = ?", (str(guild_id),))
return await cursor.fetchone() is not None
@@ -68,7 +68,7 @@ class AntiWebhookUpdate(commands.Cog):
if await self.is_blacklisted_guild(guild.id):
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
@@ -87,7 +87,7 @@ class AntiWebhookUpdate(commands.Cog):
if executor.id in {guild.owner_id, self.bot.user.id}:
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT mngweb FROM whitelisted_users WHERE guild_id = ? AND user_id = ?",
(guild.id, executor.id)) as cursor:
whitelist_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -58,7 +58,7 @@ class AntiWebhookCreate(commands.Cog):
return True
async def is_blacklisted_guild(self, guild_id):
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
cursor = await block_db.execute("SELECT 1 FROM guild_blacklist WHERE guild_id = ?", (str(guild_id),))
return await cursor.fetchone() is not None
@@ -68,7 +68,7 @@ class AntiWebhookCreate(commands.Cog):
if await self.is_blacklisted_guild(guild.id):
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
@@ -87,7 +87,7 @@ class AntiWebhookCreate(commands.Cog):
if executor.id in {guild.owner_id, self.bot.user.id}:
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT mngweb FROM whitelisted_users WHERE guild_id = ? AND user_id = ?",
(guild.id, executor.id)) as cursor:
whitelist_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -58,7 +58,7 @@ class AntiWebhookDelete(commands.Cog):
return True
async def is_blacklisted_guild(self, guild_id):
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
cursor = await block_db.execute("SELECT 1 FROM guild_blacklist WHERE guild_id = ?", (str(guild_id),))
return await cursor.fetchone() is not None
@@ -68,7 +68,7 @@ class AntiWebhookDelete(commands.Cog):
if await self.is_blacklisted_guild(guild.id):
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()
@@ -87,7 +87,7 @@ class AntiWebhookDelete(commands.Cog):
if executor.id in {guild.owner_id, self.bot.user.id}:
return
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT mngweb FROM whitelisted_users WHERE guild_id = ? AND user_id = ?",
(guild.id, executor.id)) as cursor:
whitelist_status = await cursor.fetchone()

View File

@@ -1,3 +1,4 @@
from utils.db_paths import db_path
import discord
from discord.ext import commands
import aiosqlite
@@ -29,7 +30,7 @@ class AntiEmojiCreate(commands.Cog):
@commands.Cog.listener()
async def on_guild_emojis_update(self, guild, before, after):
if len(after) > len(before):
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()

View File

@@ -1,3 +1,4 @@
from utils.db_paths import db_path
import discord
from discord.ext import commands
import aiosqlite
@@ -29,7 +30,7 @@ class AntiEmojiDelete(commands.Cog):
@commands.Cog.listener()
async def on_guild_emojis_update(self, guild, before, after):
if len(after) < len(before):
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()

View File

@@ -1,3 +1,4 @@
from utils.db_paths import db_path
import discord
from discord.ext import commands
import aiosqlite
@@ -29,7 +30,7 @@ class AntiEmojiUpdate(commands.Cog):
@commands.Cog.listener()
async def on_guild_emojis_update(self, guild, before, after):
if len(after) == len(before): # An emoji was updated
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()

View File

@@ -1,3 +1,4 @@
from utils.db_paths import db_path
import discord
from discord.ext import commands
from datetime import timedelta, datetime
@@ -34,7 +35,7 @@ class AntiSticker(commands.Cog):
else:
action = discord.AuditLogAction.sticker_update
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()

View File

@@ -1,3 +1,4 @@
from utils.db_paths import db_path
import discord
from discord.ext import commands
import aiosqlite
@@ -26,7 +27,7 @@ class AntiUnban(commands.Cog):
@commands.Cog.listener()
async def on_member_unban(self, guild, user):
async with aiosqlite.connect('db/anti.db') as db:
async with aiosqlite.connect(db_path('anti.db')) as db:
async with db.execute("SELECT status FROM antinuke WHERE guild_id = ?", (guild.id,)) as cursor:
antinuke_status = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import TICK
@@ -26,35 +26,35 @@ class AntiEmojiSpam(commands.Cog):
self.emoji_threshold = 5
async def is_automod_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT enabled FROM automod WHERE guild_id = ?", (guild_id,))
result = await cursor.fetchone()
return result is not None and result[0] == 1
async def is_anti_emoji_spam_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti emoji spam'", (guild_id,))
result = await cursor.fetchone()
return result is not None
async def get_ignored_channels(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'channel'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_ignored_roles(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'role'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_punishment(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti emoji spam'", (guild_id,))
result = await cursor.fetchone()
return result[0] if result else None
async def log_action(self, guild, user, channel, action, reason):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT log_channel FROM automod_logging WHERE guild_id = ?", (guild.id,))
log_channel_id = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import TICK
@@ -26,35 +26,35 @@ class AntiInvite(commands.Cog):
self.invite_pattern = re.compile(r'(https?://)?(www\.)?(discord\.gg|discordapp\.com/invite|discord\.com/invite)/\S+')
async def is_automod_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT enabled FROM automod WHERE guild_id = ?", (guild_id,))
result = await cursor.fetchone()
return result is not None and result[0] == 1
async def is_anti_invites_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti invites'", (guild_id,))
result = await cursor.fetchone()
return result is not None
async def get_ignored_channels(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'channel'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_ignored_roles(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'role'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_punishment(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti invites'", (guild_id,))
result = await cursor.fetchone()
return result[0] if result else None
async def log_action(self, guild, user, channel, action, reason):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT log_channel FROM automod_logging WHERE guild_id = ?", (guild.id,))
log_channel_id = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import TICK
@@ -25,36 +25,36 @@ class AntiMassMention(commands.Cog):
self.mass_mention_threshold = 5
async def is_automod_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT enabled FROM automod WHERE guild_id = ?", (guild_id,))
result = await cursor.fetchone()
return result is not None and result[0] == 1
async def is_anti_mass_mention_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti mass mention'", (guild_id,))
result = await cursor.fetchone()
return result is not None
async def get_ignored_channels(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'channel'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_ignored_roles(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'role'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_punishment(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti mass mention'", (guild_id,))
result = await cursor.fetchone()
return result[0] if result else None
async def log_action(self, guild, user, channel, action, reason):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT log_channel FROM automod_logging WHERE guild_id = ?", (guild.id,))
log_channel_id = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import TICK
@@ -26,35 +26,35 @@ class AntiCaps(commands.Cog):
self.mute_duration = 2 * 60
async def is_automod_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT enabled FROM automod WHERE guild_id = ?", (guild_id,))
result = await cursor.fetchone()
return result is not None and result[0] == 1
async def is_anti_caps_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti caps'", (guild_id,))
result = await cursor.fetchone()
return result is not None
async def get_ignored_channels(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'channel'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_ignored_roles(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'role'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_punishment(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti caps'", (guild_id,))
result = await cursor.fetchone()
return result[0] if result else None
async def log_action(self, guild, user, channel, action, reason):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT log_channel FROM automod_logging WHERE guild_id = ?", (guild.id,))
log_channel_id = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import TICK
@@ -29,35 +29,35 @@ class AntiLink(commands.Cog):
self.spotify_pattern = re.compile(r'^https://open\.spotify\.com/track/\S+')
async def is_automod_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT enabled FROM automod WHERE guild_id = ?", (guild_id,))
result = await cursor.fetchone()
return result is not None and result[0] == 1
async def is_anti_link_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti link'", (guild_id,))
result = await cursor.fetchone()
return result is not None
async def get_ignored_channels(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'channel'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_ignored_roles(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'role'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_punishment(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti link'", (guild_id,))
result = await cursor.fetchone()
return result[0] if result else None
async def log_action(self, guild, user, channel, action, reason):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT log_channel FROM automod_logging WHERE guild_id = ?", (guild.id,))
log_channel_id = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import TICK
@@ -27,36 +27,36 @@ class AntiSpam(commands.Cog):
self.recent_messages = {}
async def is_automod_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT enabled FROM automod WHERE guild_id = ?", (guild_id,))
result = await cursor.fetchone()
return result is not None and result[0] == 1
async def is_anti_spam_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti spam'", (guild_id,))
result = await cursor.fetchone()
return result is not None
async def get_ignored_channels(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'channel'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_ignored_roles(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'role'", (guild_id,))
return [row[0] for row in await cursor.fetchall()]
async def get_punishment(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti spam'", (guild_id,))
result = await cursor.fetchone()
return result[0] if result else None
async def log_action(self, guild, user, channel, action, reason):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT log_channel FROM automod_logging WHERE guild_id = ?", (guild.id,))
log_channel_id = await cursor.fetchone()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import jsondb_path
import discord
from discord.ext import commands, tasks
@@ -56,7 +56,7 @@ class Birthdays(commands.Cog):
@commands.has_permissions(administrator=True)
@commands.guild_only()
async def birthday_setup(self, ctx: commands.Context, channel: discord.TextChannel, role: discord.Role):
db = read_db('jsondb/birthday_logs.json')
db = read_db(jsondb_path('birthday_logs.json'))
guild_id = str(ctx.guild.id)
if guild_id not in db:
@@ -65,7 +65,7 @@ class Birthdays(commands.Cog):
db[guild_id]["birthday_channel_id"] = channel.id
db[guild_id]["birthday_role_id"] = role.id
write_db('jsondb/birthday_logs.json', db)
write_db(jsondb_path('birthday_logs.json'), db)
await ctx.send(view=CV2("Birthday Setup", f"Birthday log channel set to {channel.mention} and birthday role set to {role.mention}."))
@@ -104,9 +104,9 @@ class Birthdays(commands.Cog):
return
date = f"{month}-{day}-{year}"
db = read_db('jsondb/birthdays.json')
db = read_db(jsondb_path('birthdays.json'))
db[str(ctx.author.id)] = date
write_db('jsondb/birthdays.json', db)
write_db(jsondb_path('birthdays.json'), db)
await ctx.send(view=CV2("Success", f"Your birthday has been set to {date}."))
except asyncio.TimeoutError:
@@ -117,11 +117,11 @@ class Birthdays(commands.Cog):
help="Remove your birthday.")
@commands.guild_only()
async def remove_birthday(self, ctx: commands.Context):
db = read_db('jsondb/birthdays.json')
db = read_db(jsondb_path('birthdays.json'))
if str(ctx.author.id) in db:
del db[str(ctx.author.id)]
write_db('jsondb/birthdays.json', db)
write_db(jsondb_path('birthdays.json'), db)
await ctx.send(view=CV2("Success", "Your birthday has been removed."))
else:
await ctx.send(view=CV2("Error", "You have no birthday set."))
@@ -133,7 +133,7 @@ class Birthdays(commands.Cog):
async def list_birthdays(self, ctx: commands.Context):
now = datetime.datetime.now()
today_date = now.strftime("%m-%d")
db = read_db('jsondb/birthdays.json')
db = read_db(jsondb_path('birthdays.json'))
members_with_birthday = [ctx.guild.get_member(int(user_id)) for user_id, date in db.items() if date.startswith(today_date)]
@@ -148,7 +148,7 @@ class Birthdays(commands.Cog):
help="Check your birthday.")
@commands.guild_only()
async def check_birthday(self, ctx: commands.Context):
db = read_db('jsondb/birthdays.json')
db = read_db(jsondb_path('birthdays.json'))
if str(ctx.author.id) in db:
date = db[str(ctx.author.id)]
@@ -160,8 +160,8 @@ class Birthdays(commands.Cog):
async def check_birthdays(self):
now = datetime.datetime.now()
today_date = now.strftime("%m-%d")
db = read_db('jsondb/birthdays.json')
guild_settings = read_db('jsondb/birthday_logs.json')
db = read_db(jsondb_path('birthdays.json'))
guild_settings = read_db(jsondb_path('birthday_logs.json'))
for user_id, birthday in db.items():
if birthday.startswith(today_date):

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,21 +1,20 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
import discord
from discord.ext import commands
import os
from core import Cog, zyrox, Context
from core import Cog, HexaHost, Context
import games as games
from utils.Tools import *
from utils.cv2 import CV2
@@ -26,9 +25,9 @@ import asyncio
class Games(Cog):
"""Zyrox Games"""
"""HexaHost Games"""
def __init__(self, client: zyrox):
def __init__(self, client: HexaHost):
self.client = client

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -23,7 +23,7 @@ from utils.config import *
class Invcrole(commands.Cog):
def __init__(self, bot):
self.bot = bot
self.db_path = 'db/invc.db'
self.db_path = db_path('invc.db')
self.bot.loop.create_task(self.create_table())
async def create_table(self):

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
import aiosqlite
@@ -27,7 +27,7 @@ class Media(commands.Cog):
async def set_db(self):
async with aiosqlite.connect('db/media.db') as db:
async with aiosqlite.connect(db_path('media.db')) as db:
await db.execute('''
CREATE TABLE IF NOT EXISTS media_channels (
guild_id INTEGER PRIMARY KEY,
@@ -62,7 +62,7 @@ class Media(commands.Cog):
@commands.cooldown(1, 3, commands.BucketType.user)
@commands.has_permissions(administrator=True)
async def setup(self, ctx, *, channel: discord.TextChannel):
async with aiosqlite.connect('db/media.db') as db:
async with aiosqlite.connect(db_path('media.db')) as db:
async with db.execute('SELECT channel_id FROM media_channels WHERE guild_id = ?', (ctx.guild.id,)) as cursor:
result = await cursor.fetchone()
if result:
@@ -80,7 +80,7 @@ class Media(commands.Cog):
@commands.cooldown(1, 3, commands.BucketType.user)
@commands.has_permissions(administrator=True)
async def remove(self, ctx):
async with aiosqlite.connect('db/media.db') as db:
async with aiosqlite.connect(db_path('media.db')) as db:
async with db.execute('SELECT channel_id FROM media_channels WHERE guild_id = ?', (ctx.guild.id,)) as cursor:
result = await cursor.fetchone()
if not result:
@@ -98,7 +98,7 @@ class Media(commands.Cog):
@commands.cooldown(1, 3, commands.BucketType.user)
@commands.has_permissions(administrator=True)
async def config(self, ctx):
async with aiosqlite.connect('db/media.db') as db:
async with aiosqlite.connect(db_path('media.db')) as db:
async with db.execute('SELECT channel_id FROM media_channels WHERE guild_id = ?', (ctx.guild.id,)) as cursor:
result = await cursor.fetchone()
if not result:
@@ -124,7 +124,7 @@ class Media(commands.Cog):
@commands.cooldown(1, 3, commands.BucketType.user)
@commands.has_permissions(administrator=True)
async def bypass_add(self, ctx, user: discord.Member):
async with aiosqlite.connect('db/media.db') as db:
async with aiosqlite.connect(db_path('media.db')) as db:
async with db.execute('SELECT COUNT(*) FROM media_bypass WHERE guild_id = ?', (ctx.guild.id,)) as cursor:
count = await cursor.fetchone()
if count[0] >= 25:
@@ -148,7 +148,7 @@ class Media(commands.Cog):
@commands.cooldown(1, 3, commands.BucketType.user)
@commands.has_permissions(administrator=True)
async def bypass_remove(self, ctx, user: discord.Member):
async with aiosqlite.connect('db/media.db') as db:
async with aiosqlite.connect(db_path('media.db')) as db:
async with db.execute('SELECT 1 FROM media_bypass WHERE guild_id = ? AND user_id = ?', (ctx.guild.id, user.id)) as cursor:
result = await cursor.fetchone()
if not result:
@@ -166,7 +166,7 @@ class Media(commands.Cog):
@commands.cooldown(1, 3, commands.BucketType.user)
@commands.has_permissions(administrator=True)
async def bypass_show(self, ctx):
async with aiosqlite.connect('db/media.db') as db:
async with aiosqlite.connect(db_path('media.db')) as db:
async with db.execute('SELECT user_id FROM media_bypass WHERE guild_id = ?', (ctx.guild.id,)) as cursor:
result = await cursor.fetchall()
if not result:
@@ -183,16 +183,16 @@ class Media(commands.Cog):
if message.author.bot:
return
async with aiosqlite.connect('db/media.db') as db:
async with aiosqlite.connect(db_path('media.db')) as db:
async with db.execute('SELECT channel_id FROM media_channels WHERE guild_id = ?', (message.guild.id,)) as cursor:
media_channel = await cursor.fetchone()
if media_channel and message.channel.id == media_channel[0]:
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
async with block_db.execute('SELECT 1 FROM user_blacklist WHERE user_id = ?', (message.author.id,)) as cursor:
blacklisted = await cursor.fetchone()
async with aiosqlite.connect('db/media.db') as db:
async with aiosqlite.connect(db_path('media.db')) as db:
async with db.execute('SELECT 1 FROM media_bypass WHERE guild_id = ? AND user_id = ?', (message.guild.id, message.author.id)) as cursor:
bypassed = await cursor.fetchone()
@@ -221,7 +221,7 @@ class Media(commands.Cog):
]
if len(self.infractions[message.author.id]) >= 5:
async with aiosqlite.connect('db/block.db') as block_db:
async with aiosqlite.connect(db_path('block.db')) as block_db:
await block_db.execute('INSERT OR IGNORE INTO user_blacklist (user_id) VALUES (?)', (message.author.id,))
await block_db.commit()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -24,7 +24,7 @@ from utils.cv2 import CV2, build_container
from utils.emoji import TICK, MENTION, SEED, TIME
from utils.config import *
DB_PATH = "db/afk.db"
DB_PATH = db_path("afk.db")
THEME_COLOR = 0xFF0000
FOOTER_TEXT = f"Developed by {BRAND_NAME}"

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import os
import discord
@@ -323,7 +323,7 @@ class AI (commands .Cog ):
import os
db_path ="db/ai_data.db"
db_path =db_path("ai_data.db")
if os .path .exists (db_path ):
try :
@@ -401,7 +401,7 @@ class AI (commands .Cog ):
import aiosqlite
import os
db_path ="db/ai_data.db"
db_path =db_path("ai_data.db")
if not os .path .exists (db_path ):
logger .info ("AI database doesn't exist, will be created on first use")
return
@@ -590,7 +590,7 @@ class AI (commands .Cog ):
system_context .append ({
"role":"system",
"content":"You are a Discord bot with many features including moderation, entertainment, music, games, AI capabilities, and utilities. Support server: https://discord.gg/codexdev"
"content":"You are a Discord bot with many features including moderation, entertainment, music, games, AI capabilities, and utilities. Support server: https://discord.gg/hexahost"
})
else :
@@ -602,7 +602,7 @@ You have a caring, helpful personality and can remember conversations with users
Be natural, conversational, and genuine in your responses. Don't be overly formal or robotic. Use the conversation history to provide personalized responses that feel like talking to a real friend who happens to be very knowledgeable and helpful.
Support server: https://discord.gg/codexdev"""
Support server: https://discord.gg/hexahost"""
})

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, MANAGER, REDDOT, TICK
@@ -31,7 +31,7 @@ class Unwhitelist(commands.Cog):
#@commands.Cog.listener()
async def initialize_db(self):
self.db = await aiosqlite.connect('db/anti.db')
self.db = await aiosqlite.connect(db_path('anti.db'))
@commands.hybrid_command(name='unwhitelist', aliases=['unwl'], help="Unwhitelist a user from antinuke")
@commands.has_permissions(administrator=True)

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import ARROWRED, CROSS, DISABLE, ENABLE, MANAGER, TICK
@@ -32,7 +32,7 @@ class Whitelist(commands.Cog):
#@commands.Cog.listener()
async def initialize_db(self):
self.db = await aiosqlite.connect('db/anti.db')
self.db = await aiosqlite.connect(db_path('anti.db'))
await self.db.execute('''
CREATE TABLE IF NOT EXISTS whitelisted_users (
guild_id INTEGER,

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, EMOTE, TICK, ZSAFE, ZSETTINGS
@@ -31,7 +31,7 @@ class Antinuke(commands.Cog):
self.bot.loop.create_task(self.initialize_db())
async def initialize_db(self):
self.db = await aiosqlite.connect('db/anti.db')
self.db = await aiosqlite.connect(db_path('anti.db'))
await self.db.execute('''
CREATE TABLE IF NOT EXISTS antinuke (
guild_id INTEGER PRIMARY KEY,

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, DISABLE, ENABLE, TICK, TICK_ALT
@@ -113,7 +113,7 @@ class Automod(commands.Cog):
self.bot.loop.create_task(self.init_db())
async def get_exempt_roles_channels(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
roles_cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'role'", (guild_id,))
channels_cursor = await db.execute("SELECT id FROM automod_ignored WHERE guild_id = ? AND type = 'channel'", (guild_id,))
@@ -124,18 +124,18 @@ class Automod(commands.Cog):
async def is_automod_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT enabled FROM automod WHERE guild_id = ?", (guild_id,))
result = await cursor.fetchone()
return result is not None and result[0] == 1
async def update_punishments(self, guild_id, event, punishment):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
await db.execute("INSERT OR REPLACE INTO automod_punishments (guild_id, event, punishment) VALUES (?, ?, ?)", (guild_id, event, punishment))
await db.commit()
async def get_current_punishments(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
async with db.execute(
"SELECT event, punishment FROM automod_punishments WHERE guild_id = ? AND event != 'Anti NSFW link'",
(guild_id,)
@@ -143,7 +143,7 @@ class Automod(commands.Cog):
return await cursor.fetchall()
async def is_anti_nsfw_enabled(self, guild_id):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT punishment FROM automod_punishments WHERE guild_id = ? AND event = 'Anti NSFW link'", (guild_id,))
result = await cursor.fetchone()
return result is not None
@@ -151,7 +151,7 @@ class Automod(commands.Cog):
async def init_db(self):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
await db.execute("""
CREATE TABLE IF NOT EXISTS automod (
guild_id INTEGER PRIMARY KEY,
@@ -271,7 +271,7 @@ class Automod(commands.Cog):
async def enable_automod(self, ctx, guild_id, selected_events, interaction):
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
await db.execute("INSERT OR REPLACE INTO automod (guild_id, enabled) VALUES (?, 1)", (guild_id,))
for event in selected_events:
await db.execute("INSERT OR REPLACE INTO automod_punishments (guild_id, event, punishment) VALUES (?, ?, ?)", (guild_id, event, self.default_punishment))
@@ -328,7 +328,7 @@ class Automod(commands.Cog):
log_channel = await interaction.guild.create_text_channel(f"{BRAND_NAME.lower()}-automod", overwrites=overwrites)
guild_id = interaction.guild.id
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
await db.execute("INSERT OR REPLACE INTO automod_logging (guild_id, log_channel) VALUES (?, ?)", (guild_id, log_channel.id))
await db.commit()
@@ -440,7 +440,7 @@ class Automod(commands.Cog):
await ctx.send(view=CV2(f"Automod Settings for {ctx.guild.name}", f"Uhh, looks like your server hasn\'t enabled Automoderation.\n\nCurrent Status: {DISABLE} Disabled\nTo Enable use `{ctx.prefix}automod enable`"))
return
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT 1 FROM automod_ignored WHERE guild_id = ? AND type = 'channel' AND id = ?", (guild_id, channel.id))
if await cursor.fetchone() is not None:
await ctx.send(view=CV2("__Channel Already Whitelisted!__", f"{CROSS} The channel {channel.mention} is already in the ignore list.\n\n➜ Use **{ctx.prefix}automod unignore channel {channel.mention}** to remove it."))
@@ -491,7 +491,7 @@ class Automod(commands.Cog):
await ctx.send(view=CV2(f"Automod Settings for {ctx.guild.name}", f"Uhh, looks like your server hasn\'t enabled Automoderation.\n\nCurrent Status: {DISABLE} Disabled\nTo Enable use `{ctx.prefix}automod enable`"))
return
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT 1 FROM automod_ignored WHERE guild_id = ? AND type = 'role' AND id = ?", (guild_id, role.id))
if await cursor.fetchone() is not None:
@@ -545,7 +545,7 @@ class Automod(commands.Cog):
return
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT type, id FROM automod_ignored WHERE guild_id = ?", (guild_id,))
ignored_items = await cursor.fetchall()
@@ -592,7 +592,7 @@ class Automod(commands.Cog):
await ctx.send(view=CV2(f"Automod Settings for {ctx.guild.name}", f"Uhh, looks like your server hasn\'t enabled Automoderation.\n\nCurrent Status: {DISABLE} Disabled\nTo Enable use `{ctx.prefix}automod enable`"))
return
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
await db.execute("DELETE FROM automod_ignored WHERE guild_id = ?", (guild_id,))
await db.commit()
await ctx.send(view=CV2(f"Automod Settings for {ctx.guild.name}", f"** {TICK} | All ignored channels and roles have been reset!**\n\nTo view current Automod settings use `{ctx.prefix}automod config`"))
@@ -639,7 +639,7 @@ class Automod(commands.Cog):
except discord.HTTPException:
pass
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
result = await db.execute("DELETE FROM automod_ignored WHERE guild_id = ? AND type = 'channel' AND id = ?", (guild_id, channel.id))
await db.commit()
@@ -682,7 +682,7 @@ class Automod(commands.Cog):
pass
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
result = await db.execute("DELETE FROM automod_ignored WHERE guild_id = ? AND type = 'role' AND id = ?", (guild_id, role.id))
await db.commit()
@@ -719,7 +719,7 @@ class Automod(commands.Cog):
elif view.value:
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
await db.execute("DELETE FROM automod WHERE guild_id = ?", (guild_id,))
await db.execute("DELETE FROM automod_punishments WHERE guild_id = ?", (guild_id,))
await db.execute("DELETE FROM automod_ignored WHERE guild_id = ?", (guild_id,))
@@ -768,7 +768,7 @@ class Automod(commands.Cog):
items_str.append(f"**{event}**: {punishment or 'None'}")
if await self.is_anti_nsfw_enabled(guild_id):
items_str.append("**Anti NSFW Links**: Block Message")
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
cursor = await db.execute("SELECT log_channel FROM automod_logging WHERE guild_id = ?", (guild_id,))
log_channel_id = await cursor.fetchone()
if log_channel_id and log_channel_id[0]:
@@ -799,7 +799,7 @@ class Automod(commands.Cog):
await ctx.send(view=CV2(f"Automod Settings for {ctx.guild.name}", f"Uhh, looks like your server hasn\'t enabled Automoderation.\n\nCurrent Status: {DISABLE} Disabled\nTo Enable use `{ctx.prefix}automod enable`"))
return
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
await db.execute("INSERT OR REPLACE INTO automod_logging (guild_id, log_channel) VALUES (?, ?)", (guild_id, channel.id))
await db.commit()
await ctx.send(view=CV2(f"Automod Settings for {ctx.guild.name}", f"**{TICK} | Automoderation Logging channel set to {channel.mention}.**\n\n➜ Use `{ctx.prefix}automod config` to view current Automod settings."))
@@ -809,7 +809,7 @@ class Automod(commands.Cog):
async def on_guild_remove(self, guild):
guild_id = guild.id
async with aiosqlite.connect("db/automod.db") as db:
async with aiosqlite.connect(db_path("automod.db")) as db:
await db.execute("DELETE FROM automod WHERE guild_id = ?", (guild_id,))
await db.execute("DELETE FROM automod_punishments WHERE guild_id = ?", (guild_id,))
await db.execute("DELETE FROM automod_ignored WHERE guild_id = ?", (guild_id,))

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, ICONS_WARNING, TICK
@@ -28,7 +28,7 @@ from utils.cv2 import CV2, build_container
class AutoReaction(commands.Cog):
def __init__(self, bot):
self.bot = bot
self.db_path = 'db/autoreact.db'
self.db_path = db_path('autoreact.db')
self.bot.loop.create_task(self.setup_database())
async def setup_database(self):

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, TICK
@@ -25,7 +25,7 @@ from utils.cv2 import CV2, build_container
DB_PATH = "db/autoresponder.db"
DB_PATH = db_path("autoresponder.db")
class AutoResponder(commands.Cog):
def __init__(self, bot):

View File

@@ -1,18 +1,18 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from __future__ import annotations
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, ICONS_WARNING, TICK
import aiosqlite
@@ -33,7 +33,7 @@ logging.basicConfig(
datefmt="%H:%M:%S",
)
DATABASE_PATH = 'db/autorole.db'
DATABASE_PATH = db_path('autorole.db')
class BasicView(discord.ui.View):
def __init__(self, ctx: commands.Context, timeout=60):

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, TICK
@@ -55,7 +55,7 @@ class BlacklistWordSource(menus.ListPageSource):
return embed
DB_PATH = "db/blword.db"
DB_PATH = db_path("blword.db")
async def create_blacklist_table():

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, TICK
@@ -37,7 +37,7 @@ class Block(commands.Cog):
#@commands.Cog.listener()
async def set_db(self):
async with aiosqlite.connect('db/block.db') as db:
async with aiosqlite.connect(db_path('block.db')) as db:
await db.execute('''
CREATE TABLE IF NOT EXISTS user_blacklist (
user_id INTEGER PRIMARY KEY,
@@ -71,7 +71,7 @@ class Block(commands.Cog):
@user.command(name="add", help="Adds a user to the blacklist.")
@commands.is_owner()
async def add_user(self, ctx, user: discord.User):
async with aiosqlite.connect('db/block.db') as db:
async with aiosqlite.connect(db_path('block.db')) as db:
cursor = await db.execute('SELECT user_id FROM user_blacklist WHERE user_id = ?', (user.id,))
if await cursor.fetchone():
await ctx.reply(view=CV2("User Already Blacklisted", f"{user.mention} is already blacklisted."))
@@ -83,7 +83,7 @@ class Block(commands.Cog):
@user.command(name="remove", help="Remove a user from the blacklist.")
@commands.is_owner()
async def remove_user(self, ctx, user: discord.User):
async with aiosqlite.connect('db/block.db') as db:
async with aiosqlite.connect(db_path('block.db')) as db:
cursor = await db.execute('SELECT user_id FROM user_blacklist WHERE user_id = ?', (user.id,))
if not await cursor.fetchone():
await ctx.reply(view=CV2(f"{CROSS} User Not Blacklisted", f"{user.mention} is not in the blacklist."))
@@ -95,7 +95,7 @@ class Block(commands.Cog):
@user.command(name="show", aliases=["list"], help="Shows all Blacklisted users.")
@commands.is_owner()
async def show_users(self, ctx):
async with aiosqlite.connect('db/block.db') as db:
async with aiosqlite.connect(db_path('block.db')) as db:
cursor = await db.execute('SELECT user_id FROM user_blacklist')
rows = await cursor.fetchall()
if not rows:
@@ -135,7 +135,7 @@ class Block(commands.Cog):
@guild.command(name="add", help="Adds a guild to the blacklist.")
@commands.is_owner()
async def add_guild(self, ctx, guild_id: int):
async with aiosqlite.connect('db/block.db') as db:
async with aiosqlite.connect(db_path('block.db')) as db:
cursor = await db.execute('SELECT guild_id FROM guild_blacklist WHERE guild_id = ?', (guild_id,))
if await cursor.fetchone():
await ctx.reply(view=CV2(f"{CROSS} Guild Already Blacklisted", f"Guild with ID `{guild_id}` is already blacklisted."))
@@ -147,7 +147,7 @@ class Block(commands.Cog):
@guild.command(name="remove", help="Remove a guild from the blacklist.")
@commands.is_owner()
async def remove_guild(self, ctx, guild_id: int):
async with aiosqlite.connect('db/block.db') as db:
async with aiosqlite.connect(db_path('block.db')) as db:
cursor = await db.execute('SELECT guild_id FROM guild_blacklist WHERE guild_id = ?', (guild_id,))
if not await cursor.fetchone():
await ctx.reply(view=CV2(f"{CROSS} Guild Not Blacklisted", f"Guild with ID `{guild_id}` is not in the blacklist."))
@@ -160,7 +160,7 @@ class Block(commands.Cog):
@guild.command(name="show", aliases=["list"], help="Shows the list of blacklisted guilds")
@commands.is_owner()
async def show_guilds(self, ctx):
async with aiosqlite.connect('db/block.db') as db:
async with aiosqlite.connect(db_path('block.db')) as db:
cursor = await db.execute('SELECT guild_id FROM guild_blacklist')
rows = await cursor.fetchall()
if not rows:

View File

@@ -1,18 +1,18 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from __future__ import annotations
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, NITRO_BOOST, TICK, TIMER
import asyncio
@@ -28,7 +28,7 @@ import datetime
import re
from typing import *
from time import strftime
from core import Cog ,zyrox ,Context
from core import Cog, HexaHost, Context
from discord.ui import LayoutView, TextDisplay, Separator, Container
from utils.cv2 import CV2, build_container
@@ -49,10 +49,10 @@ datefmt ="%H:%M:%S",
)
class Booster (Cog ):
def __init__ (self ,bot : Zyrox ):
def __init__ (self ,bot : HexaHost ):
self .bot =bot
self .color =0xFF0000
self .db_path ="db/boost.db"
self .db_path =db_path("boost.db")
self .bot .loop .create_task (self .setup_database ())

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,18 +1,18 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
import discord
from utils.db_paths import db_path
from utils.emoji import ARROWRED, CROSS, NEXT_ALT1, REDRULESBOOK, RED_BUTTON, RED_PIN, STAR, TICK, ZBACK, ZPAUSE, ZPLAY, ZWARNING
from discord.ext import commands
import json
@@ -41,7 +41,7 @@ STAR = STAR
class Counting(commands.Cog):
def __init__(self, bot):
self.bot = bot
self.data_file = "db/counting.json"
self.data_file = db_path("counting.json")
if not os.path.exists(self.data_file):
with open(self.data_file, 'w') as f:
json.dump({}, f)

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, TICK, ZWARNING
@@ -27,8 +27,8 @@ from utils.config import *
DATABASE_PATH = 'db/customrole.db'
DATABASE_PATH2 = 'db/np.db'
DATABASE_PATH = db_path('customrole.db')
DATABASE_PATH2 = db_path('np.db')
class Customrole(commands.Cog):
@@ -81,7 +81,7 @@ class Customrole(commands.Cog):
async def handle_role_command(self, context: Context, member: discord.Member, role_type: str):
async with aiosqlite.connect('db/customrole.db') as db:
async with aiosqlite.connect(db_path('customrole.db')) as db:
async with db.execute(f"SELECT reqrole, {role_type} FROM roles WHERE guild_id = ?", (context.guild.id,)) as cursor:
data = await cursor.fetchone()
if data:

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, CROSS_ALT, ML_CROSS, TICK, TICK_ALT, ZWARNING
@@ -374,7 +374,7 @@ class EmergencyRestoreResultView(LayoutView):
class Emergency(commands.Cog):
def __init__(self, bot):
self.bot = bot
self.db_path = "db/emergency.db"
self.db_path = db_path("emergency.db")
self.bot.loop.create_task(self.initialize_database())
async def initialize_database(self):
@@ -533,7 +533,7 @@ class Emergency(commands.Cog):
is_owner = await self.is_guild_owner(ctx)
if not is_owner:
return await ctx.reply(view=AuthoriseErrorView("owner_list"))
async with aiosqlite.connect("db/emergency.db") as db:
async with aiosqlite.connect(db_path("emergency.db")) as db:
cursor = await db.execute(
"SELECT user_id FROM authorised_users WHERE guild_id = ?",
(ctx.guild.id,),
@@ -606,7 +606,7 @@ class Emergency(commands.Cog):
is_auth = await self.is_guild_owner_or_authorised(ctx)
if not is_auth:
return await ctx.reply(view=RoleErrorView("owner_list"))
async with aiosqlite.connect("db/emergency.db") as db:
async with aiosqlite.connect(db_path("emergency.db")) as db:
cursor = await db.execute(
"SELECT role_id FROM emergency_roles WHERE guild_id = ?",
(ctx.guild.id,),
@@ -632,7 +632,7 @@ class Emergency(commands.Cog):
guild_id = ctx.guild.id
antinuke_enabled = False
async with aiosqlite.connect("db/anti.db") as anti:
async with aiosqlite.connect(db_path("anti.db")) as anti:
cursor = await anti.execute(
"SELECT status FROM antinuke WHERE guild_id = ?", (guild_id,)
)
@@ -731,7 +731,7 @@ class Emergency(commands.Cog):
await ctx.reply(view=result_view)
if antinuke_enabled:
async with aiosqlite.connect("db/anti.db") as anti:
async with aiosqlite.connect(db_path("anti.db")) as anti:
await anti.execute("INSERT INTO antinuke VALUES (?, 1)", (guild_id,))
await anti.commit()
await proc_msg.delete()

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import os
import discord
@@ -30,7 +30,7 @@ from typing import *
from utils import *
from utils.config import BotName, serverLink
from utils import Paginator, DescriptionEmbedPaginator, FieldPagePaginator, TextPaginator
from core import Cog, zyrox, Context
from core import Cog, HexaHost, Context
from typing import Optional
import aiosqlite
import asyncio
@@ -887,7 +887,7 @@ class Extra(commands.Cog):
db_latency = "Not Available"
try:
async with aiosqlite.connect("db/afk.db") as db:
async with aiosqlite.connect(db_path("afk.db")) as db:
db_start_time = time.perf_counter()
await db.execute("SELECT 1")
db_end_time = time.perf_counter()

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, TICK, ZWARNING
@@ -86,7 +86,7 @@ class Extraowner(commands.Cog):
self.bot.loop.create_task(self.initialize_db())
async def initialize_db(self):
self.db = await aiosqlite.connect('db/anti.db')
self.db = await aiosqlite.connect(db_path('anti.db'))
await self.db.execute('''
CREATE TABLE IF NOT EXISTS extraowners (
guild_id INTEGER PRIMARY KEY,

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,20 +1,19 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
import asyncio
import discord
from utils.emoji import CROSS, TICK, ZWARNING, ZYROXCONNECTION, ZYROXLINKS
from utils.emoji import CROSS, TICK, ZWARNING, HEXAHOST_CONNECTION, HEXAHOST_LINKS
from discord.ext import commands, tasks
from discord.utils import get
import datetime
@@ -309,8 +308,8 @@ class General(commands.Cog):
async def invite(self, ctx: commands.Context):
invite_text = (
"```Empower your server with blazing-fast features and 24/7 support!```\n"
f"{ZYROXLINKS} **Quick Actions**\n"
f"{HEXAHOST_LINKS} **Quick Actions**\n"
f">>> **[Invite {BotName}](https://discord.com/oauth2/authorize?client_id=1396114795102470196&permissions=8&integration_type=0&scope=bot+applications.commands)**\n"
"**[Support Server](https://discord.gg/codexdev)**"
"**[Support Server](https://discord.gg/hexahost)**"
)
await ctx.send(view=CV2(f"{ZYROXCONNECTION} {BotName} Integration Hub!", invite_text))
await ctx.send(view=CV2(f"{HEXAHOST_CONNECTION} {BotName} Integration Hub!", invite_text))

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
@@ -19,7 +18,7 @@ from discord import app_commands, Interaction
from difflib import get_close_matches
from contextlib import suppress
from core import Context
from core.zyrox import zyrox
from core.hexahost import HexaHost
from core.Cog import Cog
from utils.Tools import getConfig
from itertools import chain
@@ -33,7 +32,6 @@ from utils.cv2 import CV2, CV2Embed
from utils.config import *
color = 0xFF0000
client = zyrox()
from utils.config import BotName
@@ -157,7 +155,7 @@ class HelpCommand(commands.HelpCommand):
)
embed.set_footer(
text=f"Requested By {self.context.author} | [Support](https://discord.gg/codexdev)",
text=f"Requested By {self.context.author} | [Support](https://discord.gg/hexahost)",
)
view = vhelp.View(mapping=mapping, ctx=self.context, homeembed=embed, ui=2)
@@ -175,9 +173,9 @@ class HelpCommand(commands.HelpCommand):
await self.send_ignore_message(ctx, "command")
return
zyrox = f">>> {command.help}" if command.help else '>>> No Help Provided...'
help_text = f">>> {command.help}" if command.help else '>>> No Help Provided...'
embed = CV2Embed(
description=f"""{zyrox}""",
description=f"""{help_text}""",
color=color)
alias = ' & '.join(command.aliases)
@@ -270,7 +268,7 @@ class HelpCommand(commands.HelpCommand):
class Help(Cog, name="help"):
def __init__(self, client: zyrox):
def __init__(self, client: HexaHost):
self._original_help_command = client.help_command
attributes = {
'name': "help",

View File

@@ -58,7 +58,7 @@ class HelpCommand(commands.HelpCommand):
matches = get_close_matches(string, cmds)
embed = discord.Embed(
title="Zyrox Helper",
title="HexaHost Helper",
description=f">>> **Ops! Command not found with the name** `{string}`.",
color=0xFF0000
)
@@ -101,7 +101,7 @@ class HelpCommand(commands.HelpCommand):
embed = discord.Embed(
description=(
f"**{ARROWRED} __Start Zyrox X Today__**\n"
f"**{ARROWRED} __Start HexaHost Today__**\n"
f"**{ZARROW} Type {prefix}antinuke enable**\n"
f"**{ZARROW} Server Prefix:** `{prefix}`\n"
f"**{ZARROW} Total Commands:** `{len(set(self.context.bot.walk_commands()))}`\n"),
@@ -150,7 +150,7 @@ class HelpCommand(commands.HelpCommand):
)
embed.set_footer(
text=f"Requested By {self.context.author} | [Support](https://discord.gg/codexdev)",
text=f"Requested By {self.context.author} | [Support](https://discord.gg/hexahost)",
)
view = vhelp.View(mapping=mapping, ctx=self.context, homeembed=embed, ui=2)
@@ -253,7 +253,7 @@ class HelpCommand(commands.HelpCommand):
) for cmd in cog.get_commands()]
paginator = Paginator(source=FieldPagePaginator(
entries=entries,
title=f"Zyrox's {cog.qualified_name.title()} ({len(cog.get_commands())})",
title=f"HexaHost's {cog.qualified_name.title()} ({len(cog.get_commands())})",
description="`<..> Required | [..] Optional`\n\n",
color=0xFF0000,
per_page=4),

View File

@@ -1,18 +1,18 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from __future__ import annotations
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, TICK, ZWARNING
from discord.ui import LayoutView, TextDisplay, Separator, Container
@@ -98,7 +98,7 @@ class ListView(LayoutView):
class Ignore(commands.Cog):
def __init__(self, bot):
self.bot = bot
self.db_path = "db/ignore.db"
self.db_path = db_path("ignore.db")
self.color = 0xFF0000
bot.loop.create_task(self.initialize_db())

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands, tasks
@@ -19,7 +19,7 @@ from datetime import datetime, timedelta
import re
from utils.cv2 import CV2
DB_FILE = "db/jail.db"
DB_FILE = db_path("jail.db")
class Jail(commands.Cog):
def __init__(self, bot):

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import jsondb_path
import discord
from utils.emoji import BLOBPART
@@ -27,14 +27,14 @@ class joindm(commands.Cog):
def load_joindm_messages(self):
# Load the join DM messages from file
try:
with open('jsondb/joindm_messages.json', 'r') as f:
with open(jsondb_path('joindm_messages.json'), 'r') as f:
self.joindm_messages = json.load(f)
except FileNotFoundError:
self.joindm_messages = {}
def save_joindm_messages(self):
# Save the join DM messages to file
with open('jsondb/joindm_messages.json', 'w') as f:
with open(jsondb_path('joindm_messages.json'), 'w') as f:
json.dump(self.joindm_messages, f)
@commands.group(invoke_without_command=True)

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CROSS, TICK, ZWARNING
@@ -212,7 +212,7 @@ class LevelConfigModal (discord .ui .Modal ,title ="Leveling System Configuratio
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute ("SELECT guild_id FROM leveling_settings WHERE guild_id = ?",(interaction .guild .id ,))as cursor :
exists =await cursor .fetchone ()
@@ -291,7 +291,7 @@ class Leveling (commands .Cog ):
self .bot =bot
self .message_cooldowns ={}
self .last_level_cache ={}
self .db_path ="db/leveling.db"
self .db_path =db_path("leveling.db")
@commands.group (name ="level",invoke_without_command =True ,description ="Leveling system")
async def level (self ,ctx ):
@@ -310,7 +310,7 @@ class Leveling (commands .Cog ):
async def init_database (self ):
"""Initialize all required database tables"""
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
await db .execute ("""
CREATE TABLE IF NOT EXISTS user_xp (
@@ -411,13 +411,13 @@ class Leveling (commands .Cog ):
max_retries =5
for attempt in range (max_retries ):
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute ("SELECT * FROM leveling_settings WHERE guild_id = ?",(guild_id ,))as cursor :
row =await cursor .fetchone ()
if not row :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
await db .execute ("INSERT INTO leveling_settings (guild_id, enabled) VALUES (?, 0)",(guild_id ,))
await db .commit ()
return {
@@ -474,7 +474,7 @@ class Leveling (commands .Cog ):
async def is_blacklisted (self ,guild_id :int ,user_id :int ,channel_id :int )->bool :
"""Check if user or channel is blacklisted"""
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .cursor ()as cursor :
await cursor .execute ("PRAGMA table_info(leveling_blacklist)")
@@ -522,7 +522,7 @@ class Leveling (commands .Cog ):
return 1.0
total_multiplier =1.0
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute (
"SELECT target_id, multiplier FROM xp_multipliers WHERE guild_id = ? AND target_type = 'role'",
@@ -593,7 +593,7 @@ class Leveling (commands .Cog ):
final_xp =int (final_xp *multiplier )
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute (
"SELECT xp, messages FROM user_xp WHERE guild_id = ? AND user_id = ?",
(guild_id ,user_id )
@@ -713,7 +713,7 @@ class Leveling (commands .Cog ):
async def give_level_rewards (self ,guild ,member ,level ):
"""Give role rewards for reaching a level"""
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute (
"SELECT role_id, remove_previous FROM level_rewards WHERE guild_id = ? AND level <= ? ORDER BY level DESC",
(guild .id ,level )
@@ -727,7 +727,7 @@ class Leveling (commands .Cog ):
if remove_previous :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute (
"SELECT role_id FROM level_rewards WHERE guild_id = ? AND level < ?",
(guild .id ,level )
@@ -745,7 +745,7 @@ class Leveling (commands .Cog ):
async def apply_level_roles (self ,guild ,member ,level ):
"""Apply level roles for reaching a level"""
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute (
"SELECT role_id FROM level_roles WHERE guild_id = ? AND level <= ? ORDER BY level DESC",
(guild .id ,level )
@@ -768,7 +768,7 @@ class Leveling (commands .Cog ):
async def get_user_data (self ,guild_id :int ,user_id :int )->tuple :
"""Get user XP and level data"""
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute (
"SELECT xp, messages FROM user_xp WHERE guild_id = ? AND user_id = ?",
(guild_id ,user_id )
@@ -786,7 +786,7 @@ class Leveling (commands .Cog ):
async def get_user_rank (self ,guild_id :int ,user_id :int )->int :
"""Get user's rank in the guild"""
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute (
"SELECT COUNT(*) + 1 FROM user_xp WHERE guild_id = ? AND xp > (SELECT COALESCE(xp, 0) FROM user_xp WHERE guild_id = ? AND user_id = ?)",
(guild_id ,guild_id ,user_id )
@@ -1751,7 +1751,7 @@ class Leveling (commands .Cog ):
embed_color_int =hex_to_int (embed_color )
level_image_final =level_image if level_image and level_image .strip ()else None
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute ("SELECT guild_id FROM leveling_settings WHERE guild_id = ?",(ctx .guild .id ,))as cursor :
exists =await cursor .fetchone ()
@@ -2014,7 +2014,7 @@ class Leveling (commands .Cog ):
await ctx .send ("Level must be greater than 0.")
return
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
await db .execute (
"INSERT OR REPLACE INTO level_rewards (guild_id, level, role_id, remove_previous) VALUES (?, ?, ?, ?)",
(ctx .guild .id ,level ,role .id ,int (remove_previous ))
@@ -2031,7 +2031,7 @@ class Leveling (commands .Cog ):
async def rewards_remove (self ,ctx ,level :int ):
"""Remove level reward"""
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
await db .execute (
"DELETE FROM level_rewards WHERE guild_id = ? AND level = ?",
(ctx .guild .id ,level )
@@ -2048,7 +2048,7 @@ class Leveling (commands .Cog ):
async def rewards_list (self ,ctx ):
"""List level rewards"""
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute (
"SELECT level, role_id, remove_previous FROM level_rewards WHERE guild_id = ? ORDER BY level",
(ctx .guild .id ,)
@@ -2104,7 +2104,7 @@ class Leveling (commands .Cog ):
await ctx .send ("Invalid channel ID.")
return
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
await db .execute (
"INSERT OR REPLACE INTO xp_multipliers (guild_id, target_id, target_type, multiplier) VALUES (?, ?, ?, ?)",
(ctx .guild .id ,target_id ,target_type ,multiplier )
@@ -2140,7 +2140,7 @@ class Leveling (commands .Cog ):
await ctx .send ("Invalid channel ID.")
return
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
await db .execute (
"DELETE FROM xp_multipliers WHERE guild_id = ? AND target_id = ? AND target_type = ?",
(ctx .guild .id ,target_id ,target_type )
@@ -2157,7 +2157,7 @@ class Leveling (commands .Cog ):
async def multiplier_list (self ,ctx ):
"""List XP multipliers"""
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute (
"SELECT target_id, target_type, multiplier FROM xp_multipliers WHERE guild_id = ?",
(ctx .guild .id ,)
@@ -2213,7 +2213,7 @@ class Leveling (commands .Cog ):
await ctx .send ("Invalid channel ID.")
return
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
await db .execute (
"INSERT OR REPLACE INTO leveling_blacklist (guild_id, target_id, target_type) VALUES (?, ?, ?)",
(ctx .guild .id ,target_id ,target_type )
@@ -2249,7 +2249,7 @@ class Leveling (commands .Cog ):
await ctx .send ("Invalid channel ID.")
return
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
await db .execute (
"DELETE FROM leveling_blacklist WHERE guild_id = ? AND target_id = ? AND target_type = ?",
(ctx .guild .id ,target_id ,target_type )
@@ -2266,7 +2266,7 @@ class Leveling (commands .Cog ):
async def blacklist_list (self ,ctx ):
"""List leveling blacklist"""
try :
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute (
"SELECT target_id, target_type FROM leveling_blacklist WHERE guild_id = ?",
(ctx .guild .id ,)
@@ -2422,7 +2422,7 @@ class Leveling (commands .Cog ):
if isinstance (ctx ,discord .Interaction ):
await ctx .response .defer ()
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
cursor =await db .execute ('''
SELECT user_id, xp, messages FROM user_xp
@@ -3013,7 +3013,7 @@ class Leveling (commands .Cog ):
percentage =(progress /needed *100 )if needed >0 else 100
async with aiosqlite .connect ("db/leveling.db")as db :
async with aiosqlite .connect (db_path("leveling.db"))as db :
async with db .execute (
"SELECT COUNT(*) FROM user_xp WHERE guild_id = ? AND xp > 0",
(guild_id ,)

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import jsondb_path
import discord
from discord.ext import commands
@@ -43,7 +43,7 @@ LOG_CATEGORIES = [
"system_events",
]
CONFIG_FILE = "jsondb/logging_config.json"
CONFIG_FILE = jsondb_path("logging_config.json")
LOGS_DIR = "logs"
MAX_AUDIT_CACHE_SIZE = 1000
AUDIT_CACHE_TTL = 300

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
@@ -92,7 +91,7 @@ class MapView(LayoutView):
def get_coordinates(self, location):
try:
headers = {'User-Agent': f'{BRAND_NAME} Bot (https://codexdevs.in)'}
headers = {'User-Agent': f'{BRAND_NAME} Bot (https://hexahost.dev)'}
response = requests.get(f'https://nominatim.openstreetmap.org/search?q={location}&format=json', headers=headers)
response.raise_for_status()
data = response.json()[0]

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import ARROWRED
@@ -34,7 +34,7 @@ class MessagesView(LayoutView):
f"**Daily Messages**: {daily_average}\n"
f"**Today Messages**: {today_count}\n"
f"**Total Messages**: {total}\n\n"
f"**{ARROWRED}Upgrade Your Experience With [{BRAND_NAME} Noprefix](https://discord.gg/codexdev)**"
f"**{ARROWRED}Upgrade Your Experience With [{BRAND_NAME} Noprefix](https://discord.gg/hexahost)**"
),
)
)
@@ -49,7 +49,7 @@ class Messages(commands.Cog):
if message.author.bot or not message.guild:
return
conn = sqlite3.connect("db/messages.db")
conn = sqlite3.connect(db_path("messages.db"))
c = conn.cursor()
c.execute("""
CREATE TABLE IF NOT EXISTS messages (
@@ -86,7 +86,7 @@ class Messages(commands.Cog):
member = member or ctx.author
today = datetime.utcnow().strftime("%Y-%m-%d")
conn = sqlite3.connect("db/messages.db")
conn = sqlite3.connect(db_path("messages.db"))
c = conn.cursor()
c.execute(
"SELECT date, count FROM messages WHERE guild_id = ? AND user_id = ?",

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands, tasks
@@ -30,7 +30,7 @@ from utils.emoji import SUCCESS, ERROR, WARNING_UNICODE, CLOCK, REFRESH, JAVA_CO
ASSETS_DIR = "assets"
FONT_PATH = os.path.join(ASSETS_DIR, "fonts", "minecraft.ttf")
BACKGROUND_PATH = os.path.join(ASSETS_DIR, "background", "background.png")
DB_PATH = "db/minecraft.db"
DB_PATH = db_path("minecraft.db")
# --- Other Constants ---
REFRESH_COOLDOWN_SECONDS = 30

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -28,7 +28,7 @@ class Messagespack(commands.Cog):
return await ctx.send("Amount must be greater than 0.")
today = datetime.utcnow().strftime("%Y-%m-%d")
conn = sqlite3.connect("db/messages.db")
conn = sqlite3.connect(db_path("messages.db"))
c = conn.cursor()
c.execute("SELECT count FROM messages WHERE guild_id = ? AND user_id = ? AND date = ?",
@@ -53,7 +53,7 @@ class Messagespack(commands.Cog):
return await ctx.send("Amount must be greater than 0.")
today = datetime.utcnow().strftime("%Y-%m-%d")
conn = sqlite3.connect("db/messages.db")
conn = sqlite3.connect(db_path("messages.db"))
c = conn.cursor()
c.execute("SELECT count FROM messages WHERE guild_id = ? AND user_id = ? AND date = ?",
@@ -73,7 +73,7 @@ class Messagespack(commands.Cog):
@commands.command(name="clearmessage", aliases=["clearmsg"])
@commands.has_permissions(manage_messages=True)
async def clearmessage(self, ctx, member: discord.Member):
conn = sqlite3.connect("db/messages.db")
conn = sqlite3.connect(db_path("messages.db"))
c = conn.cursor()
c.execute("DELETE FROM messages WHERE guild_id = ? AND user_id = ?",
(ctx.guild.id, member.id))

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
@@ -22,7 +21,7 @@ from discord.ui import Button, View, LayoutView, TextDisplay, Separator, Contain
import wavelink
from wavelink.enums import TrackSource
from utils import Paginator, DescriptionEmbedPaginator
from core import Cog, zyrox, Context
from core import Cog, HexaHost, Context
from PIL import Image, ImageDraw, ImageFont, ImageOps
import io
import aiohttp
@@ -335,7 +334,7 @@ class MusicControlView(LayoutView):
class Music(commands.Cog):
def __init__(self, client: zyrox):
def __init__(self, client: HexaHost):
self.client = client
self.client.loop.create_task(self.connect_nodes())
self.client.loop.create_task(self.monitor_inactivity())
@@ -374,7 +373,7 @@ class Music(commands.Cog):
if player:
await player.disconnect(force=True)
try:
support = Button(label='Support', style=discord.ButtonStyle.link, url='https://discord.gg/codexdev')
support = Button(label='Support', style=discord.ButtonStyle.link, url='https://discord.gg/hexahost')
vote = Button(label='Vote', style=discord.ButtonStyle.link, url='https://top.gg/bot//vote')
view = LayoutView(timeout=None)
container = build_container(
@@ -423,7 +422,7 @@ class Music(commands.Cog):
await player.ctx.send(view=CV2("No suitable track found for autoplay."))
else:
await player.disconnect()
support = Button(label='Support', style=discord.ButtonStyle.link, url='https://discord.gg/codexdev')
support = Button(label='Support', style=discord.ButtonStyle.link, url='https://discord.gg/hexahost')
vote = Button(label='Vote', style=discord.ButtonStyle.link, url='https://top.gg/bot//vote')
view = LayoutView(timeout=None)
container = build_container(
@@ -473,7 +472,7 @@ class Music(commands.Cog):
if isinstance(tracks, wavelink.Playlist):
await vc.queue.put_wait(tracks.tracks)
await ctx.send(view=CV2(f"{ZPLUS} Added playlist [{tracks.name}](https://discord.gg/codexdev) with **{len(tracks.tracks)} songs** to the queue."))
await ctx.send(view=CV2(f"{ZPLUS} Added playlist [{tracks.name}](https://discord.gg/hexahost) with **{len(tracks.tracks)} songs** to the queue."))
if not vc.playing:
track = await vc.queue.get_wait()
await vc.play(track)
@@ -481,7 +480,7 @@ class Music(commands.Cog):
else:
track = tracks[0]
await vc.queue.put_wait(track)
await ctx.send(view=CV2(f"{ZPLUS} Added [{track.title}](https://discord.gg/codexdev) to the queue."))
await ctx.send(view=CV2(f"{ZPLUS} Added [{track.title}](https://discord.gg/hexahost) to the queue."))
if not vc.playing:
await vc.play(await vc.queue.get_wait())
await self.display_player_embed(vc, track, ctx)
@@ -510,7 +509,7 @@ class Music(commands.Cog):
track = search_results[0]
await vc.queue.put_wait(track)
await ctx.send(view=CV2(f"{ZPLUS} Added [{track.title}](https://discord.gg/codexdev) to the queue."))
await ctx.send(view=CV2(f"{ZPLUS} Added [{track.title}](https://discord.gg/hexahost) to the queue."))
if not vc.playing:
await vc.play(track)
await self.display_player_embed(vc, track, ctx)
@@ -541,7 +540,7 @@ class Music(commands.Cog):
c += 1
await ctx.message.add_reaction("")
await ctx.send(view=CV2(f"{ZPLUS} Added **{c}** of **{playlist_length}** tracks from **playlist** **[{playlist_info['name']}](https://discord.gg/codexdev)** to the queue."))
await ctx.send(view=CV2(f"{ZPLUS} Added **{c}** of **{playlist_length}** tracks from **playlist** **[{playlist_info['name']}](https://discord.gg/hexahost)** to the queue."))
await lmao.delete()
if not vc.playing:
@@ -569,7 +568,7 @@ class Music(commands.Cog):
if track_results:
await vc.queue.put_wait(track_results[0])
await ctx.send(view=CV2(f"{ZPLUS} Added all tracks from album **[{album_info['name']}](https://discord.gg/codexdev)** to the queue."))
await ctx.send(view=CV2(f"{ZPLUS} Added all tracks from album **[{album_info['name']}](https://discord.gg/hexahost)** to the queue."))
if not vc.playing:
next_track = await vc.queue.get_wait()
await vc.play(next_track)

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
@@ -44,7 +43,7 @@ class Nitro(commands.Cog):
claim_button = Button(
style=discord.ButtonStyle.primary,
label="Click me!",
url="https://discord.gg/codexdev",
url="https://discord.gg/hexahost",
disabled=False,
)

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands
@@ -22,7 +22,7 @@ from utils.cv2 import CV2
class NotifCommands(commands.Cog):
def __init__(self, bot):
self.bot = bot
self.db_path = "db/notify.db"
self.db_path = db_path("notify.db")
self.loop_task = self.bot.loop.create_task(self.setup_db())
async def setup_db(self):

View File

@@ -1,21 +1,21 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
from discord.ext import commands, tasks
from discord import *
import discord
from utils.emoji import BOOST, ICONS_WARNING, INFO, MENTION, PREMIUM, TICK, TIME, TIMER_ALT1, U_ADMIN, ZDIL, ZHUMAN, ZYROXHAMMER, ZYROXSYS
from utils.emoji import BOOST, ICONS_WARNING, INFO, MENTION, PREMIUM, TICK, TIME, TIMER_ALT1, U_ADMIN, ZDIL, ZHUMAN, HEXAHOST_HAMMER, HEXAHOST_SYS
import aiosqlite
from typing import Optional
from datetime import datetime, timedelta
@@ -143,7 +143,7 @@ class TimeSelect(Select):
await log_channel.send(view=embed)
embed = CV2Embed(
description=f"**Added Global No Prefix**:\n{ZHUMAN} User: **{self.user.mention}**\n{MENTION} User Mention: {self.user.mention}\n{ZYROXSYS} User ID: {self.user.id}\n\n__**Additional Info**__:\n{ZYROXHAMMER} Added By: **{self.author.display_name}**\n{TIME} Expiry Time: {expiry_text}\n{BOOST} Timestamp: {expiry_timestamp}",
description=f"**Added Global No Prefix**:\n{ZHUMAN} User: **{self.user.mention}**\n{MENTION} User Mention: {self.user.mention}\n{HEXAHOST_SYS} User ID: {self.user.id}\n\n__**Additional Info**__:\n{HEXAHOST_HAMMER} Added By: **{self.author.display_name}**\n{TIME} Expiry Time: {expiry_text}\n{BOOST} Timestamp: {expiry_timestamp}",
color=0xFF0000,
)
embed.set_author(
@@ -171,7 +171,7 @@ class NoPrefix(commands.Cog):
def __init__(self, client):
self.client = client
self.staff = set()
self.db_path = "db/np.db"
self.db_path = db_path("np.db")
self.client.loop.create_task(self.load_staff())
self.client.loop.create_task(self.setup_database())
self.expiry_check.start()
@@ -278,7 +278,7 @@ class NoPrefix(commands.Cog):
support = Button(
label="Support",
style=discord.ButtonStyle.link,
url=f"https://discord.gg/codexdev",
url=f"https://discord.gg/hexahost",
)
view = View()
view.add_item(support)
@@ -363,7 +363,7 @@ class NoPrefix(commands.Cog):
@_np.command(name="remove", help="Remove user from no-prefix")
@commands.check(is_owner_or_staff)
async def np_remove(self, ctx, user: discord.User):
async with aiosqlite.connect("db/np.db") as db:
async with aiosqlite.connect(db_path("np.db")) as db:
async with db.execute(
"SELECT id FROM np WHERE id = ?", (user.id,)
) as cursor:
@@ -423,7 +423,7 @@ class NoPrefix(commands.Cog):
)
@commands.check(is_owner_or_staff)
async def np_status(self, ctx, user: discord.User):
async with aiosqlite.connect("db/np.db") as db:
async with aiosqlite.connect(db_path("np.db")) as db:
async with db.execute(
"SELECT id, expiry_time FROM np WHERE id = ?", (user.id,)
) as cursor:
@@ -581,7 +581,7 @@ class NoPrefix(commands.Cog):
embed = CV2Embed(
title="Congratulations you got 2 months No Prefix!",
description=f"You've been credited 2 months of global No Prefix for boosting our Partnered Servers. You can now use my commands without prefix. If you wish to remove it, please reach out [Support Server](https://discord.gg/codexdev).",
description=f"You've been credited 2 months of global No Prefix for boosting our Partnered Servers. You can now use my commands without prefix. If you wish to remove it, please reach out [Support Server](https://discord.gg/hexahost).",
color=0xFF0000,
)
try:
@@ -613,7 +613,7 @@ class NoPrefix(commands.Cog):
embed = CV2Embed(
title=f"{ICONS_WARNING} Global No Prefix Expired",
description=f"Hey {user.mention}, your global no prefix has expired!\n\n__**Reason:**__ Unboosting our partnered Server.\nIf you think this is a mistake then please reach out [Support Server](https://discord.gg/codexdev).",
description=f"Hey {user.mention}, your global no prefix has expired!\n\n__**Reason:**__ Unboosting our partnered Server.\nIf you think this is a mistake then please reach out [Support Server](https://discord.gg/hexahost).",
color=0xFF0000,
)

View File

@@ -1,18 +1,18 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from __future__ import annotations
from utils.db_paths import db_path
from discord.ext import commands
from discord import *
from PIL import Image, ImageDraw, ImageFont, ImageFilter
@@ -26,7 +26,7 @@ from utils import Paginator, DescriptionEmbedPaginator, FieldPagePaginator, Text
from utils.Tools import *
from utils.config import OWNER_IDS, BOT_OWNER_IDS
from utils.emoji import BOOSTS, DISCORD_BADGE_EMOJIS, LOADINGRED, NITRO_BOOST, TICK, ZWARNING
from core import Cog, zyrox, Context
from core import Cog, HexaHost, Context
import sqlite3
import os
import requests
@@ -136,7 +136,7 @@ class Owner(commands.Cog):
self.client = client
self.staff = set()
self.np_cache = []
self.db_path = 'db/np.db'
self.db_path = db_path('np.db')
self.stop_tour = False
self.bot_owner_ids = BOT_OWNER_IDS
self.client.loop.create_task(self.setup_database())

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,19 +1,19 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import CODEBASE, LOADING, SYSTEM, THUNDER, ZYROX_CODE, ZYROX_COMMAND, ZYROX_GLOBAL, ZYROX_OWNER, ZYROX_SEARCH
from utils.emoji import CODEBASE, LOADING, SYSTEM, THUNDER, HEXAHOST_CODE, HEXAHOST_COMMAND, HEXAHOST_GLOBAL, HEXAHOST_OWNER, HEXAHOST_SEARCH
import psutil
import sys
import os
@@ -60,27 +60,27 @@ def create_stats_content(stats_data, selected):
f"**{SYSTEM} Hardware**\n"
f"Cpu Usage: **{stats_data['cpu']}%**\n"
f"Ram Usage: **{stats_data['ram']}%**\n\n"
f"**{ZYROX_CODE} Software**\n"
f"**{HEXAHOST_CODE} Software**\n"
f"Python: **{sys.version_info.major}.{sys.version_info.minor}**\n"
f"Discord.py: **{discord.__version__}**"
),
"General Info": (
f"**Uptime**: `{stats_data['uptime']}`\n\n"
f"**{ZYROX_GLOBAL} Server Stats**\n"
f"**{HEXAHOST_GLOBAL} Server Stats**\n"
f"Guilds: **{stats_data['guilds']}**\n"
f"Users: **{stats_data['users']}**\n\n"
f"**{ZYROX_COMMAND} Commands Stats**\n"
f"**{HEXAHOST_COMMAND} Commands Stats**\n"
f"Total Commands: **{stats_data['all_cmds']}**\n"
f"Slash Commands: **{stats_data['slash_cmds']}**"
),
"Team Info": (
"There is only one person who made me. Thanks to him ❤️.\n\n"
f"**{ZYROX_OWNER} Main Owner**\n"
f"**{HEXAHOST_OWNER} Main Owner**\n"
"[01]. [runxking](https://discord.com/users/767979794411028491)\n"
"[02]. [Ray](https://discord.com/users/870179991462236170)"
),
"Code Info": (
f"**{ZYROX_SEARCH} Codebase Overview**\n\n"
f"**{HEXAHOST_SEARCH} Codebase Overview**\n\n"
f"Files: **{stats_data['files']}**\n"
f"Lines: **{stats_data['lines']}**\n"
f"Words: **{stats_data['words']}**"
@@ -110,7 +110,7 @@ class StatsView(LayoutView):
),
discord.SelectOption(
label="General Info",
emoji=ZYROX_GLOBAL,
emoji=HEXAHOST_GLOBAL,
description="General info",
),
discord.SelectOption(
@@ -120,7 +120,7 @@ class StatsView(LayoutView):
),
discord.SelectOption(
label="Code Info",
emoji=ZYROX_SEARCH,
emoji=HEXAHOST_SEARCH,
description="Code stats",
),
],
@@ -179,7 +179,7 @@ class Stats(commands.Cog):
self.bot.loop.create_task(self.setup_database())
async def setup_database(self):
async with aiosqlite.connect("db/stats.db") as db:
async with aiosqlite.connect(db_path("stats.db")) as db:
await db.execute(
"CREATE TABLE IF NOT EXISTS stats (key TEXT PRIMARY KEY, value INTEGER)"
)

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
import aiosqlite
@@ -31,7 +31,7 @@ class StickyMessage(commands.Cog):
if not os.path.exists("db"):
os.makedirs("db")
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
await db.execute("""
CREATE TABLE IF NOT EXISTS sticky_messages (
id INTEGER PRIMARY KEY AUTOINCREMENT,
@@ -58,7 +58,7 @@ class StickyMessage(commands.Cog):
if not message.guild or (message.author.bot and message.author.id != self.bot.user.id):
return
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
db.row_factory = aiosqlite.Row
cursor = await db.execute(
"SELECT * FROM sticky_messages WHERE channel_id = ? AND enabled = 1",
@@ -81,7 +81,7 @@ class StickyMessage(commands.Cog):
new_count = sticky_data['current_count'] + 1
if new_count < sticky_data['trigger_count']:
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
await db.execute(
"UPDATE sticky_messages SET current_count = ? WHERE id = ?",
(new_count, sticky_data['id'])
@@ -89,7 +89,7 @@ class StickyMessage(commands.Cog):
await db.commit()
return
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
await db.execute("UPDATE sticky_messages SET current_count = 0 WHERE id = ?", (sticky_data['id'],))
await db.commit()
@@ -123,7 +123,7 @@ class StickyMessage(commands.Cog):
new_sticky = await message.channel.send(content=content, embed=embed, delete_after=delete_after)
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
await db.execute(
"UPDATE sticky_messages SET last_message_id = ? WHERE id = ?",
(new_sticky.id, sticky_data['id'])
@@ -140,7 +140,7 @@ class StickyMessage(commands.Cog):
@commands.has_permissions(manage_messages=True)
async def sticky_setup(self, ctx: commands.Context, channel: Optional[discord.TextChannel] = None):
channel = channel or ctx.channel
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
cursor = await db.execute("SELECT 1 FROM sticky_messages WHERE channel_id = ?", (channel.id,))
if await cursor.fetchone():
embed = discord.Embed(title="Setup Error", description=f"A sticky message already exists in {channel.mention}.", color=RED_THEME_COLOR)
@@ -153,7 +153,7 @@ class StickyMessage(commands.Cog):
@commands.has_permissions(manage_messages=True)
async def sticky_remove(self, ctx: commands.Context, channel: Optional[discord.TextChannel] = None):
channel = channel or ctx.channel
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
cursor = await db.execute("SELECT last_message_id FROM sticky_messages WHERE channel_id = ?", (channel.id,))
data = await cursor.fetchone()
if not data:
@@ -175,7 +175,7 @@ class StickyMessage(commands.Cog):
@stickymessage.command(name='list')
@commands.has_permissions(manage_messages=True)
async def sticky_list(self, ctx: commands.Context):
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
db.row_factory = aiosqlite.Row
cursor = await db.execute("SELECT * FROM sticky_messages WHERE guild_id = ?", (ctx.guild.id,))
stickies = await cursor.fetchall()
@@ -198,7 +198,7 @@ class StickyMessage(commands.Cog):
@commands.has_permissions(manage_messages=True)
async def sticky_edit(self, ctx: commands.Context, channel: Optional[discord.TextChannel] = None):
channel = channel or ctx.channel
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
db.row_factory = aiosqlite.Row
cursor = await db.execute("SELECT * FROM sticky_messages WHERE channel_id = ?", (channel.id,))
sticky_data = await cursor.fetchone()
@@ -262,7 +262,7 @@ class PlainTextModal(discord.ui.Modal, title='Plain Text Sticky Message'):
except ValueError:
delay = 2
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
await db.execute(
"INSERT INTO sticky_messages (guild_id, channel_id, message_type, message_content, delay_seconds) VALUES (?, ?, ?, ?, ?)",
(self.ctx.guild.id, self.channel.id, 'plain', self.message_content.value, delay)
@@ -296,7 +296,7 @@ class EmbedModal(discord.ui.Modal, title='Embed Sticky Message'):
"footer": self.footer.value
}
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
await db.execute(
"INSERT INTO sticky_messages (guild_id, channel_id, message_type, embed_data, delay_seconds) VALUES (?, ?, ?, ?, ?)",
(self.ctx.guild.id, self.channel.id, 'embed', json.dumps(embed_data), delay)
@@ -342,7 +342,7 @@ class EditPlainTextModal(discord.ui.Modal, title='Edit Plain Text Content'):
self.add_item(self.message_content)
async def on_submit(self, interaction: discord.Interaction):
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
await db.execute(
"UPDATE sticky_messages SET message_content = ? WHERE channel_id = ?",
(self.message_content.value, self.channel.id)
@@ -371,7 +371,7 @@ class EditEmbedModal(discord.ui.Modal, title='Edit Embed Content'):
"title": self.title.value, "description": self.description.value,
"color": f"#{RED_THEME_COLOR:06x}", "footer": self.footer.value
}
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
await db.execute(
"UPDATE sticky_messages SET embed_data = ? WHERE channel_id = ?",
(json.dumps(embed_data), self.channel.id)
@@ -402,7 +402,7 @@ class EditSettingsModal(discord.ui.Modal, title='Edit Sticky Settings'):
except ValueError:
return await interaction.response.send_message("Please enter valid numbers.", ephemeral=True)
async with aiosqlite.connect("db/stickymessages.db") as db:
async with aiosqlite.connect(db_path("stickymessages.db")) as db:
await db.execute(
"UPDATE sticky_messages SET delay_seconds = ?, auto_delete_after = ?, trigger_count = ? WHERE channel_id = ?",
(delay, auto_del, trigger, self.channel.id)

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
# cogs/commands/ticket.py
@@ -44,7 +44,7 @@ TRANSCRIPT_EMOJI = ZMODULE
# --- Constants ---
if not os.path.exists('db'):
os.makedirs('db')
DB_PATH = 'db/ticket.db'
DB_PATH = db_path('ticket.db')
MAX_CATEGORIES = 15
TICKET_LIMIT_PER_USER = 3

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import ARROWRED
@@ -18,7 +18,7 @@ from discord.ext import commands
import aiosqlite
from utils.cv2 import CV2
INVITE_DB = "db/invite.db"
INVITE_DB = db_path("invite.db")
EMOJI_INVITE = ARROWRED
from utils.config import BotName
@@ -157,7 +157,7 @@ class Tracking(commands.Cog):
f"**Fake:** `{fake}`\n"
f"**Left:** `{left}`\n"
f"**Rejoins:** `{rejoin}`\n\n"
f"{EMOJI_INVITE} **Get {BotName} Premium Lifetime [Join Support Here](https://discord.gg/codexdev)**"
f"{EMOJI_INVITE} **Get {BotName} Premium Lifetime [Join Support Here](https://discord.gg/hexahost)**"
)
await ctx.send(view=CV2(f"Invite Log - {member.name}", desc))

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from discord.ext import commands, tasks
@@ -19,7 +19,7 @@ import aiohttp
import os
from utils.Tools import *
DB_PATH = "db/vanity.db"
DB_PATH = db_path("vanity.db")
class VanityRoles(commands.Cog):
def __init__(self, bot):

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import TICK
@@ -30,7 +30,7 @@ from utils .Tools import *
logger =logging .getLogger ('discord')
DATABASE_PATH ='db/verification.db'
DATABASE_PATH =db_path('verification.db')
DISCORD_COLORS ={

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,16 +1,16 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
from utils.db_paths import db_path
import discord
from utils.emoji import ICONS_CHANNEL, ICONS_PLUS, TICK, ZTICK
@@ -65,7 +65,7 @@ class Welcomer(commands.Cog):
self.bot.loop.create_task(self._create_table())
async def _create_table(self):
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
await db.execute("""
CREATE TABLE IF NOT EXISTS welcome (
guild_id INTEGER PRIMARY KEY,
@@ -93,7 +93,7 @@ class Welcomer(commands.Cog):
@commands.cooldown(1, 6, commands.BucketType.user)
@commands.max_concurrency(1, per=commands.BucketType.default, wait=False)
async def greet_setup(self, ctx):
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
async with db.execute("SELECT * FROM welcome WHERE guild_id = ?", (ctx.guild.id,)) as cursor:
row = await cursor.fetchone()
@@ -247,7 +247,7 @@ class Welcomer(commands.Cog):
async def _save_welcome_data(self, guild_id, welcome_type, message, embed_data=None):
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
await db.execute("""
INSERT OR REPLACE INTO welcome (guild_id, welcome_type, welcome_message, embed_data)
VALUES (?, ?, ?, ?)
@@ -431,7 +431,7 @@ class Welcomer(commands.Cog):
@commands.cooldown(1, 6, commands.BucketType.user)
@commands.max_concurrency(1, per=commands.BucketType.default, wait=False)
async def greet_reset(self, ctx):
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
cursor = await db.execute("SELECT 1 FROM welcome WHERE guild_id = ?", (ctx.guild.id,))
is_set_up = await cursor.fetchone()
@@ -454,7 +454,7 @@ class Welcomer(commands.Cog):
await interaction.response.send_message("Only the command author can confirm this action.", ephemeral=True)
return
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
await db.execute("DELETE FROM welcome WHERE guild_id = ?", (ctx.guild.id,))
await db.commit()
@@ -490,7 +490,7 @@ class Welcomer(commands.Cog):
@commands.cooldown(1, 6, commands.BucketType.user)
@commands.max_concurrency(1, per=commands.BucketType.default, wait=False)
async def greet_channel(self, ctx):
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
async with db.execute("SELECT welcome_type, channel_id FROM welcome WHERE guild_id = ?", (ctx.guild.id,)) as cursor:
result = await cursor.fetchone()
welcome_message = result[0] if result else None
@@ -524,7 +524,7 @@ class Welcomer(commands.Cog):
selected_channel_id = int(select_menu.values[0])
selected_channel = ctx.guild.get_channel(selected_channel_id)
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
await db.execute("UPDATE welcome SET channel_id = ? WHERE guild_id = ?", (selected_channel_id, ctx.guild.id))
await db.commit()
@@ -580,7 +580,7 @@ class Welcomer(commands.Cog):
@commands.cooldown(1, 6, commands.BucketType.user)
@commands.max_concurrency(1, per=commands.BucketType.default, wait=False)
async def greet_test(self, ctx):
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
async with db.execute("SELECT welcome_type, welcome_message, channel_id, embed_data FROM welcome WHERE guild_id = ?", (ctx.guild.id,)) as cursor:
row = await cursor.fetchone()
@@ -680,7 +680,7 @@ class Welcomer(commands.Cog):
@commands.cooldown(1, 6, commands.BucketType.user)
@commands.max_concurrency(1, per=commands.BucketType.default, wait=False)
async def greet_config(self, ctx):
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
async with db.execute("SELECT * FROM welcome WHERE guild_id = ?", (ctx.guild.id,)) as cursor:
row = await cursor.fetchone()
@@ -750,7 +750,7 @@ class Welcomer(commands.Cog):
return
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
await db.execute("""
UPDATE welcome
SET auto_delete_duration = ?
@@ -769,7 +769,7 @@ class Welcomer(commands.Cog):
@commands.cooldown(1, 6, commands.BucketType.user)
@commands.max_concurrency(1, per=commands.BucketType.default, wait=False)
async def greet_edit(self, ctx):
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
async with db.execute("SELECT welcome_type, welcome_message, embed_data FROM welcome WHERE guild_id = ?", (ctx.guild.id,)) as cursor:
row = await cursor.fetchone()
@@ -820,7 +820,7 @@ class Welcomer(commands.Cog):
await ctx.send("Setup was canceled. No changes were made.")
return
await new_message.delete()
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
await db.execute("UPDATE welcome SET welcome_message = ? WHERE guild_id = ?", (new_message.content, ctx.guild.id))
await db.commit()
@@ -924,7 +924,7 @@ class Welcomer(commands.Cog):
else:
embed_data_json[selected_option] = url_or_text
async with aiosqlite.connect("db/welcome.db") as db:
async with aiosqlite.connect(db_path("welcome.db")) as db:
await db.execute("UPDATE welcome SET embed_data = ? WHERE guild_id = ?", (json.dumps(embed_data_json), ctx.guild.id))
await db.commit()

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝
@@ -17,11 +16,11 @@ import json
import aiosqlite
from discord.ext import commands
from utils.config import serverLink
from core import zyrox, Cog, Context
from core import HexaHost, Cog, Context
from utils.Tools import get_ignore_data
class Errors(Cog):
def __init__(self, client: zyrox):
def __init__(self, client: HexaHost):
self.client = client
@commands.Cog.listener()

View File

@@ -1,14 +1,13 @@
# ╔══════════════════════════════════════════════════════════════════╗
# ║ ║
# ║ ░█▀▀░█▀█░█▀▄░█▀▀░█░█ ░█▀▄░█▀▀░█░█░█▀▀
# ║ ░█░░░█░█░█░█░█▀▀░▄▀▄ ░█░█░█▀▀░▀▄▀░▀▀█
# ║ ░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀ ░▀▀░░▀▀▀░░▀░░▀▀▀
# ║ +-+-+-+-+-+-+-+-+
# ║ |H|e|x|a|H|o|s|t|
# ║ +-+-+-+-+-+-+-+-+
# ║ ║
# ║ © 2026 CodeX Devs — All Rights Reserved ║
# ║ © 2026 HexaHost — All Rights Reserved
# ║ ║
# ║ discord ── https://discord.gg/codexdev
# ║ youtube ── https://youtube.com/@CodeXDevs
# ║ github ── https://github.com/RayExo ║
# ║ discord ── https://discord.gg/hexahost
# ║ github ── https://github.com/theoneandonlymace
# ║ ║
# ╚══════════════════════════════════════════════════════════════════╝

Some files were not shown because too many files have changed in this diff Show More