PVP experience only after level 75

This commit is contained in:
2024-05-21 20:43:21 -05:00
parent b66e1c1f93
commit 0d7beb5a5a
2 changed files with 15 additions and 6 deletions
+6 -2
View File
@@ -2916,7 +2916,11 @@ public class PlayerCharacter extends AbstractCharacter {
return endSpeed;
}
public synchronized void grantXP(int xp) {
public synchronized void grantXP(int xp, boolean fromPVP) {
if(this.level > 75 && !fromPVP){
return;
}
if(GroupManager.getGroup(this) == null)
xp *= 2;
@@ -4636,7 +4640,7 @@ public class PlayerCharacter extends AbstractCharacter {
tmpLevel = (short) Math.min(tmpLevel, MBServerStatics.LEVELCAP);
while (this.level < tmpLevel) {
grantXP(Experience.getBaseExperience(tmpLevel) - this.exp);
grantXP(Experience.getBaseExperience(tmpLevel) - this.exp, false);
}
}