新增say指令

This commit is contained in:
2025-10-30 14:27:38 +08:00
parent 8ffd261bb0
commit 927c16e1fc
2 changed files with 14 additions and 0 deletions

View File

@@ -193,6 +193,15 @@ async def handle_command(game_type: str, command: str,
game = GiftGame()
return await game.handle(command, chat_id, user_id)
# 复述功能
if game_type == 'say':
# 提取参数并原样返回
_, args = CommandParser.extract_command_args(command)
args = args.strip()
if not args:
return "用法:.say 你想让我说的话\n别名:.说 / .复述"
return args
# AI对话系统
if game_type == 'ai_chat':
from games.ai_chat import AIChatGame

View File

@@ -68,6 +68,11 @@ class CommandParser:
'.ai': 'ai_chat',
'.aiconfig': 'ai_chat',
# 复述
'.say': 'say',
'.说': 'say',
'.复述': 'say',
# 帮助
'.help': 'help',
'.帮助': 'help',