so I have just finished this /setnick command for my Discord Bot, but I am getting the following error. I have tried looking for solutions on google and here on StackOverflow but I couldn’t find any regarding my problem. Does anyone know what the fix for this is? Here is the /setnick command file: Answer Should be
Tag: discord.js
Problems playing audio files in Discord
So, It’s been two long days traying to figure what the reck is going on… I’m creating a Bot to my Discord Channel that plays an audio.mp3 when a command is written, like !laugh then the bot should enter the voice channel and reproduce laugh.mp3. I’ve tried in so manny different ways but the bot keeps entering the channel, the
Discord.js search nearest result of an argument
Im not sure if this question has been posted yet but here is what i wanna make: So im trying to make something that find the nearest result of an argument.(Discord.js v13) But i have no idea on how to make it,is there a Code or an API for this feature? For example: !find rock If Rock is in the
Discord bot not fetching user data even when user id is there
I am using discord v13.6.0 . I have a 2d array in which data looks like this Here is my code . Now I am getting a error here. My code shows me curretName but it is giving me a error for the nextUserName. My error is this TypeError: Cannot read properties of undefined (reading ‘username’) at E:DiscordBotTestingLeaderBoardLeaderboardRankingsystem.js:217:42 I am
How to put text and get audio discord.js like google translate?
Is there a way or a module on discord.js that allows you to say vocally some text? I would need it to make a kind of voice log, a trivial example would be that when someone connects to a voice channel the bot says “$username has entered the voice channel”. Does anyone know how to do this? I would also
Discord.js v13 How to prevent mod commands from working on mods?
So I wanted to make a mute command for my Discord bot. It is supposed to mute a mentioned user untill they are unmuted through another command (WIP), additionaly there should be an option to give a reason. If there is no reason provided it just says Reason: none. I’ve managed to Restrict the command acces to a mod role
(discord.js) Problem listing all the members
This function never returns anything. Can you help me? Answer As Cameron said in the comments you need to enable the GUILD_MEMBERS and the GUILDS intent from your Client constructer by listing it in the intents property of the Client Options like so
How to get users in voice channel without cache in DiscordJS?
I’m trying to get all users connected to a voice channel on my server. When someone talks to a bot in #general, I want to get the users inside Voice Channel 1. I’m using Node 17 and DiscordJS 13. This is my code: Also, I tried this one: But, it always returns the voice channel users that joined when I
How to run a copy of a Discord bot through a proxy?
I have a Discord bot written in discord.js. I created a referral system so that everyone can create a copy of my Discord bot with their own token, but there was a small problem. I don’t know how to run a copy of my Discord bot through a proxy so that there are several identical bots from one VPS, but
discordjs v13 – subtract the variable
The code doesn’t work when it subtract the variable (enemy’s health) This is my code I wonder at the damage – ene_health why it doesn’t subtract the enemy’s health I am using discord.js v13 and quickdb Answer isn’t doing anything. In your case you have to CHANGE the damage variable. or even better, use the Substract assignment :