mirror of
https://gitlab.com/phoenix-dvpmt/mmocore.git
synced 2024-11-24 00:15:16 +01:00
!Added safe checks, updated version nb
This commit is contained in:
parent
fb86db6437
commit
61d297412a
2
pom.xml
2
pom.xml
@ -2,7 +2,7 @@
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>net.Indyuce</groupId>
|
||||
<artifactId>MMOCore</artifactId>
|
||||
<version>1.2.5</version>
|
||||
<version>1.3</version>
|
||||
<description>Offer your players a brand new RPG experience.</description>
|
||||
|
||||
<properties>
|
||||
|
@ -246,7 +246,7 @@ public class PlayerData extends OfflinePlayerData {
|
||||
public void refreshVanillaExp() {
|
||||
if (MMOCore.plugin.configManager.overrideVanillaExp) {
|
||||
player.setLevel(getLevel());
|
||||
player.setExp((float) experience / (float) getLevelUpExperience());
|
||||
player.setExp(Math.max(0, Math.min(1, (float) experience / (float) getLevelUpExperience())));
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user