file description module import type { HibikiClient } from "../classes/Client" ; export function rotateStatuses ( bot ) { const string = bot . localeSystem . getLocaleFunction ( bot . config . defaultLocale ) ; function getStatus ( number ) { let status = bot . config . statuses [ number ] ; switch ( status ) { case "help" : status = string ( "global.BOTSTATUS_HELP" , { prefix : bot . config . prefixes [ 0 ] } ) ; break ; case "guilds" : status = string ( "global.BOTSTATUS_GUILDS" , { guilds : bot . guilds . size } ) ; break ; case "users" : status = string ( "global.BOTSTATUS_USERS" , { users : bot . users . size } ) ; break ; case "version" : status = string ( "global.BOTSTATUS_VERSION" , { version : process . env . npm_package_version } ) ; break ; } return status ; } bot . editStatus ( "online" , { name : getStatus ( Math . floor ( rotateStatuses . length * Math . random ( ) ) ) , type : 3 , url : "https://twitch.tv/" , } ) ; setInterval ( ( ) => { bot . editStatus ( "online" , { name : getStatus ( Math . floor ( rotateStatuses . length * Math . random ( ) ) ) , type : 3 , url : "https://twitch.tv/ifyouarereadingthisyoushouldgetalife" , } ) ; } , 60000 ) ; }