Paper icon indicating copy to clipboard operation
Paper copied to clipboard

Implement Better Player Experience API

Open UnknownSilicon opened this issue 4 years ago • 8 comments
trafficstars

This adds a more useful API to get the total amount of experience the player currently has. This fixes #6253

Background

The current experience API allows to get the player's exp levels, percent to the next exp level, and total, lifetime experience. Some plugins need to be able to access the total number of experience points a player has at a given time. This adds Player#getCurrentExperience which does just that.

UnknownSilicon avatar Jul 25 '21 00:07 UnknownSilicon

Should it not return long instead?

imDaniX avatar Jul 25 '21 16:07 imDaniX

Yep, it should! I'll go fix that (I verified this by giving myself 3000000 xp points in game to ensure it handles it properly, which it does, therefore it should be a long)

UnknownSilicon avatar Jul 25 '21 16:07 UnknownSilicon

Does it make sense to have a setter as well?

me4502 avatar Aug 29 '21 13:08 me4502

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Oct 28 '21 16:10 stale[bot]

Bump. Any update on this?

UnknownSilicon avatar Oct 30 '21 05:10 UnknownSilicon

Bump. Any update on this?

I mean, they did ask about a setter. I think this is a good idea to have. So that is the next step really.

olijeffers0n avatar Oct 30 '21 08:10 olijeffers0n

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Dec 29 '21 09:12 stale[bot]

This issue has been automatically closed because it has not had activity in a long time. If the issue still applies to the most recent supported version, please open a new issue referencing this original issue.

stale[bot] avatar Jan 05 '22 10:01 stale[bot]