Pysi Developer
Decapat
Arkadaşlar, Discord bot yazmaya karar verdim. İzlediğim bir videodan şu kodu yazdım zaten klasik kod sanırım ama "sa" yazınca bot yanıt vermiyor. Neden olabilir?
const Discord = require('discord.js');
const client = new Discord.Client();
client.on('ready', () => {
console.log(`${client.user.tag} Aktif !`);
});
client.on('message', msg => {
if (msg.content === 'sa') {
msg.reply('as');
}
});
client.login('');
const client = new Discord.Client();
client.on('ready', () => {
console.log(`${client.user.tag} Aktif !`);
});
client.on('message', msg => {
if (msg.content === 'sa') {
msg.reply('as');
}
});
client.login('');