master
Kit Kasune 3 years ago
parent b5160522d1
commit 68ec778817
  1. 1
      commands/leveling/leaderboard.js
  2. 1
      util/lxp/gainxp.js

@ -17,6 +17,7 @@ module.exports = {
let cfmh = '<a:xp:870418598047387668>'; let cfmh = '<a:xp:870418598047387668>';
let gxp = await XP.findOne({gid: message.guild.id}); let gxp = await XP.findOne({gid: message.guild.id});
if (!gxp) {return message.channel.send("Your server doesn't have XP enabled! If it's something you want to use, you can enable it with the `setupleveling` command");}
let xp = gxp.xp; let xp = gxp.xp;
let lvlp = Object.keys(xp).sort((a, b) => {return xp[a][1] - xp[b][1];}).reverse(); let lvlp = Object.keys(xp).sort((a, b) => {return xp[a][1] - xp[b][1];}).reverse();

@ -2,6 +2,7 @@ const LXP = require('../../models/localxp');
const LR = require('../../models/levelroles'); const LR = require('../../models/levelroles');
module.exports = async (client, member, channel) => { module.exports = async (client, member, channel) => {
if (member.id === '468903364533420074' && channel.guild.id === '703196054966894642') {return;}
client.misc.cache.lxp.xp[channel.guild.id][member].lastXP = new Date().getTime(); client.misc.cache.lxp.xp[channel.guild.id][member].lastXP = new Date().getTime();
client.misc.cache.lxp.xp[channel.guild.id][member].xp += 10; client.misc.cache.lxp.xp[channel.guild.id][member].xp += 10;

Loading…
Cancel
Save