@SuppressWarnings("deprecation")
	@EventHandler
	public void onProjectileHit(ProjectileHitEvent event) {

		Projectile projectile = event.getEntity();

		if (!(projectile instanceof Arrow))
			return;

		Arrow arrow = (Arrow)projectile;

		if (!(arrow.getShooter() instanceof Player)) {
			return;
		}

		BlockIterator bi = new BlockIterator(arrow.getWorld(), arrow.getLocation().toVector(), arrow.getVelocity().normalize(), 0, 4);

		while (bi.hasNext())
		{
			final Block hit = bi.next();

			if (!(arrow.getShooter() instanceof Player)) {
				return;
			}

			//final Player shooter = (Player) arrow.getShooter();

			if (hit.getType() == Material.GLASS || hit.getType() == Material.GLOWSTONE || hit.getType() == Material.THIN_GLASS)
			{
				this.sendBlockBreakParticles(/*(Player) arrow.getShooter(), */hit, hit.getLocation());
				
				for (Player p : Bukkit.getOnlinePlayers()) {
					p.sendBlockChange(hit.getLocation(), Material.AIR, (byte) 0);
				}
				
				arrow.remove();

				Bukkit.getServer().getScheduler().scheduleSyncDelayedTask(HyperPVP.getJavaPlugin(), new Runnable() {

					@Override
					public void run() {
						for (Player p : Bukkit.getOnlinePlayers()) {
							p.sendBlockChange(hit.getLocation(), hit.getType(), (byte) 0);
						}
					}
				}, Helpers.getSecondByTick(2));

				//hit.setType(Material.AIR);
				break;
			}
		}
	}