
[1.12.2 - Suggestion] Config option to apply a multiplier XP curve per level.
SonicX8000 opened this issue ยท 8 comments
Currently there's a hard value for the extra XP needed that gets added per level and in order to increase the XP needed you change the "experienceHardness" value. Thing is... the little XP it adds to that value just kinda seems off as per level it adds the XP + Interest as the level increases. An example...
If I set the "experienceHardness" 4990, at Level 1 for items/weapons that qualify... you will need 5000 XP to gain a level, however upon gaining a level the XP needed for Level 2 will become 10036 (5036), Level 3 will be 15132 (5132), Level 4 will be 20312 (5312), etc.
There's no way to change that extra XP that gets added as you level up your gear but the base XP gets added per level + interest, it may get more steep as the level rises but setting the level to... say 20 just leaves you with leftover tokens and such.
If a "Multiplier XP Scaling" config option were to be added, you can fine tune the xp curve by setting a Base XP Value and the Multiplier Value per level, for example...
Base XP Value is 100, multiplier is 2.0 per level.
Level 1 - 100 XP
Level 2 - 200 XP
Level 3 - 400 XP
Level 4 - 800 XP
Level 5 - 1600 XP
etc.
Base XP Value is 200, multiplier is 1.5 per level.
Level 1 - 200 XP
Level 2 - 300 XP
Level 3 - 450 XP
Level 4 - 675 XP
Level 5 - 1012 XP Round down from 1012.5, if that's how it works.
etc.
It'll be just like the XP curves from Tinker's Tool Leveling/Construct's Armory mods with their XP system, where you have a base value and it increases depending on the multiplier scale. Although Tinker's Tool Leveling has a hard cap of the multiplier curve being at 2.0 unless that's changed recently but you're able to change the XP Multiplier for Construct's Armory per level.
I do recall seeing an XP Weight config option in older versions of your mod but I am not sure if that was the option for the XP Curve.
Should be right, if I have the math right with what you have set... Base XP is 100 with a 1.5 Multiplier Curve... it will be like this per level up.
Level 1 - 100 XP
Level 2 - 150 XP
Level 3 - 225 XP
Level 4 - 337 XP
Level 5 - 506 XP
Level 6 - 759 XP
Level 7 - 1139 XP
Level 8 - 1708 XP
Level 9 - 2562 XP
Level 10 - 3844 XP
Is it still adding the XP onto the previous level's XP much like what it was doing before with "experienceHardness"? If it's still like that then the XP would be... if I have this correct...
Note that numbers in the parentheses is how much XP is added onto the previous level after the multiplier scales it.
Level 1 - 100 XP (N/A)
Level 2 - 250 XP (100+150)
Level 3 - 475 XP (250+225)
Level 4 - 812 XP (475+337)
Level 5 - 1318 XP (812+506)
Level 6 - 2077 XP (1318+759)
Level 7 - 3216 XP (2077+1139)
Level 8 - 4924 XP (3216+1708)
Level 9 - 7486 XP (4924+2562)
Level 10 - 11330 XP (7486+3844)
It'll be like that, correct?
Level 1 - 100 XP
Level 2 - 150 XP
Level 3 - 225 XP
Level 4 - 337 XP
Level 5 - 506 XP
Level 6 - 759 XP
Level 7 - 1139 XP
Level 8 - 1708 XP
Level 9 - 2562 XP
Level 10 - 3844 XP
it will be like this
Noticed a little issue with the way the XP curves... the XP needed for leveling up is kinda off for the first levels with the default settings.
With your current default settings... at Level 1, you need 100 XP for the item to reach the next level but when you reach Level 2... you only need 50 XP for Level 3 since at Level 2 it'll be 100/150 XP, at Level 3 you will only need 75 XP to reach the next level as it will be 150/225 XP.
XP needed for next level.
Level 1 - 100
Level 2 - 50
Level 3 - 75
Level 4 - 112
Granted you can kinda get around this by setting the multiplier higher, you could have the item's XP reset to 0 as soon as the level up occurs. Like this...
Item is Level 1 and it needs 100 XP for the next level, it gains 200 XP,... instead of being 200/225 which would would put it at Level 3, the XP resets due to gaining a level so it'll be 100/150 at Level 2.
If you wish to keep the current XP onto the counter instead of resetting it upon gaining a level, you can have the XP add onto the previous level. Like...
Level 1 - 100 XP (N/A)
Level 2 - 250 XP (100+150)
Level 3 - 475 XP (250+225)
Level 4 - 812 XP (475+337)
Level 5 - 1318 XP (812+506)
Level 6 - 2077 XP (1318+759)
Level 7 - 3216 XP (2077+1139)
Level 8 - 4924 XP (3216+1708)
Level 9 - 7486 XP (4924+2562)
Level 10 - 11330 XP (7486+3844)
...this, it's very similar with the XP being reset to zero upon gaining a level but you keep the current XP instead. You gain 200 XP so 100/150 with XP reset is the same as 200/250 without XP reset and both need only 50 XP to reach Level 3 with the current gained XP.
Not sure which one would be easier to work with.
By the way, you missed on calculating experience. For example you say:
Level 1 - 100 XP (N/A)
Level 2 - 250 XP (100+150)
Level 3 - 475 XP (250+225)
475 XP should be required for level 3- that is the addition of 250 and 225. But where did 225 come from??
Level 3 XP should be 250 + 250 * 1,5. So it is 625.