41 lines
908 B
JavaScript
41 lines
908 B
JavaScript
const { Client, Guild, Events, ActivityType, PresenceUpdateStatus } = require('discord.js');
|
|
|
|
/**
|
|
*
|
|
* @param {Client} client
|
|
* @param {Guild} guild
|
|
*/
|
|
|
|
module.exports = {
|
|
name: Events.ClientReady,
|
|
async execute(client) {
|
|
const guildsCount = client.guilds.cache.size;
|
|
|
|
let status = [
|
|
{
|
|
name: "I am Live",
|
|
type: ActivityType.Watching,
|
|
},
|
|
{
|
|
name: "Choo Choo 🚂",
|
|
},
|
|
{
|
|
name: 'Hippity Hoppity',
|
|
},
|
|
{
|
|
name: `I am in ${guildsCount} Server(s)`,
|
|
},
|
|
{
|
|
name: 'Yippe 🐻'
|
|
},
|
|
];
|
|
|
|
|
|
|
|
|
|
setInterval(() => {
|
|
let random = Math.floor(Math.random() * status.length);
|
|
client.user.setActivity(status[random]);
|
|
}, 30000);
|
|
}
|
|
}; |