Added on_ready() listener to know when Cog is ready

pull/8/head
sgoudham 4 years ago
parent b00352ed72
commit 96bf805f0c

@ -115,6 +115,11 @@ class Anime(commands.Cog):
def __init__(self, bot):
self.bot = bot
@commands.Cog.listener()
async def on_ready(self):
"""Printing out that Cog is ready on startup"""
print(f"{self.__class__.__name__} Cog has been loaded!\n-----")
@commands.group(invoke_without_command=True)
async def waifu(self, ctx, waifu=None):
"""Shows a Waifu"""

@ -92,6 +92,11 @@ class Enso(commands.Cog):
def __init__(self, bot):
self.bot = bot
@commands.Cog.listener()
async def on_ready(self):
"""Printing out that Cog is ready on startup"""
print(f"{self.__class__.__name__} Cog has been loaded\n-----")
@commands.group(invoke_without_command=True)
async def enso(self, ctx, name=None):
"""Shows Random Person from Ensō"""

@ -62,6 +62,11 @@ class Fun(commands.Cog):
def __init__(self, bot):
self.bot = bot
@commands.Cog.listener()
async def on_ready(self):
"""Printing out that Cog is ready on startup"""
print(f"{self.__class__.__name__} Cog has been loaded\n-----")
@command(name="attack", aliases=['Attack'], hidden=True)
@is_owner()
async def attack(self, ctx, target: Member):

@ -56,6 +56,11 @@ class Info(commands.Cog):
def __init__(self, bot):
self.bot = bot
@commands.Cog.listener()
async def on_ready(self):
"""Printing out that Cog is ready on startup"""
print(f"{self.__class__.__name__} Cog has been loaded\n-----")
@command(name="userinfo", aliases=["ui"])
@cooldown(1, 5, BucketType.user)
async def user_info(self, ctx, target=None):

@ -27,6 +27,11 @@ class Interactive(commands.Cog):
def __init__(self, bot):
self.bot = bot
@commands.Cog.listener()
async def on_ready(self):
"""Printing out that Cog is ready on startup"""
print(f"{self.__class__.__name__} Cog has been loaded\n-----")
@command(name="kiss", aliases=["Kiss"])
@cooldown(1, 1, BucketType.user)
async def kiss(self, ctx, member: Member):

@ -151,6 +151,11 @@ class Modmail(commands.Cog):
self.bot = bot
self.anon = None
@commands.Cog.listener()
async def on_ready(self):
"""Printing out that Cog is ready on startup"""
print(f"{self.__class__.__name__} Cog has been loaded\n-----")
@commands.group(invoke_without_command=True)
async def modmail(self, ctx):
"""Setup/Update/Delete Modmail System"""

@ -50,6 +50,11 @@ class Relationship(commands.Cog):
def __init__(self, bot):
self.bot = bot
@commands.Cog.listener()
async def on_ready(self):
"""Printing out that Cog is ready on startup"""
print(f"{self.__class__.__name__} Cog has been loaded\n-----")
@command(name="marry", aliases=["Marry"])
@cooldown(1, 1, BucketType.user)
async def marry(self, ctx, member: Member):

Loading…
Cancel
Save