PVP experience only after level 75
This commit is contained in:
@@ -161,12 +161,12 @@ public class VendorDialogMsg extends ClientNetMsg {
|
|||||||
}
|
}
|
||||||
playerCharacter.isBoxed = false;
|
playerCharacter.isBoxed = false;
|
||||||
playerCharacter.title = CharacterTitle.NONE;
|
playerCharacter.title = CharacterTitle.NONE;
|
||||||
InterestManager.reloadCharacter(playerCharacter);
|
InterestManager.setObjectDirty(playerCharacter);
|
||||||
playerCharacter.removeEffectBySource(Enum.EffectSourceType.DeathShroud,50,true);
|
playerCharacter.removeEffectBySource(Enum.EffectSourceType.DeathShroud,50,true);
|
||||||
for(PlayerCharacter box : currentBoxes) {
|
for(PlayerCharacter box : currentBoxes) {
|
||||||
box.isBoxed = true;
|
box.isBoxed = true;
|
||||||
box.title = CharacterTitle.BOX;
|
box.title = CharacterTitle.BOX;
|
||||||
InterestManager.reloadCharacter(box);
|
InterestManager.setObjectDirty(box);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Dispatch dispatch = Dispatch.borrow(playerCharacter, msg);
|
Dispatch dispatch = Dispatch.borrow(playerCharacter, msg);
|
||||||
|
|||||||
@@ -460,7 +460,8 @@ public class Experience {
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
// Get XP and adjust for Mob Level with world xp modifier taken into account
|
// Get XP and adjust for Mob Level with world xp modifier taken into account
|
||||||
grantedExperience = (double) LOOTMANAGER.NORMAL_EXP_RATE * maxXPPerKill(killer.getLevel());
|
float mdofier = LOOTMANAGER.NORMAL_EXP_RATE;
|
||||||
|
grantedExperience = maxXPPerKill(killer.getLevel());
|
||||||
grantedExperience *= getConMod(killer, mob);
|
grantedExperience *= getConMod(killer, mob);
|
||||||
|
|
||||||
// Modify for hotzone
|
// Modify for hotzone
|
||||||
|
|||||||
@@ -1827,20 +1827,18 @@ public class PlayerCharacter extends AbstractCharacter {
|
|||||||
//see if we shold grant xp to attacker
|
//see if we shold grant xp to attacker
|
||||||
boolean doPVPEXP = false;
|
boolean doPVPEXP = false;
|
||||||
long lastKill = att.getLastKillOfTarget(this.getObjectUUID());
|
long lastKill = att.getLastKillOfTarget(this.getObjectUUID());
|
||||||
if ((System.currentTimeMillis() - lastKill) > MBServerStatics.PLAYER_KILL_XP_TIMER)
|
|
||||||
if (attacker.getLevel() > 39 && this.getLevel() > 39) {
|
Guild aN = null;
|
||||||
Guild aN = null;
|
Guild tN = null;
|
||||||
Guild tN = null;
|
if (attacker.getGuild() != null)
|
||||||
if (attacker.getGuild() != null)
|
aN = attacker.getGuild().getNation();
|
||||||
aN = attacker.getGuild().getNation();
|
if (this.getGuild() != null)
|
||||||
if (this.getGuild() != null)
|
tN = this.getGuild().getNation();
|
||||||
tN = this.getGuild().getNation();
|
|
||||||
if (aN == null || tN == null || aN.isEmptyGuild() || Guild.sameGuild(aN, tN) || this.isDeathShroud()) {
|
if (aN != null || tN != null || !aN.equals(tN) || !this.isDeathShroud()) {
|
||||||
//skip giving xp if same guild or attacker is errant, or target is in death shroud.
|
doPVPEXP = true;
|
||||||
} else {
|
}
|
||||||
doPVPEXP = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
//apply death shroud to non safeholds.
|
//apply death shroud to non safeholds.
|
||||||
Zone zone = ZoneManager.findSmallestZone(this.getLoc());
|
Zone zone = ZoneManager.findSmallestZone(this.getLoc());
|
||||||
|
|
||||||
@@ -2926,8 +2924,9 @@ public class PlayerCharacter extends AbstractCharacter {
|
|||||||
xp *= 2;
|
xp *= 2;
|
||||||
|
|
||||||
// Stop players from getting experience past the cap
|
// Stop players from getting experience past the cap
|
||||||
if (this.exp + xp >= Experience.getBaseExperience(MBServerStatics.LEVELCAP))
|
int levelCap = MBServerStatics.LEVELCAP;
|
||||||
xp = Experience.getBaseExperience(MBServerStatics.LEVELCAP) - this.exp + 1;
|
if (this.exp + xp >= Experience.getBaseExperience(levelCap))
|
||||||
|
xp = Experience.getBaseExperience(levelCap) - this.exp + 1;
|
||||||
|
|
||||||
if (xp == 0)
|
if (xp == 0)
|
||||||
xp = 1;
|
xp = 1;
|
||||||
|
|||||||
Reference in New Issue
Block a user