Quantcast
Channel: Processing Forum
Viewing all articles
Browse latest Browse all 1768

Re : array of audio files - failed

$
0
0
So glad you liked my tweaked version!

Secret is to identify any redundant patterns,
and make them become arrays & loops and so on!  

Well, just for another Java fun,
the last loop within function stop() could also be written this way:
    void stop() {
      for ( AudioPlayer ap: songs )  ap.close();
      minim.stop();
      super.stop();
    }
    
It is the enhanced for each loop format.

Cya another time!

Viewing all articles
Browse latest Browse all 1768

Trending Articles