Background music now loops instead of playing once
This commit is contained in:
parent
893294b227
commit
49072956a7
@ -37,7 +37,7 @@ public class Display extends JPanel{
|
|||||||
AudioSystem.getAudioInputStream(new URL("http://users.hszk.bme.hu/~bb1376/tomboy.wav"))) {
|
AudioSystem.getAudioInputStream(new URL("http://users.hszk.bme.hu/~bb1376/tomboy.wav"))) {
|
||||||
clip = AudioSystem.getClip();
|
clip = AudioSystem.getClip();
|
||||||
clip.open(ais);
|
clip.open(ais);
|
||||||
clip.start();
|
clip.loop(Clip.LOOP_CONTINUOUSLY);
|
||||||
}
|
}
|
||||||
catch(Exception e) {
|
catch(Exception e) {
|
||||||
e.printStackTrace(System.out);
|
e.printStackTrace(System.out);
|
||||||
|
Loading…
Reference in New Issue
Block a user