From 001914740707142564103342a8884d0132b0cb74 Mon Sep 17 00:00:00 2001 From: WubzyGD Date: Tue, 8 Jun 2021 21:05:03 -0600 Subject: [PATCH] things are done --- commands/dev/reload.js | 6 +++--- commands/leveling/stats.js | 2 +- commands/social/afk.js | 1 + commands/social/dnd.js | 1 + util/lxp/gainxp.js | 2 +- 5 files changed, 7 insertions(+), 5 deletions(-) diff --git a/commands/dev/reload.js b/commands/dev/reload.js index 5b84f4a..9b48e2c 100644 --- a/commands/dev/reload.js +++ b/commands/dev/reload.js @@ -38,7 +38,7 @@ module.exports = { if (command.aliases) {command.aliases.forEach(a => client.aliases.set(a, command.name));} } cmdspinner.stop(); cmdspinner.clear(); - console.log(`${chalk.gray('[LOG]')} >> ${chalk.blue('Loaded all Commands')}`); + console.log(`${chalk.gray('[PROC]')} >> ${chalk.blue('Loaded all Commands')}`); let eventspinner = ora(chalk.blue('Loading Events')).start(); let eventFilter = fs.readdirSync('./events/').filter(x => x.endsWith('.js')); @@ -50,7 +50,7 @@ module.exports = { client.on(evtName, evt.bind(null, client)); } eventspinner.stop(); eventspinner.clear(); - console.log(`${chalk.gray('[LOG]')} >> ${chalk.blue('Loaded all Events')}`); + console.log(`${chalk.gray('[PROC]')} >> ${chalk.blue('Loaded all Events')}`); let rspspinner = ora(chalk.blue('Loading Commands')).start(); let responses = fs.readdirSync('./responses').filter(file => file.endsWith('.js')); @@ -62,7 +62,7 @@ module.exports = { client.responses.commands.set(response.name, response); } rspspinner.stop(); rspspinner.clear(); - console.log(`${chalk.gray('[LOG]')} >> ${chalk.blue('Loaded all Responses')}`); + console.log(`${chalk.gray('[PROC]')} >> ${chalk.blue('Loaded all Responses')}`); console.log(`\n${chalk.gray('[INFO]')} >> ${chalk.hex('ff4fd0')(`Client refresh successful`)}\n`); diff --git a/commands/leveling/stats.js b/commands/leveling/stats.js index 34fed78..af9bc1b 100644 --- a/commands/leveling/stats.js +++ b/commands/leveling/stats.js @@ -31,7 +31,7 @@ module.exports = { .setTitle(`${u.displayName}${u.displayName.toLowerCase().endsWith('s') ? "'" : "'s"} Stats`) .setDescription("Local leveling stats") .addField("Level", xp.level, true) - .addField("XP", `**${xp.xp}** of **${Math.ceil(100 + (((xp.level / 3) ** 2) * 2))}** needed to level up`, true) + .addField("XP", `**${xp.xp}** of **${Math.ceil(100 + (((x / 2.85) ** 2.2) * 2.5))}** needed to level up`, true) .setThumbnail(client.users.cache.get(u.id).avatarURL({size: 2048})) .setColor("328ba8") .setFooter("Luno") diff --git a/commands/social/afk.js b/commands/social/afk.js index 56b0e09..2a6e874 100644 --- a/commands/social/afk.js +++ b/commands/social/afk.js @@ -30,6 +30,7 @@ module.exports = { if (!args.length) {return message.channel.send(`Syntax: \`${prefix}afk [clearMode] \``);} let reason = args.join(" "); if (reason.length > 150) {return message.reply("That status a bit long; keep it under 150 characters.");} + if (reason.match(/<@&\d+>|@everyone/gm)) {return message.reply("I won't ping any roles or @ everyone!");} tu.statustype = 'afk'; tu.statusmsg = reason.trim(); tu.statussetat = new Date(); diff --git a/commands/social/dnd.js b/commands/social/dnd.js index 775ca6a..1e566cd 100644 --- a/commands/social/dnd.js +++ b/commands/social/dnd.js @@ -28,6 +28,7 @@ module.exports = { if (!args.length) {return message.channel.send(`Syntax: \`${prefix}afk [clearMode] \``);} let reason = args.join(" "); if (reason.length > 150) {return message.reply("That status a bit long; keep it under 150 characters.");} + if (reason.match(/<@&\d+>|@everyone/gm)) {return message.reply("I won't ping any roles or @ everyone!");} tu.statustype = 'dnd'; tu.statusmsg = reason.trim(); tu.statussetat = new Date(); diff --git a/util/lxp/gainxp.js b/util/lxp/gainxp.js index 85ab5da..f6f0b45 100644 --- a/util/lxp/gainxp.js +++ b/util/lxp/gainxp.js @@ -6,7 +6,7 @@ module.exports = async (client, member, channel) => { client.misc.cache.lxp.xp[channel.guild.id][member].xp += 10; let x = client.misc.cache.lxp.xp[channel.guild.id][member].level; - let max = Math.ceil(100 + (((x / 3) ** 2) * 2)); + let max = Math.ceil(100 + (((x / 2.85) ** 2.2) * 2.5)); if (client.misc.cache.lxp.xp[channel.guild.id][member].xp > max) { client.misc.cache.lxp.xp[channel.guild.id][member].xp -= max;