From 80bae060c6823321d039ebe3dcaa8ade567b8b9c Mon Sep 17 00:00:00 2001 From: Feildmaster Date: Thu, 9 Feb 2012 17:18:50 -0600 Subject: [PATCH] [Bleeding] Use event values for damage. --- src/main/java/net/minecraft/server/EntityEnderPearl.java | 2 +- src/main/java/net/minecraft/server/EntityWolf.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/net/minecraft/server/EntityEnderPearl.java b/src/main/java/net/minecraft/server/EntityEnderPearl.java index 0e8837285f..57b4e2f3c1 100644 --- a/src/main/java/net/minecraft/server/EntityEnderPearl.java +++ b/src/main/java/net/minecraft/server/EntityEnderPearl.java @@ -61,7 +61,7 @@ public class EntityEnderPearl extends EntityProjectile { if (!damageEvent.isCancelled()) { org.bukkit.entity.Player bPlayer = Bukkit.getPlayerExact(((EntityPlayer) this.shooter).name); ((CraftPlayer) bPlayer).getHandle().invulnerableTicks = -1; // Remove spawning invulnerability. - ((CraftPlayer) bPlayer).getHandle().damageEntity(DamageSource.FALL, 5); // Damage the new player instead of the old + ((CraftPlayer) bPlayer).getHandle().damageEntity(DamageSource.FALL, damageEvent.getDamage()); // Damage the new player instead of the old } } // CraftBukkit end diff --git a/src/main/java/net/minecraft/server/EntityWolf.java b/src/main/java/net/minecraft/server/EntityWolf.java index 3e934a80b9..2ce334612d 100644 --- a/src/main/java/net/minecraft/server/EntityWolf.java +++ b/src/main/java/net/minecraft/server/EntityWolf.java @@ -347,9 +347,9 @@ public class EntityWolf extends EntityAnimal { if (event.isCancelled()) { return; } - // CraftBukkit end - entity.damageEntity(DamageSource.mobAttack(this), b0); + entity.damageEntity(DamageSource.mobAttack(this), event.getDamage()); + // CraftBukkit end } }