A pretty basic media player, plays all types a music and movies.. uses the newest version of nHTMLn_2.92.dll, MDX.dll and dialog.mdx
dialog mmp.dialog {
title "Nexgen Media Player"
size -1 -1 489 412
option pixels
box "play", 1, -12 -15 529 442
button "", 10, 0 0 0 0
menu "File", 2
item "Open Movie", 4, 2
item break, 6, 2
item "Open Song", 3, 2
item "Open Song From URL...", 5, 2
item "Exit", 7, 2, ok
menu "Help", 8
item "About", 9, 8
}
dialog aboutmed {
title "About Media Player"
size -1 -1 83 34
option dbu
button "Close", 1, 23 20 37 12, ok
text "Nexgen Media Player By Kryptic", 2, 0 7 84 8, center
}
on *:LOAD:{ set %mmp.playdir C:\ }
on *:UNLOAD:{ unset %mmp.* }
on *:dialog:mmp.dialog:*:*:{ if ($devent == init) { dll $mmp.dll(mdx) SetMircVersion $version | dll $mmp.dll(mdx) MarkDialog $dname | dll $mmp.dll(mdx) SetControlMDX $dname 10 Positioner size minbox maxbox > $mmp.dll(dialog) } | if ($did == 3) { mmp.open } | if ($devent == menu) { if ($did == 4) { mmp.open2 } | if ($did == 5) { mmp.openurl } | if ($did == 9) { dialog -m aboutmed aboutmed } } | if ($devent == sclick) { dll $mmp.dll(mdx) MoveControl $dname 1 * * $calc($dialog($dname).cw + 40) $calc($dialog($dname).ch + 34) } }
alias mmp.open { write -c " $+ $mircdirmmp.html $+ " | if (!$isdir(%mmp.playdir)) { set %mmp.playdir C:\ } | set %mmp.media $sfile( $+ %mmp.playdir $+ ,Select A Media File To Play,Play) | if (%mmp.media) { write " $+ $mircdirmmp.html $+ " <embed width="100%" height="100%" src=" $+ %mmp.media $+ "> | dll $mmp.dll(html) attach $dll($mmp.dll(html),find,play) | dll $mmp.dll(html) navigate $mircdirmmp.html | set %mmp.playdir $nofile(%mmp.media) | dialog -t mmp.dialog Nexgen Media Player - $nopath(%mmp.media) | set %cid.chan $activecid | scid %cid.chan msg $active 14Nexgen Media Player 4 $+ - 14Is Playing $+ 4 $+ (14 $+ $remove($nopath(%mmp.media),.mp3) $+ $+ 4 $+ )14 14 $+ $duration($calc($sound(%mmp.media).length /1000)) $+ 4 $+ @14 $mp3(%mmp.media).bitrate $+ Kbps $+ 4 $+ /14 $+ $round($calc($lof(%mmp.media)/1000000),2) $+ MB | unset %cid.chan } } } }
alias mmp.open2 { write -c " $+ $mircdirmmp.html $+ " | if (!$isdir(%mmp.playdir)) { set %mmp.playdir C:\ } | set %mmp.media $sfile( $+ %mmp.playdir $+ ,Select A Media File To Play,Play) | if (%mmp.media) { write " $+ $mircdirmmp.html $+ " <embed width="100%" height="100%" src=" $+ %mmp.media $+ "> | dll $mmp.dll(html) attach $dll($mmp.dll(html),find,play) | dll $mmp.dll(html) navigate $mircdirmmp.html | set %mmp.playdir $nofile(%mmp.media) | dialog -t mmp.dialog Nexgen Media Player - $nopath(%mmp.media) } } } }
alias mmp.openurl { write -c " $+ $mircdirmmp.html $+ " | set %mmp.mediaurl $$?"URL To Media File:" | if (%mmp.mediaurl) { write " $+ $mircdirmmp.html $+ " <embed width="100%" height="100%" src=" $+ %mmp.mediaurl $+ "> | dll $mmp.dll(html) attach $dll($mmp.dll(html),find,play) | dll $mmp.dll(html) navigate $mircdirmmp.html | dialog -t mmp.dialog Nexgen Media Player - $nopath(%mmp.mediaurl) } }
alias mmp.dll { if ($$1 == mdx) { return " $+ system\dlls\MDX.dll $+ " } | if ($$1 == dialog) { return system/dlls/Dialog.mdx } | if ($$1 == html) { return " $+ system\dlls\nHTMLn_2.92.dll $+ " } }
alias mmp { dialog -m $+ $1 mmp.dialog mmp.dialog }
}