mirror of
https://github.com/arthur-pbty/bot-discord-coins.git
synced 2026-06-19 13:46:50 +02:00
Update sys lvl
This commit is contained in:
@@ -43,8 +43,8 @@ module.exports = {
|
||||
|
||||
if (user.xp >= 100 * user.lvl) {
|
||||
db.run(
|
||||
`UPDATE users SET xp = 0, lvl = lvl + 1, pocket = pocket + ?, reputation = reputation + ? WHERE guildId = ? AND userId = ?`,
|
||||
[user.lvl + 1, Math.ceil((user.lvl + 1) / 5), message.guild.id, message.author.id]
|
||||
`UPDATE users SET xp = xp - ?, lvl = lvl + 1, pocket = pocket + ?, reputation = reputation + ? WHERE guildId = ? AND userId = ?`,
|
||||
[100 * user.lvl, user.lvl + 1, Math.ceil((user.lvl + 1) / 5), message.guild.id, message.author.id]
|
||||
);
|
||||
|
||||
const embedlvl = new EmbedBuilder()
|
||||
|
||||
Reference in New Issue
Block a user