Files
yenai-plugin/apps/events/input.js
2023-04-11 20:04:57 +08:00

15 lines
490 B
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
import { common } from '../../model/index.js'
import { Config } from '../../components/index.js'
Bot.on('internal.input', async (e) => {
if (!Config.Notice.input) return false
// 判断是否主人消息
if (Config.masterQQ.includes(e.user_id)) return false
let msg = [
segment.image(`https://q1.qlogo.cn/g?b=qq&s=100&nk=${e.user_id}`),
`[事件 - 对方${e.end ? '输入完毕' : '正在输入'}]\n`,
`好友QQ${e.user_id}`
]
await common.sendMasterMsg(msg)
})