From c493df42c2f2e2a25b7ac2b364c3357f087b7d1d Mon Sep 17 00:00:00 2001 From: alisolarflare Date: Sat, 5 Nov 2016 14:05:31 -0400 Subject: [PATCH] The fix --- src/alisolarflare/magic/tricks/BoomBowDeathListener.java | 6 ++---- src/alisolarflare/magic/tricks/BoomBowListener.java | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/src/alisolarflare/magic/tricks/BoomBowDeathListener.java b/src/alisolarflare/magic/tricks/BoomBowDeathListener.java index c436a97..4380414 100644 --- a/src/alisolarflare/magic/tricks/BoomBowDeathListener.java +++ b/src/alisolarflare/magic/tricks/BoomBowDeathListener.java @@ -9,12 +9,10 @@ public class BoomBowDeathListener implements Listener{ @EventHandler public void onBoomBowDeath(PlayerDeathEvent event){ Player player = event.getEntity(); - if (player.getLastDamage() == 7.000042){ + + if (player.getLastDamage() > 7.42420 && player.getLastDamage() < 7.42429){ player.sendMessage("42!"); event.setDeathMessage(player.getName() + "got trigger happy with the Boom Bow"); } - if (player.getLastDamage() < 7.000041 || player.getLastDamage() > 7.000043){ - player.sendMessage("meaning of lyyyyyyfffe"); - } } } diff --git a/src/alisolarflare/magic/tricks/BoomBowListener.java b/src/alisolarflare/magic/tricks/BoomBowListener.java index a2560c6..5e74bd8 100644 --- a/src/alisolarflare/magic/tricks/BoomBowListener.java +++ b/src/alisolarflare/magic/tricks/BoomBowListener.java @@ -95,7 +95,7 @@ public class BoomBowListener implements Listener { //CREATE - Explosion + damage player.getWorld().playSound(playerLocation, Sound.ENTITY_GENERIC_EXPLODE, 10, -20); player.getWorld().spawnParticle(Particle.EXPLOSION_HUGE, playerLocation, 2); - player.damage(7.000042, player); + player.damage(7.42425, player); player.sendMessage(player.getLastDamage() + ""); boomBow.setDurability((short) (boomBow.getDurability() + 3)); if(boomBow.getDurability() < 0){