Nutchapol
DIdiscord.js - Imagine ❄
•Created by Nutchapol on 11/28/2024 in #djs-questions
what happens to the "main listener" when using a message collector?
suppose i use a
client.on('messageCreate', ...)
(eg. for collecting DMs) and a messageCollector.on('collect', ...)
on a channel simultaneously
would the same message appear on both listeners? or would it only appear on the "most restrictive listener" (ie. the channel msg collector) or some other rule?7 replies
DIdiscord.js - Imagine ❄
•Created by Nutchapol on 11/14/2024 in #djs-voice
Typescript complains about adapterCreator after upgrading to v0.17.0
i updated
@discordjs/voice
from 0.16.1
to 0.17.0
and discord.js
from 14.14.1
to 14.16.3
, and now this snippet makes typescript complains about
how do i fix this? are there changes i missed? the changelogs for voice 0.17.0
doesn't seem to mention anything about voice adapter creators5 replies
DIdiscord.js - Imagine ❄
•Created by Nutchapol on 3/30/2023 in #djs-voice
"Cannot perform IP discovery - socket closed"
getting this error after leaving the bot on for some time
is this piece of code below related to the error? (it's a fix for the "Music Bot stops playing after about 30-40 seconds" problem from another thread, although i changed from using
Reflect.get
to directly accessing properties)
currently using discord.js
14.7.1, @discordjs/voice
0.14.0, node
19.0.13 replies
DIdiscord.js - Imagine ❄
•Created by Nutchapol on 3/29/2023 in #djs-questions
what's the boolean in Client<boolean>?
i'm using typescript and i see that Client is a generic type that takes a boolean (sub)class
what can i do with that?
8 replies
DIdiscord.js - Imagine ❄
•Created by Nutchapol on 2/12/2023 in #djs-voice
How do I stop an autopaused audio player?
title.
it doesn't look like
audioPlayer.stop()
does anything
its state doesn't change to idle too
this prevents the bot from shutting itself down5 replies
DIdiscord.js - Imagine ❄
•Created by Nutchapol on 2/1/2023 in #djs-voice
what does joinVoiceChannel return when there's already an active voice connection?
so the guide says
If you try to call joinVoiceChannel
on another channel in the same guild in which there is already an active voice connection, the existing voice connection switches over to the new channel.
does it return the same VoiceConnection
object as before changing channels (therefore, it already has event listeners attached, if any) or is it a new VoiceConnection
with the old one destroyed?5 replies