변상훈
변상훈
DIdiscord.js - Imagine ❄
Created by 변상훈 on 1/16/2025 in #djs-questions
button interaction response problem
When responding to a button interaction, I am trying to disable the clicked button, but the following error keeps occurring. The label is already set during its creation.
6 replies
DIdiscord.js - Imagine ❄
Created by 변상훈 on 1/15/2025 in #djs-questions
Does Discord.js natively support a debouncer or similar feature to prevent excessive button inputs?
I am curious if Discord.js provides native support for a debouncer to handle issues like excessive button inputs. If not, are there alternative features or approaches available to address this problem?
6 replies
DIdiscord.js - Imagine ❄
Created by 변상훈 on 1/14/2025 in #djs-questions
slash command deploy
I think the function for deploying slash commands is not working properly. I want to know what the issue is.
22 replies
DIdiscord.js - Imagine ❄
Created by 변상훈 on 1/14/2025 in #djs-questions
When my bot receives DMs:
Initially, when the bot is invited to a guild, it can receive DM messages without any issues. However, after the bot is rebooted, it cannot receive DMs anymore. Has anyone experienced a similar situation and found a solution? Any help would be greatly appreciated!
7 replies
DIdiscord.js - Imagine ❄
Created by 변상훈 on 10/9/2022 in #djs-voice
tts not reading without undefined
client.on("messageCreate", async (msg)=>{
const prefix = "!"
const args = msg.content.slice(prefix.length).trim().split(/ +/);
let txtr = args[1]
console.log(txtr)
console.log(args)

if(msg.content == "!say")
{


const stream = discordTTS.getVoiceStream(txtr);
const audioResource=createAudioResource(stream, {inputType: StreamType.Arbitrary, inlineVolume:true});
if(!voiceConnection || voiceConnection?.status===VoiceConnectionStatus.Disconnected){
voiceConnection = joinVoiceChannel({
channelId: msg.member.voice.channelId,
guildId: msg.guildId,
adapterCreator: msg.guild.voiceAdapterCreator,
});
voiceConnection=await entersState(voiceConnection, VoiceConnectionStatus.Connecting, 5_000);
}

if(voiceConnection.status===VoiceConnectionStatus.Connected){
voiceConnection.subscribe(audioPlayer);
audioPlayer.play(audioResource);
}
}
});
client.on("messageCreate", async (msg)=>{
const prefix = "!"
const args = msg.content.slice(prefix.length).trim().split(/ +/);
let txtr = args[1]
console.log(txtr)
console.log(args)

if(msg.content == "!say")
{


const stream = discordTTS.getVoiceStream(txtr);
const audioResource=createAudioResource(stream, {inputType: StreamType.Arbitrary, inlineVolume:true});
if(!voiceConnection || voiceConnection?.status===VoiceConnectionStatus.Disconnected){
voiceConnection = joinVoiceChannel({
channelId: msg.member.voice.channelId,
guildId: msg.guildId,
adapterCreator: msg.guild.voiceAdapterCreator,
});
voiceConnection=await entersState(voiceConnection, VoiceConnectionStatus.Connecting, 5_000);
}

if(voiceConnection.status===VoiceConnectionStatus.Connected){
voiceConnection.subscribe(audioPlayer);
audioPlayer.play(audioResource);
}
}
});
when use command just !say the voice say undefined but when i use !say hello nothing. what is problem??
12 replies
DIdiscord.js - Imagine ❄
Created by 변상훈 on 9/26/2022 in #djs-voice
bot mute when join voice channel.
10 replies