mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-05 18:27:17 +01:00
Add API to get a players experience to level (getExpToLevel). Implements BUKKIT-1906
This is the total experience one needs to gain a level. By: feildmaster <admin@feildmaster.com>
This commit is contained in:
parent
ef912f9658
commit
5601006d64
2 changed files with 11 additions and 0 deletions
|
@ -146,4 +146,11 @@ public interface HumanEntity extends LivingEntity, AnimalTamer, Permissible, Inv
|
|||
* @return Whether they are blocking.
|
||||
*/
|
||||
public boolean isBlocking();
|
||||
|
||||
/**
|
||||
* Get the total amount of experience required for the player to level
|
||||
*
|
||||
* @return Experience required to level up
|
||||
*/
|
||||
public int getExpToLevel();
|
||||
}
|
||||
|
|
|
@ -764,4 +764,8 @@ public class TestPlayer implements Player {
|
|||
public boolean isValid() {
|
||||
throw new UnsupportedOperationException("Not supported yet.");
|
||||
}
|
||||
|
||||
public int getExpToLevel() {
|
||||
throw new UnsupportedOperationException("Not supported yet.");
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue