This is Haewk's "Hawks MP3 player" but i have changed the place of the buttons and added a menu in the channel section so if you right click in the channel section "MP3 Player" will be there.
/song : shows what your listening to
everything else is pretty self explanitory
V.1.1 Update - This is a very minor change but i changed menu channel to menu * which makes it so you can right click any window to get the list with "MP3 Player" in it. :)
V.1.2 Update - My freind had used this, but he said it didn't work, so i just changed "mp3" to "mp4" i hope it will work, and if it doesn't comment below that it doesn't (P.S. With it being mp4 you can use it with other mp3 dialogs)
V.2 Update - With Version 2 i gave it a, kind of new look, i put buttons in boxes, Text at the bottom showing credits. Check it out for yourself! (spoiler: i'm going to try to put in an "add directory" to my dialog next update)
V.2.5 Update - ^Neptune said that the MP3 looked horrible so i moved some buttons up and made the list shorter (happy? :p). Also i fixed the del file button, so it acctually deletes files from the MP3 instead of doing nothing.
V.2.6 Update - I decided that the close button was useless scince it's close to the 'X' button anyways. so i decided to change it into a 'Check For Updates' button. This will make it easier to come back here and see if i've improved it.
V.3.0 Update - I moved around all of the buttons to make the dialog smaller .i also changed add and del to ADD and DEL for clear reading. Make sure to give ideas so i can get more updates out.
dialog mp4 {
title "MP3 Player V.3.0"
size -1 -1 350 190
option pixel
box "Music Play Options" 12, 210 45 138 94
button "<<", 2, 215 110 60 25 ok tab 11
button "||", 3, 215 60 130 25
button "", 4, 215 85 60 25
button "|>", 5, 285 85 60 25
button ">>", 6, 285 110 60 25
button "Check For Updates", 10, 215 140 130 25
list 7, 1 0 208 170, hsbar vsbar extel
box "ADD/DEL file" 11, 210 1 138 45
button "ADD File" 8, 215 15 65 25
button "DEL File" 9, 280 15 65 25
text "|Haewk's MP3 player Edited by RagBot|" 14, 75 170 200 25
}
menu * {
MP3 Player { player }
}
on 1:dialog:mp4:sclick:10:{ url -an http://www.hawkee.com/snippet/4369/ }
on 1:dialog:mp4:sclick:8: {
set %song1 $sfile(/)
write playlist.txt %song1
did -a mp4 7 $nopath(%song1)
}
on 1:dialog:mp4:sclick:9: {
set %del1 $did(mp4,9)
set %del2 $did(mp4,7).sel
write -dw [ $+ [ * [ $+ [ %del1 [ $+ [ * ] ] ] ] ] ] playlist.txt
did -d mp4 7 %del2
}
on 1:dialog:mp4:init:0: {
set %number 1
:next
set %song2 $read(playlist.txt, %number )
did -a mp4 7 $nopath(%song2)
inc %number 1
if ( %song2 != $null ) { goto next }
}
on 1:dialog:mp4:sclick:5: {
if ( %pause == on ) {
set %pause off
splay -p resume
}
else {
unset %play1
unset %play3
set %play1 $did(mp4, 7).seltext
set %play2 $did(mp4, 7).sel
set %play3 $read(playlist.txt, w, * [ $+ [ %play1 ] ] [ $+ [ * ] ] )
splay %play3
set %listening $nopath(%play3)
inc %play2 1
}
}
on 1:MP4END: {
set %play3 $read(playlist.txt, %play2)
splay %play3
set %listening $nopath(%play3)
inc %play2 1
}
on 1:dialog:mp4:sclick:4: {
splay stop
}
on 1:dialog:mp4:sclick:6: {
splay $read(playlist.txt, %play2)
set %path $read(playlist.txt, %play2)
set %listening $nopath(%path)
inc %play2 1
}
on 1:dialog:mp4:sclick:2: {
dec %play2 1
splay $read(playlist.txt, %play2)
set %path $read(playlist.txt, %play2)
set %listening $nopath(%path)
}
on 1:dialog:mp4:sclick:3: {
set %pause on
splay -p pause
}
alias song {
if ( %islist == me ) {
describe $chan %text %listening
}
else {
msg $chan %text %listening
}
}
alias setup {
set %islist $$?="When you say what you're listening to, shall it be in /me or /say. (me for /me and say for /say)"
set %text $$?="And what do you want to say? Example: Now playing: or is listening to"
echo ok, type /song to show what song you're listening to
}
alias player {
dialog -md mp4 mp4
}
A few edits. This way allows you to set a directory and writes ms.txt for all your mp3s in a folder. Also adds an on load to set the /me or /say with instuctions echo'd in the active window. Added the directory finder and song announcer in menu * { . Still have to manually delete each song from the player itself. I'm not that good with dialogs :/
Enjoy.
I think the dialog looks hideous
You need to tell my why it looks hideous, or suggest ways to fix it. Just saying it looks bad won\'t be able to give me ideas to change how it looks for the better.
EDIT: i guess i got one idea, The list does look a bit ... off, i\'ll see what i can do to make it look better.