[WIP] Help With Custom Sounds

Discussion in 'Plugin Development' started by OMGursobad, Nov 21, 2013.

Thread Status:
Not open for further replies.
  1. Offline

    OMGursobad

    Hi,

    I have made a small bit of code which makes items on the ground de-spawn after a set amount of time. But I was wondering if anyone knows how to add custom sounds, so the moment the items de-spawn, a popping sound plays (the sound when you pick up and item). This is all I need to complete my plugin!

    Thanks!
     
  2. Offline

    Pik0

    when you do the de-spawn method, just play a sound to the OnlinePlayers

    Code:java
    1. Player p = Bukkit.getServer().getOnlinePlayers();
    2.  
    3. p.playSound(p.getLocation(), Sound.YOURSOUND, 4, 1);
     
  3. Offline

    clienthax

    Build against craftbukkit only if your using nms, that may fix it
     
  4. Offline

    Iroh

    Moved to plugin dev.
     
Thread Status:
Not open for further replies.

Share This Page