我想讓機器人檢測用戶何時說話。在不和諧的文檔中我看到我需要使用該事件guildMemberSpeaking。這是代碼:const Discord = require('discord.js');const client = new Discord.Client();client.once('ready', () => { console.log('Talkover is online!');})// Joins the voice channel with every tekstclient.on('message', async message => { // Join the same voice channel of the author of the message if (message.member.voice.channel) { const connection = await message.member.voice.channel.join(); }});client.on('guildMemberSpeaking', (member, speaking) => { if (speaking) { console.log('speaking'); } else { console.log('notspeaking'); }});由于某種原因,消息有效,但公會成員無法說話。我不知道我做錯了什么。
Discord BOT,guildMemberSpeaking 事件不起作用
LEATH
2023-07-20 16:27:14