; Command-based mp3 - RubixCube
; Syntax:
; /mp -r/p (mp3name)/s/e
; /mp -se -d/a/b/c
; Ripping is forbidden
; Contact: rub1xcube@yahoo.com
Syntax:
-r : random play
-p (mp3name) : plays a match to the mp3name. It works even for only a few bits of the actual mp3. For example if I typed /mp -p L's and had an mp3 called L's theme B in my directory it would play that mp3.
-s : stops the mp3
-e : pauses/resumes the mp3
-se :
-se -d : sets the directory
-se -a : sets the mp3end option to repeat
-se -b : sets the mp3end option to shuffle
-se -c : sets the mp3end option to halt
; Command-based mp3 - RubixCube
; Syntax:
; /mp -r/p (mp3name)/s/e
; /mp -se -d/a/b/c
; Ripping is forbidden
; Contact: rub1xcube@yahoo.com
alias mp {
if ($1) {
if ($v1 = -r) {
var %| $findfile(%mp,*,0)
var %- $r(1,%|)
var %& $findfile(%mp,*.mp3,%-)
set %mp_ac $sound(%&).title
splay -p %&
if ($active != status window) msg $active cp: $sound(%&).title - $sound(%&).artist - $gmt($round($calc($insong.length / 1000),0),nn:ss)) $+([,$sound(%&).bitrate,kbps,;,$sound(%&).mode,])
}
if ($v1 = -se) {
if ($2) {
if ($v1 = -d) set %mp $sdir(C:\,MP3 DIRECTORY)
if ($v1 = -a) set %mp_end -re
if ($v1 = -b) set %mp_end -r
if ($v1 = -c) set %mp_end -s
}
}
if ($v1 = -p) {
if ($2-) {
var %& $findfile(%mp,$+(*,$v1,*),1,splay -p $1-)
set %mp_ac $sound(%&).title
var %$ $sound(%&).title - $sound(%&).artist, %^ $gmt($round($calc($insong.length / 1000),0),nn:ss)), %@ $sound(%&).bitrate, %# $sound(%&).mode
if ($active != status window) msg $active cp: %$ - %^ $+([,%@,kbps,;,%#,])
}
}
if ($v1 = -e) {
if ($inmp3) {
if (%pause isnum 1) {
splay -p resume
unset %pause
halt
}
else {
splay -p pause
set %pause 1
halt
}
}
}
if ($v1 = -s) {
if ($inmp3) { splay -p stop }
}
}
}
on *:MP3END:{
if (%mp_end = -re) mp -p %mp_ac
if (%mp_end = -r) mp -r
if (%mp_end = -s) halt
}