Start quiz on startup

This commit is contained in:
2020-11-10 00:54:58 +01:00
parent 6e6e3a1b34
commit 44fb2402cc

View File

@@ -94,10 +94,10 @@ class Quiz(commands.Cog):
await asyncio.sleep(random.randint(self.interval[0], self.interval[1]))
await self.ask_question()
# @commands.Cog.listener()
# async def on_ready(self):
# loop = asyncio.get_event_loop()
# task = loop.create_task(self.ask_question())
@commands.Cog.listener()
async def on_ready(self):
self.auto = True
casyncio.create_task(self.start_auto_quiz()
async def ask_question(self):