MP3 Player

By KuTsuM on Jul 01, 2005

Mp3 player with no dialog: /play (song number optional, leave blank for random play), /dir to set file directory, /add to add file to playlist, /stop to stop, /check returns the number of files in playlist

alias dir { 
  set %sdir $sdir(C:\) 
} 
alias add { 
  if ($read(playlist.txt,1) == $null) { write -c playlist.txt } 
  write -a playlist.txt $sfile(%mp3.sdir) 
  echo -a File Added 
} 
alias play { 
  if ($1 == $null) { 
    set %song $read(playlist.txt,$rand(1,$lines(playlist.txt))) 
    splay %song 
    .amsg [Now Playing] $nopath(%song) [Song #] $readn $+ / $+ $lines(playlist.txt) 
    echo -a [Now Playing] $nopath(%song) [Song #] $readn $+ / $+ $lines(playlist.txt) 
  } 
  else { 
    set %song $read(playlist.txt,$1) 
    splay %song 
    .amsg [Now Playing] $nopath(%song) [Song #] $readn $+ / $+ $lines(playlist.txt) 
    echo -a [Now Playing] $nopath(%song) [Song #] $readn $+ / $+ $lines(playlist.txt) 
  } 
} 
alias stop { 
  splay stop 
} 
alias check { 
  echo -a You have $lines(playlist.txt) tracks in your playlist 
} 

Comments

Sign in to comment.
Acid-Religion   -  Jun 16, 2006

Is\'nt /play a standard mirc alias? should change it so it does\'nt mess up with other scripts, addons

 Respond  
`Shippo   -  Oct 28, 2005

It doesnt work and i dont know why... I might just be using it wrong i type /add Dirty little secret by all american rejects but it doesnt work =( i might just be usin wrong so...

 Respond  
DarthReven   -  Jul 02, 2005

lota aliases

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.