This is a smart randomize. It give you the option of randomizing your selection or the entire playlist. If you choose the entire playlist, it will only randomize the songs after the song selected by winamp (ie the bolded one).

entire=inputbox("Entire Playlist or Selection (E/S)?","","E")
 
if left(ucase(entire),1) = "E" then 
 
for each track in playlist
	if track.position > playlist.position then
		Randomize
		playlist.swapindex track.position, _
		 (Int(playlist.count - playlist.position) * Rnd + 1  + playlist.position)
	end if	
next
 
else
 
x = playlist.getselection()
 
for each track in x
Randomize
playlist.swapindex track.position, x( Int((ubound(x,1)) * Rnd + 1)).position
next
 
end if
 
quit
 
examples/playlist/smart_randomize.txt · Last modified: 2006/11/06 15:44
 
Recent changes RSS feed Creative Commons License Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki
Music Plugins