Mapache2212 Games
Mapache2212 Games
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
Okay, that's your opinion. The matter is closed.
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
.
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
could have connect it into my code
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
and you thank you @Alexcitten
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
I undestand
client.on("messageCreate", opa => {
if (opa.content === 'teti') {
let guild = opa.guild;
guild.members.fetch().then(members => {
members.forEach(member => {
console.log(member.user.username);
});
}).catch(console.error);
}
});
client.on("messageCreate", opa => {
if (opa.content === 'teti') {
let guild = opa.guild;
guild.members.fetch().then(members => {
members.forEach(member => {
console.log(member.user.username);
});
}).catch(console.error);
}
});
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
thx
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
My quietion: How do I get a list of members in a guild? I need the names of the participants, I would like to get everyone
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
They didn't answer my question
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
.
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
Ok
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
If I didn’t understand something, I always searched on the Internet or asked a friend
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
._.
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
I completed the entire Javascript tutorial learn.javascript.com
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
This I don't understand
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
const foldersPath = path.join(__dirname, 'commands');
const commandFolders = fs.readdirSync(foldersPath);

for (const folder of commandFolders) {
const commandsPath = path.join(foldersPath, folder);
const commandFiles = fs.readdirSync(commandsPath).filter(file => file.endsWith('.js'));
for (const file of commandFiles) {
const filePath = path.join(commandsPath, file);
const command = require(filePath);
// Set a new item in the Collection with the key as the command name and the value as the exported module
if ('data' in command && 'execute' in command) {
client.commands.set(command.data.name, command);
} else {
console.log(`[WARNING] The command at ${filePath} is missing a required "data" or "execute" property.`);
}
}
}
const foldersPath = path.join(__dirname, 'commands');
const commandFolders = fs.readdirSync(foldersPath);

for (const folder of commandFolders) {
const commandsPath = path.join(foldersPath, folder);
const commandFiles = fs.readdirSync(commandsPath).filter(file => file.endsWith('.js'));
for (const file of commandFiles) {
const filePath = path.join(commandsPath, file);
const command = require(filePath);
// Set a new item in the Collection with the key as the command name and the value as the exported module
if ('data' in command && 'execute' in command) {
client.commands.set(command.data.name, command);
} else {
console.log(`[WARNING] The command at ${filePath} is missing a required "data" or "execute" property.`);
}
}
}
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
Yes
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
The tutorial shows that the command handler searches only for a folder with a specific name, I would like to remake this handler for myself. But I don't understand how it works.
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
Command handler
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
I don't understand your question
81 replies
DIAdiscord.js - Imagine an app
Created by Mapache2212 Games on 12/13/2023 in #djs-questions
List member (Question resolved)
Slash command creator not working in guide
81 replies