This commit is contained in:
alisolarflare 2016-11-05 14:05:31 -04:00
parent a4ce259249
commit c493df42c2
2 changed files with 3 additions and 5 deletions

View file

@ -9,12 +9,10 @@ public class BoomBowDeathListener implements Listener{
@EventHandler @EventHandler
public void onBoomBowDeath(PlayerDeathEvent event){ public void onBoomBowDeath(PlayerDeathEvent event){
Player player = event.getEntity(); Player player = event.getEntity();
if (player.getLastDamage() == 7.000042){
if (player.getLastDamage() > 7.42420 && player.getLastDamage() < 7.42429){
player.sendMessage("42!"); player.sendMessage("42!");
event.setDeathMessage(player.getName() + "got trigger happy with the Boom Bow"); 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");
}
} }
} }

View file

@ -95,7 +95,7 @@ public class BoomBowListener implements Listener {
//CREATE - Explosion + damage //CREATE - Explosion + damage
player.getWorld().playSound(playerLocation, Sound.ENTITY_GENERIC_EXPLODE, 10, -20); player.getWorld().playSound(playerLocation, Sound.ENTITY_GENERIC_EXPLODE, 10, -20);
player.getWorld().spawnParticle(Particle.EXPLOSION_HUGE, playerLocation, 2); player.getWorld().spawnParticle(Particle.EXPLOSION_HUGE, playerLocation, 2);
player.damage(7.000042, player); player.damage(7.42425, player);
player.sendMessage(player.getLastDamage() + ""); player.sendMessage(player.getLastDamage() + "");
boomBow.setDurability((short) (boomBow.getDurability() + 3)); boomBow.setDurability((short) (boomBow.getDurability() + 3));
if(boomBow.getDurability() < 0){ if(boomBow.getDurability() < 0){