}
String extension = Url.substring(Url.length() - 4, Url.length());
if (extension.equalsIgnoreCase(".ogg") || extension.equalsIgnoreCase(".wav") || extension.equalsIgnoreCase(".mp3") || extension.matches(".*[mM][iI][dD][iI]?$")) {
if (location == null || location.getWorld().equals(target.getWorld())) {
if (!soundEffect) {
BackgroundMusicEvent event = new BackgroundMusicEvent(Url, volumePercent, target);
Bukkit.getServer().getPluginManager().callEvent(event);
if (event.isCancelled()) {
return;
}
volumePercent = event.getVolumePercent();
}
SpoutCraftPlayer ccp = (SpoutCraftPlayer) target;
ccp.sendPacket(new PacketDownloadMusic(plugin != null ? plugin.getDescription().getName() : "temp", Url, location, distance, volumePercent, soundEffect, notify));
}
} else {