Skip to content

Commit

Permalink
新增:洛曦 直播弹幕助手 新增类型 按键映射-文案,对此类型消息支持(播放时的转发没有实现,因为类型定义没有这么细化)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ikaros-521 committed Nov 3, 2024
1 parent fe42630 commit 42747d1
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 2 deletions.
25 changes: 25 additions & 0 deletions docs/投资人/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -781,6 +781,31 @@
avatar: "https://images.cnblogs.com/cnblogs_com/ikaros-521/2328032/o_241102133508_QQ%E5%9B%BE%E7%89%8720241102213441.png",
amount: "1"
},
{
name: "Ծ‸Ծ",
avatar: "https://images.cnblogs.com/cnblogs_com/ikaros-521/2328032/o_241103045804_QQ%E5%9B%BE%E7%89%8720241103123637.jpg",
amount: "20"
},
{
name: "nbllt666",
avatar: "https://images.cnblogs.com/cnblogs_com/ikaros-521/2328032/o_241103045936_QQ%E5%9B%BE%E7%89%8720241103125910.jpg",
amount: "10"
},
{
name: "美人不胎生",
avatar: "https://images.cnblogs.com/cnblogs_com/ikaros-521/2328032/o_241103052325_QQ%E5%9B%BE%E7%89%8720241103132308.jpg",
amount: "1"
},
{
name: "蔚蓝 星空",
avatar: "https://images.cnblogs.com/cnblogs_com/ikaros-521/2328032/o_241103060445_QQ%E5%9B%BE%E7%89%8720241103140425.jpg",
amount: "233"
},
{
name: "滑稽",
avatar: "https://images.cnblogs.com/cnblogs_com/ikaros-521/2328032/o_241103060456_QQ%E5%9B%BE%E7%89%8720241103140446.jpg",
amount: "9.99"
},
];

// 对投资方数据按投资金额(amount)进行降序排序
Expand Down
Binary file modified docs/投资人/invest.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions utils/my_handle.py
Original file line number Diff line number Diff line change
Expand Up @@ -691,6 +691,7 @@ def audio_synthesis_handle(self, data_json):
song 歌曲
reread 复读
key_mapping 按键映射
key_mapping_copywriting 按键映射-文案
integral 积分
read_comment 念弹幕
gift 礼物
Expand Down Expand Up @@ -2437,6 +2438,13 @@ def get_a_copywriting_and_audio_synthesis(key_mapping_config, data):

logger.info(f'【触发按键映射】触发文案:{tmp}')

# 洛曦 直播弹幕助手
if My_handle.config.get("luoxi_project", "Live_Comment_Assistant", "enable") and \
"key_mapping_copywriting" in My_handle.config.get("luoxi_project", "Live_Comment_Assistant", "type") and \
"消息产生时" in My_handle.config.get("luoxi_project", "Live_Comment_Assistant", "trigger_position"):
asyncio.run(send_msg_to_live_comment_assistant(My_handle.config.get("luoxi_project", "Live_Comment_Assistant"), tmp))

# TODO: 播放时的转发没有实现,因为类型定义没有这么细化
self.audio_synthesis_handle(message)
except Exception as e:
logger.error(traceback.format_exc())
Expand Down
6 changes: 4 additions & 2 deletions webui.py
Original file line number Diff line number Diff line change
Expand Up @@ -4163,7 +4163,8 @@ def local_qa_text_json_file_reload():
"gift_reply",
"reread",
"schedule",
"integral"
"integral",
"key_mapping_copywriting"
]
luoxi_project_Live_Comment_Assistant_type_mapping = {
"comment": "弹幕消息",
Expand All @@ -4174,7 +4175,8 @@ def local_qa_text_json_file_reload():
"gift_reply": "礼物回复",
"reread": "复读",
"schedule": "定时任务",
"integral": "积分消息"
"integral": "积分消息",
"key_mapping_copywriting": "按键映射-文案"
}
luoxi_project_Live_Comment_Assistant_type_var = {}

Expand Down

0 comments on commit 42747d1

Please sign in to comment.