Advertisement
Guest User

[Java] Playing Sound

a guest
May 21st, 2013
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.33 KB | None | 0 0
  1. // If the left mouse button is held down, create a new projectile.
  2. if(Globals.buttons[0] && !player.isOnCooldown()) {
  3.     createParticle(pAngle);
  4.     Runnable soundPlayThread = new Runnable() {
  5.         @Override
  6.         public void run() {
  7.             Sounds.RIFLE.play();
  8.         }
  9.     };
  10.     new Thread(soundPlayThread).start();
  11. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement