Esempio n. 1
0
  public void stop() {
    log.warn("Stopping");
    // make sure the start sound is killed
    if (use_start_sound) {
      start_sound.stop();
    }

    // If the mid sound is used, turn off the looping.
    // this will allow it to naturally die.
    if (use_mid_sound) {
      mid_sound.setLooped(false);
      mid_sound.fadeOut();
    }

    // If the timer is running, stop it.
    if (t != null) {
      t.stop();
    }

    // If we're using the end sound, stop the mid sound
    // and play the end sound.
    if (use_end_sound) {
      if (use_mid_sound) {
        mid_sound.stop();
      }
      end_sound.setLooped(false);
      end_sound.play();
    }
    is_playing = false;
  }
Esempio n. 2
0
 public void shutdown() {
   if (use_start_sound) {
     start_sound.stop();
   }
   if (use_mid_sound) {
     mid_sound.stop();
   }
   if (use_end_sound) {
     end_sound.stop();
   }
   if (use_short_sound) {
     short_sound.stop();
   }
 }