agility: account for bonus exp from agility pyramid
This commit is contained in:
@@ -53,8 +53,15 @@ class AgilitySession
|
||||
final int currentExp = client.getSkillExperience(Skill.AGILITY);
|
||||
final int goalXp = xpTrackerService.getEndGoalXp(Skill.AGILITY);
|
||||
final int goalRemainingXp = goalXp - currentExp;
|
||||
double courseTotalExp = course.getTotalXp();
|
||||
if (course == Courses.PYRAMID)
|
||||
{
|
||||
// agility pyramid has a bonus exp drop on the last obstacle that scales with player level and caps at 1000
|
||||
// the bonus is not already accounted for in the total exp number in the courses enum
|
||||
courseTotalExp += Math.min(300 + 8 * client.getRealSkillLevel(Skill.AGILITY), 1000);
|
||||
}
|
||||
|
||||
lapsTillGoal = goalRemainingXp > 0 ? (int) Math.ceil(goalRemainingXp / course.getTotalXp()) : 0;
|
||||
lapsTillGoal = goalRemainingXp > 0 ? (int) Math.ceil(goalRemainingXp / courseTotalExp) : 0;
|
||||
}
|
||||
|
||||
void resetLapCount()
|
||||
|
||||
Reference in New Issue
Block a user