Mp3 Player again

By G13AoUsTiS on Mar 15, 2008

Just another very simple but effective mp3 player

menu @MP3 {
  dclick: splay $line(@MP3,$1) | ame is listening to: $nopath($line(@MP3,$1)) | set %song $1
}

alias readmp3 {
  window -sl @MP3
  dialog -m mc mc
  if (%mp3dir == $null) { %mp3dir = $$sdir($mircdir,Select Mp3 Directory) }
  write -c mp3list.txt
  var %x = $findfile($+(",%mp3dir,"),*.mp3,0,.write mp3list.txt $1-)
  var %y = 1
  while %y {
    if ($read(mp3list.txt) == $null) { halt }
    aline @MP3 $read(mp3list.txt,%y)
    inc %y
  }
  elseif (%mp3dir != $null) {
    var %y = 1
    while %y {
      if ($read(mp3list.txt) == $null) { halt }
      aline @MP3 $read(mp3list.txt,%y)
      inc %y
    }

  }
}

dialog mc {
  title "MP3 Controler"
  size -1 -1 118 18
  option dbu
  button "Resume", 1, 1 3 37 12
  button "Pause", 2, 39 3 37 12
  button "Stop", 3, 77 3 37 12
}

on *:dialog:mc:sclick:*: {
  if ($did == 1) { splay resume }
  if ($did == 2) { splay pause }
  if ($did == 3) { splay stop | unset %song }
}

on *:mp3end: { splay $line(@MP3,$($calc(%song + 1))) | ame is listening to: $nopath($line(@MP3,$($calc(%song + 1)))) }

menu channel {
-
Mp3 Player v1:/readmp3
}

Comments

Sign in to comment.
G13AoUsTiS   -  Mar 15, 2008

thank you RCA:) i also added the menu channel thingy:)

 Respond  
  -  Mar 15, 2008

This Script Is Cool. i was actually looking for a simple and easy to use mp3 player. :)

would be great to have this..

menu channel {
mp3player:/readmp3
}

in one word.. I LIKE IT!!!

 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.