From a7b14df9ef54fa1f32729d10de9f760030df2d1f Mon Sep 17 00:00:00 2001 From: Adam Gessaman Date: Mon, 29 Dec 2025 16:01:11 -0800 Subject: [PATCH] Enhance magic8 command response formatting Format the magic8 command response based on message type. --- modules/commands/{magic8.py => magic8_command.py} | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) rename modules/commands/{magic8.py => magic8_command.py} (81%) diff --git a/modules/commands/magic8.py b/modules/commands/magic8_command.py similarity index 81% rename from modules/commands/magic8.py rename to modules/commands/magic8_command.py index 8f8eaf0..304cafc 100644 --- a/modules/commands/magic8.py +++ b/modules/commands/magic8_command.py @@ -36,4 +36,13 @@ class Magic8Command(BaseCommand): async def execute(self, message: MeshMessage) -> bool: """Execute the magic8 command""" answer = magic8() - return await self.send_response(message, answer) + + # Format response with sender mention for channel messages, without for DMs + if message.is_dm: + response = f"🎱 {answer}" + else: + sender = message.sender_id or "Unknown" + response = f"🎱 @[{sender}] {answer}" + + return await self.send_response(message, response) +