Browse Source

zone loading

lakebane-master
FatBoy-DOTC 7 months ago
parent
commit
e3c8be6102
  1. 2
      src/engine/objects/PlayerCharacter.java

2
src/engine/objects/PlayerCharacter.java

@ -2889,6 +2889,8 @@ public class PlayerCharacter extends AbstractCharacter { @@ -2889,6 +2889,8 @@ public class PlayerCharacter extends AbstractCharacter {
}
public synchronized void grantXP(int xp) {
xp *= Float.parseFloat(ConfigManager.MB_NORMAL_EXP_RATE.getValue());
// Stop players from getting experience past the cap
if (this.exp + xp >= Experience.getBaseExperience(MBServerStatics.LEVELCAP))
xp = Experience.getBaseExperience(MBServerStatics.LEVELCAP) - this.exp + 1;

Loading…
Cancel
Save