Forgotten Graves

Forgotten Graves

273k Downloads

[FEATURE] More experience settings

ginsm opened this issue · 4 comments

commented

As talked about in #67, the experience settings provided are somewhat lacking. I'll be working on this next; most likely adding an uncapped variant of vanilla and a percentage based version.

commented

Changes so far

  1. The experience storage types have changed as such: [ALL, DEFAULT, CUSTOM] -> [ALL, VANILLA, NONE]
  2. MaxCustomXPLevel has been renamed to levelCap.
  3. A new config option, percentage, has been added.

Storage types

ALL: All experience is calculated.
VANILLA: Experience is calculated based on the vanilla algorithm (level * 7).
NONE: Experience is always calculated as 0.

How the new system works

This can be explained in three steps:

  1. The experience is calculated based on the storage type.
  2. Said experience is multiplied by the configured percentage (and rounded).
  3. The level cap is enforced.

I'm happy with the changes thus far as I think it provides better fine tuning/customization than the previous system. Still rather untested, though.

commented

I'm debating whether percentage should be used on the experience after it's been calculated or on the level before experience calculation. Here's what each would look like:

Experience after calculation
If you're L30 when you die (1396 experience points), and have percentage set to 50, you'd end up level 22 and some change upon grave retrieval (698 experience points).

Level before calculation
If you're L30 when you die, and you have percentage set to 50, you'd end up L15 upon grave retrieval.

EDIT: I'm just going to add an option to use either levels or points for percentage calculation.

commented

Alright, I think this is feature complete and tested. It'll be part of the 3.2.0 update that should come out soon™. For now, here's the options I've settled with:

"experience": {
  "expStorageType": "ALL (Default) | VANILLA | NONE",
  "percentage": 100,
  "percentageType": "POINTS (Default) | LEVELS",
  "cap": -1,
  "capType": "LEVELS (Default) | POINTS"
},

I think this particular blend of options should be versatile and allow users to fine tune it to their liking. For example, you could tax people on death with percentage or replicate vanilla's amount of experience with this configuration:

"experience": {
  "expStorageType": "VANILLA",
  "percentage": 100,
  "percentageType": "POINTS",
  "cap": 100,
  "capType": "POINTS"
},
commented

I'm closing this as it has been added in 3.2.0 (which has been released for 1.19.2 so far, the later versions will likely come later this week).