More xp for a higher level

Hello,
I use this Code for a level system:

if (!db[message.author.id]) db[message.author.id] = {
xp: 0,
level: 0
};
db[message.author.id].xp++;
let userInfo = db[message.author.id];
if(userInfo.xp > 100) {
userInfo.level++
userInfo.xp = 0
message.reply(“Congratulations, you level up”)
}
if(command === prefix + “level”) {
let userInfo = db[message.author.id];
let member = message.mentions.members.first();
let embed1 = new Discord.RichEmbed()
.setColor(0x4286f4)
.addField(“Level”, userInfo.level)
.addField(“XP”, userInfo.xp+"/100");
if(!member) return message.channel.send(embed1)
let memberInfo = db[member.id]
let embed2 = new Discord.RichEmbed()
.setColor(0x4286f4)
.addField(“Level”, memberInfo.level)
.addField(“XP”, memberInfo.xp+"/100")
message.channel.send(embed2)
}

for every level you need 100 xp but I want that u need more xp for a higher level. Any idea how to code this?

level * 100

when u are level 50 u need 5000 exp for level up

where in the code I insert it?

if(userInfo.xp >= userInfo.level * 100) {

1 Like

and

.addField(“XP”, memberInfo.xp+"/"+userInfo.level * 100")

Thank you! @handsomebananax

ur welcome @WOLF0722