The helper bot for LHT https://lhtranslation.net
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
Senko/bot/startup/run/setstatus.js

24 lines
1020 B

module.exports = client => {
const prefix = client.basePrefix;
const statuses = {
"PLAYING": [
`with fluffy tails!`, `with some new recipes`,
`cleaning up PRs' rooms`, `cleaning up TLs' rooms`,
`with Kitsuu's sanity (I won't stop crashing)`
],
"WATCHING": [
`over the lovely members of LHT!`, `my tail get fluffed`,
`tonight's dinner cook`, `LHT staff do great work!`
]
};
try {if (client.misc.statusTimeout) {clearTimeout(client.misc.statusTimeout)};} catch {}
const setStatus = () => {
let type = Object.keys(statuses)[Math.floor(Math.random() * Object.keys(statuses).length)];
if (type === "PLAYING") {client.user.setActivity(statuses[type][Math.floor(Math.random() * statuses[type].length)] + " | " + prefix + "help");}
else {client.user.setActivity(statuses[type][Math.floor(Math.random() * statuses[type].length)] + " | " + prefix + "help", {type: type});}
};
setStatus();
client.misc.statusTimeout = setTimeout(setStatus, 14400000);
};