Tweak archery distance XP function to reward better.

This commit is contained in:
gmcferrin
2013-01-29 10:55:06 -05:00
parent d2cb88d93b
commit 1e7b54ef0d
2 changed files with 4 additions and 3 deletions

View File

@ -19,9 +19,9 @@ public class ArcheryManager extends SkillManager {
public void distanceXpBonus(LivingEntity target) {
Location shooterLocation = player.getEyeLocation();
Location targetLocation = target.getLocation();
double distance = shooterLocation.distance(targetLocation);
double squaredDistance = shooterLocation.distanceSquared(targetLocation);
int bonusXp = (int) (distance * Archery.distanceXpModifer);
int bonusXp = (int) (squaredDistance * Archery.distanceXpModifer);
SkillTools.xpProcessing(player, profile, SkillType.ARCHERY, bonusXp);
}