Health and damage are now doubles, not ints.

This commit is contained in:
GJ
2013-07-11 12:43:36 -04:00
parent 4dc9c97978
commit d07b67b5bf
17 changed files with 65 additions and 65 deletions

View File

@ -11,7 +11,7 @@ public class AwardCombatXpTask extends BukkitRunnable {
private double baseXp;
private SkillType skillType;
private LivingEntity target;
private int baseHealth;
private double baseHealth;
public AwardCombatXpTask(McMMOPlayer mcMMOPlayer, SkillType skillType, double baseXp, LivingEntity target) {
this.mcMMOPlayer = mcMMOPlayer;
@ -23,8 +23,8 @@ public class AwardCombatXpTask extends BukkitRunnable {
@Override
public void run() {
int health = target.getHealth();
int damage = baseHealth - health;
double health = target.getHealth();
double damage = baseHealth - health;
// May avoid negative xp, we don't know what other plugins do with the entity health
if (damage <= 0) {