Adding debug
This commit is contained in:
parent
b4e4437171
commit
316ff36b8f
@ -51,11 +51,10 @@ class ReginaldCog(commands.Cog):
|
|||||||
)
|
)
|
||||||
|
|
||||||
@commands.Cog.listener()
|
@commands.Cog.listener()
|
||||||
async def on_message(self, message):
|
async def on_message(self, message, ctx):
|
||||||
if message.author.bot or not message.guild:
|
if message.author.bot or not message.guild:
|
||||||
return # Ignore bots and DMs
|
return # Ignore bots and DMs
|
||||||
|
|
||||||
await self.bot.process_commands(message) # ✅ Ensure commands still work
|
|
||||||
|
|
||||||
guild = message.guild
|
guild = message.guild
|
||||||
channel_id = str(message.channel.id)
|
channel_id = str(message.channel.id)
|
||||||
@ -66,6 +65,7 @@ class ReginaldCog(commands.Cog):
|
|||||||
# ✅ Fetch the stored listening channel or fall back to default
|
# ✅ Fetch the stored listening channel or fall back to default
|
||||||
allowed_channel_id = await self.config.guild(guild).listening_channel()
|
allowed_channel_id = await self.config.guild(guild).listening_channel()
|
||||||
if not allowed_channel_id:
|
if not allowed_channel_id:
|
||||||
|
ctx.send("<deciding channel is not cool>")
|
||||||
allowed_channel_id = self.default_listening_channel
|
allowed_channel_id = self.default_listening_channel
|
||||||
await self.config.guild(guild).listening_channel.set(allowed_channel_id)
|
await self.config.guild(guild).listening_channel.set(allowed_channel_id)
|
||||||
|
|
||||||
@ -98,6 +98,7 @@ class ReginaldCog(commands.Cog):
|
|||||||
explicit_invocation = False
|
explicit_invocation = False
|
||||||
|
|
||||||
else:
|
else:
|
||||||
|
ctx.send("<decided not to interject>")
|
||||||
return # Ignore irrelevant messages
|
return # Ignore irrelevant messages
|
||||||
|
|
||||||
# ✅ Context Handling: Maintain conversation flow
|
# ✅ Context Handling: Maintain conversation flow
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user