I'm looking for the function that describes how many experience points you need in Minecraft to level up.
A table of values can be found on the page linked below.
There's a picture of this function in the Minecraft wiki:
website:
https://minecraft-de.gamepedia.com/.../Erfahrung
Image:
Maybe this helps:
What do you need that for?
I want to do levels for a game in a plugin and do the levels with ingame levels
Maybe you can work it out somehow:
http://www.pernsteiner.org/minecraft/levelcalc.html
Since there are only 50 levels anyway, it would be a good idea to work directly with the table of values. You certainly don't need the XP number for non-integer levels.