10 lines
480 B
JavaScript
10 lines
480 B
JavaScript
module.exports = function(bot, api) {
|
|
bot.on('ready', async () => {
|
|
console.log("Bot initialized and listening");
|
|
const guild = await bot.guilds.fetch(process.env.GUILD);
|
|
const channel = await bot.channels.fetch(process.env.CHANNEL);
|
|
await api.joinChannel(channel);
|
|
|
|
api.speak(channel, `Hi! I'm alive. It is now ${new Date().toLocaleTimeString()} on ${new Date().toLocaleDateString()}`,api.ttsEngines.espeak, "en");
|
|
})
|
|
} |