HennesScript NW — File Browser
HennesScriptNWv0.61b / HennesScriptNWv0.61b / Data / script3.ini
script3.ini — 31.59 KB — Download this file
[script]
n0=; HennesScript <NW> MP3 Player
n1=;
n2=
n3=alias runMEDIA_LIST Xdialog -md DLGmp DLGmp
n4=dialog DLGmp {
n5= icon $mircdirdata\images\hsnw.ico, 0
n6= title "Media playlist editor"
n7= option dbu
n8= size -1 -1 155 207
n9= list 3, 1 1 153 136, extsel size
n10= button "Done", 4, 103 190 48 13,cancel
n11= button "Add file", 5, 5 140 29 13
n12= button "Add dir", 6, 35 140 29 13
n13= button "Remove", 7, 65 140 29 13
n14= box "", 8, -5 155 251 4
n15= text "Artist:", 10, 160 5 24 7
n16= text "Title:", 11, 160 15 24 7
n17= text "Album:", 12, 160 25 24 7
n18= text "Year:", 13, 160 35 24 7
n19= text "Genre:", 14, 160 45 24 7
n20= text "Comment:", 15, 160 55 24 7
n21= text "Length:", 16, 160 65 24 7
n22= text "Bitrate:", 17, 160 75 24 7
n23= text "Version:", 18, 160 85 24 7
n24= text "VBR:", 19, 160 95 24 7
n25= text "Sample:", 20, 160 105 24 7
n26= text "Mode:", 21, 160 115 24 7
n27= text "Track:", 22, 160 125 24 7
n28= text "Copyright:", 23, 160 135 24 7
n29= edit "", 24, 190 5 40 10,autohs,read
n30= edit "", 25, 190 15 40 10,autohs,read
n31= edit "", 26, 190 25 40 10,autohs,read
n32= edit "", 27, 190 35 40 10,autohs,read
n33= edit "", 28, 190 45 40 10,autohs,read
n34= edit "", 29, 190 55 40 10,autohs,read
n35= edit "", 30, 190 65 40 10,autohs,read
n36= edit "", 31, 190 75 40 10,autohs,read
n37= edit "", 32, 190 85 40 10,autohs,read
n38= edit "", 33, 190 95 40 10,autohs,read
n39= edit "", 34, 190 105 40 10,autohs,read
n40= edit "", 35, 190 115 40 10,autohs,read
n41= edit "", 36, 190 125 40 10,autohs,read
n42= edit "", 37, 190 135 40 10,autohs,read
n43= check "File info", 38, 120 140 30 13,push
n44= check "Shuffle", 39, 10 165 30 8
n45= check "Start playing when starting HennesScript", 40, 10 175 122 8
n46= box "", 41, 156 -5 1 259
n47= button "Done", 42, 183 190 48 13,ok ,hide
n48= link "Tip", 43, 10 195 48 13
n49=}
n50=
n51=on *:DIALOG:DLGmp:sclick:43: DLGmsg Did you know...|Did you know that it is possible to drag and drop files into the playlist?|Just select a mp3 file from your mp3 directory in windows, then drag it to the playlist.
n52=on *:DIALOG:DLGmp:sclick:4: save_ml
n53=on *:DIALOG:DLGmp:sclick:42: save_ml
n54=on *:DIALOG:DLGmp:sclick:38: dialog -sb DLGmp $dialog(DLGmp).x $dialog(DLGmp).y $iif($did(DLGmp,38).state,235,155) 207 | if ($did(DLGmp,38).state) { did -v DLGmp 42 | did -h DLGmp 4 } | else { did -h DLGmp 42 | did -v DLGmp 4 }
n55=on *:DIALOG:DLGmp:init:*: mdx MarkDialog $dname | mdx SetControlMDX 3 ListView report noheader grid droptarget > $mircdirdata\mdx\views.mdx | did -i DLGmp 3 1 headerdims 286 | load_ml | did $iif(%media.shuffle,-c,-u) DLGmp 39 | did $iif(%media.play_on_start,-c,-u) DLGmp 40 | did -c DLGmp 3 $calc(%cache.media.i + 1)
n56=on *:DIALOG:DLGmp:sclick:3:{
n57= did -i $dname 3 1 page event
n58= if ($gettok($did($dname,3,1),1,32) == sclick) && ($did($dname,38).state) {
n59= var %x = $gettok($did($dname,3,1),3,32)
n60= var %x = $read -l [ $+ [ $calc(%x - 1) ] ] %cache.medialist
n61= var %i = 10 | while (%i != 24) { var %y = $mp3(%x). [ $+ [ $remove($did($dname,%i),:) ] ] | did -ra $dname $calc(%i + 14) %y | inc %i }
n62= }
n63= if ($gettok($did($dname,3,1),1,32) == drop) {
n64= did -i $dname 3 1 page dragdrop
n65= var %x = $gettok($did($dname,3,1),6,32)
n66= if (%x == 1) { did -i $dname 3 1 page dropinfo | write " $+ %cache.medialist $+ " $gettok($did($dname,3,1),3-,32) | did -a $dname 3 $remove($nopath($gettok($did($dname,3,1),3-,32)),.mp3) }
n67= elseif (%x > 1) { var %i = 1 | while (%i <= %x) { did -i $dname 3 1 getdrop %i | did -i $dname 3 1 page dropinfo | write " $+ %cache.medialist $+ " $gettok($did($dname,3,1),3-,32) | did -a $dname 3 0 0 0 0 $remove($nopath($gettok($did($dname,3,1),3-,32)),.mp3) | inc %i } }
n68= }
n69=}
n70=on *:DIALOG:DLGmp:sclick:5: if (!%cache.media_dir) set %cache.media_dir C:\ | var %t.file = $file="Select media file" [ %cache.media_dir $+ *.* ] | set %cache.media_dir $nofile(%t.file) | write " $+ %cache.medialist $+ " %t.file | did -a DLGmp 3 0 0 0 0 $remove($nopath(%t.file),.mp3)
n71=on *:DIALOG:DLGmp:sclick:6: if (!%cache.media_dir) set %cache.media_dir C:\ | var %t.dir = $sdir="Choose directory to add files from" %cache.media_dir | set %i.max $findfile(%t.dir,*.*,0) | var %i = 1 | while (%i <= %i.max) { write " $+ %cache.medialist $+ " $findfile(%t.dir,*.*,%i) | inc %i } | load_ml
n72=on *:DIALOG:DLGmp:sclick:7: var %i = 1 | while (%i <= $did(DLGmp,3,0).sel) { var %t.del = $read -w* $+ $gettok($did(DLGmp,3,$calc($did(DLGmp,3,%i).sel + 0)).text,6-,32) $+ * %cache.medialist | write -ds" $+ %t.del $+ " " $+ %cache.medialist $+ " | inc %i } | load_ml
n73=on *:DIALOG:DLGmp:dclick:3: playmedia sel $calc($did(DLGmp,3).sel - 1)
n74=on *:MP3END: playmedia next
n75=alias -l save_ml set %media.shuffle $did(DLGmp,39).state | set %media.play_on_start $did(DLGmp,40).state
n76=alias -l load_ml if ($read -l1 %cache.medialist == $null) { did -r $dname 3 | halt } | _load [Media list]... | var %t.lines = $lines(%cache.medialist) | did -r DLGmp 3 | var %i = 1 | while (%i <= %t.lines) { _loadcheck %i %t.lines | did -a DLGmp 3 0 0 0 0 $remove($nopath($read -l $+ %i %cache.medialist),.mp3) | inc %i } | dialog -v DLGmp
n77=alias runMEDIA window -c @Mp3Player | window -dK0oaph +dL @Mp3Player %media.xy 223 14 | drawpic -s @Mp3Player 0 0 %media.background | .titlebar $gettok($titlebar,1,160) Â $+ $chr(124) $returnMP3at(%cache.last_mp3)
n78=alias returnMP3at if (!$mp3($1-).artist) || (!$mp3($1-).title) return $remove($nopath($1-),.mp3) | else return $mp3($1-).artist - $mp3($1-).title
n79=alias playmedia {
n80= if ($read -l1 %cache.medialist == $null) { DLGmsg Error!|Unable to load media files|Media-engine could not load the media list correctly, possible reasons: $crlf $+ medialist.hsml is empty $crlf $+ medialist.hsml does not exist $+ $crlf $+ $crlf $+ Path to the medialist should be: $mircdirdata\medialist.hsml $+ $crlf $+ Try /runMEDIA_LIST to edit your playlist | halt }
n81= goto $1 | :NEXT | if (%media.shuffle) set %cache.media.i $rand(1,$lines(%cache.medialist)) | else { if (%cache.media.i >= $lines(%cache.medialist)) set %cache.media.i 0 | inc %cache.media.i 1 } | mp_add %cache.media.i | splay " $+ $read -l [ $+ [ %cache.media.i ] ] %cache.medialist $+ " | .titlebar $gettok($titlebar,1,160) Â $+ $chr(124) $returnMP3at($read -l [ $+ [ %cache.media.i ] ] %cache.medialist) | goto end | :SEL | set %cache.media.i $2 | mp_add $2 | splay " $+ $read -l [ $+ [ $2 ] ] %cache.medialist $+ " | .titlebar $gettok($titlebar,1,160) Â $+ $chr(124) $returnMP3at($read -l [ $+ [ $2 ] ] %cache.medialist) | goto end
n82= :startup | set %t.fade_vol.b $vol(wave) | vol -w 0 | if (%media.shuffle) set %cache.media.i $rand(1,$lines(%cache.medialist)) | else { if (%cache.media.i >= $lines(%cache.medialist)) set %cache.media.i 0 | inc %cache.media.i 1 } | splay " $+ $read -l [ $+ [ %cache.media.i ] ] %cache.medialist $+ " | .titlebar $gettok($titlebar,1,160) Â $+ $chr(124) $returnMP3at($read -l [ $+ [ %cache.media.i ] ] %cache.medialist) | set %t.fade_vol 0 | .timerVOL -m 0 300 fade_vol | goto end
n83= :end
n84= if (%ms.enable) {
n85= if (%ms.active) && ($active ischan) && ($server) Xdescribe $active $mspy_str(%ms.string)
n86= elseif (!%ms.active) if ($server) ame $mspy_str(%ms.string)
n87= }
n88= set %cache.last_mp3 $read -l [ $+ [ %cache.media.i ] ] %cache.medialist
n89=}
n90=alias mp_add if ($dialog(DLGmp_)) did -ra DLGmp_ 11 $mspy_str(&fullsong)
n91=alias fade_vol {
n92= inc %t.fade_vol 3000
n93= vol -w %t.fade_vol
n94= if (%t.fade_vol >= %t.fade_vol.b) { vol -w %t.fade_vol.b | .timerVOL off | unset %t.fade* }
n95=}
n96=alias Mediaclick {
n97= if ($1 > 116) && ($1 < 122 ) && ($2 > 0) && ($2 < 14) { if ($inmp3) { if (%cache.media.i == 1) set %cache.media.i $calc($lines(%cache.medialist) + 1) | dec %cache.media.i 2 | playmedia next | halt } | else { if (%cache.media.i == 1) set %cache.media.i $calc($lines(%cache.medialist) + 1) | dec %cache.media.i 1 | .titlebar $gettok($titlebar,1,160) Â $+ $chr(124) $returnMP3at($read -l $+ %cache.media.i %cache.medialist) } }
n98= if ($1 > 126) && ($1 < 132 ) && ($2 > 0) && ($2 < 14) { if (%cache.media_paused) { splay resume | set %cache.media_paused 0 | halt } | if ($inmp3) { playmedia next | halt } | else { playmedia sel %cache.media.i | halt } }
n99= if ($1 > 132) && ($1 < 142 ) && ($2 > 0) && ($2 < 14) { if ($inmp3) && (!%cache.media_paused) { splay pause | set %cache.media_paused 1 | halt } | splay resume | set %cache.media_paused 0 | halt }
n100= if ($1 > 153) && ($1 < 160 ) && ($2 > 0) && ($2 < 14) { if ($inmp3) { playmedia next | halt } | else { if (%media.shuffle) set %cache.media.i $rand(1,$lines(%cache.medialist)) | else { if (%cache.media.i >= $lines(%cache.medialist)) set %cache.media.i 0 | inc %cache.media.i 1 } | .titlebar $gettok($titlebar,1,160) Â $+ $chr(124) $returnMP3at($read -l $+ %cache.media.i %cache.medialist) } }
n101= if ($1 > 145) && ($1 < 151 ) && ($2 > 0) && ($2 < 14) splay stop
n102= if ($1 > 163) && ($1 < 171 ) && ($2 > 0) && ($2 < 14) runMEDIA_LIST
n103= if ($1 > 213) && ($1 < 220 ) && ($2 > 0) && ($2 < 14) window -c @Mp3Player
n104= if ($1 > 20) && ($1 < 110 ) && ($2 > 0) && ($2 < 14) DLGmsg Moving the media player|You can move the media player using the right mouse button|Rightclick on the media player, move it to a place that fits you, then rightclick again.
n105=}
n106=menu @Mp3Player {
n107= sclick: { Mediaclick $mouse.x $mouse.y }
n108= rclick: if (!%media.move) runMEDIA_move | else { set %media.move 0 | set %media.xy $mouse.dx $mouse.dy | .timerMMOVE off }
n109=}
n110=;alias F7 set %media.xy $mouse.dx $mouse.dy | .timerMMOVE off
n111=alias runMEDIA_move window -c @Mp3Player | window -dK0oaph +dL @Mp3Player %media.xy 223 14 | drawpic -s @Mp3Player 0 0 %media.background | set %media.move 1 | .timerMMOVE -m 0 100 { MMOVE }
n112=alias -l MMOVE if (%media.move) window @Mp3Player $calc($mouse.dx - 105) $calc($mouse.dy - 7) 223 14 | else { drawpic -s @Mp3Player 0 0 $mircdirdata\images\Mp3Player.bmp | .timerMMOVE off }
n113=alias runMEDIA_SPY Xdialog -m DLGmediaspy DLGmediaspy
n114=dialog DLGmediaspy {
n115= icon $mircdirdata\images\hsnw.ico, 0
n116= title "Media spy"
n117= option dbu
n118= size 324 126 214 137
n119= check "Enable media spy", 3, 5 5 137 8
n120= box "Settings", 4, 5 15 202 103
n121= button "Done", 5, 160 120 47 13,ok
n122= radio "Send to active channel only", 6, 10 25 91 8
n123= radio "Send to all channels you are on", 7, 10 35 91 8
n124= text "What to send:", 8, 10 50 68 7
n125= edit "Edit", 9, 10 60 192 10,autohs
n126= link "Default", 10, 180 72 24 8
n127= text "|", 11, 175 72 4 9
n128= link "Info", 12, 162 72 12 7
n129= box "Preview", 13, 10 85 192 27
n130=}
n131=
n132=alias refresh.pos.ms_preview if ($dialog(DLGmediaspy)) { window @ms.preview $calc($dialog(DLGmediaspy).x + 30) $calc($dialog(DLGmediaspy).y + 208)) 370 30 } | else { window -c @ms.preview | .timerMSPREVIEW off }
n133=on *:DIALOG:DLGmediaspy:edit:9: clear @ms.preview | set -u0 %::me $me | set -u0 %::text $mspy_str($did(DLGmediaspy,9)).preview | set -u0 %:echo echo @ms.preview | %:echo $$thm($hget(theme,ActionQuerySelf))
n134=on *:DIALOG:DLGmediaspy:init:*: window -hkdo +dL @ms.preview $calc($dialog(DLGmediaspy).x + 30) $calc($dialog(DLGmediaspy).y + 208)) 370 30 | window -a @ms.preview | .timerMSPREVIEW -m 0 300 { refresh.pos.ms_preview } | if (%ms.enable) did -c DLGmediaspy 3 | else did -b DLGmediaspy 4,6,7,8,9,10,11,12 | did -ra DLGmediaspy 9 %ms.string | if (%ms.active) did -c DLGmediaspy 6 | else did -c DLGmediaspy 7 | set -u0 %::me $me | set -u0 %::text $mspy_str($did(DLGmediaspy,9)).preview | set -u0 %:echo echo @ms.preview | %:echo $$thm($hget(theme,ActionQuerySelf))
n135=on *:DIALOG:DLGmediaspy:sclick:3: did $iif($did(DLGmediaspy,3).state,-e,-b) DLGmediaspy 4,6,7,8,9,10,11,12
n136=on *:DIALOG:DLGmediaspy:sclick:5: set %ms.active $did(DLGmediaspy,6).state | set %ms.enable $did(DLGmediaspy,3).state | set %ms.string $did(DLGmediaspy,9)
n137=on *:DIALOG:DLGmediaspy:sclick:10: did -ra DLGmediaspy 9 %ms.string_def
n138=on *:DIALOG:DLGmediaspy:sclick:12: DLGmsg Media spy|You can use special identifiers in your own media string, see details for more information|The identifiers are: $+ $crlf $+ &album $+ $crlf $+ &title $+ $crlf $+ &artist $+ $crlf $+ &year $+ $crlf $+ &comment $+ $crlf $+ &genre $+ $crlf $+ &track $+ $crlf $+ &length $+ $crlf $+ &version $+ $crlf $+ &bitrate $+ $crlf $+ &vbr $+ $crlf $+ &sample $+ $crlf $+ &mode $+ $crlf $+ ©right $+ $crlf $+ &private $+ $crlf $+ &crc $+ $crlf $+ Example: "is playing &artist - &title with bitrate: &bitrate" $+ $crlf $+ You can also use &fullsong, which is a custom identifier which will return a song/title or name, because some files don't return a &title or &artist.
n139=alias mspy_str {
n140= if ($prop == preview) goto preview
n141= var %t.mspy = $1-
n142= var %t.mspy = $replace(%t.mspy,&album,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).album)
n143= var %t.mspy = $replace(%t.mspy,&title,$iif($mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).title,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).title,$remove($nopath($read -l [ $+ [ %cache.media.i ] ] %cache.medialist),.mp3)))
n144= var %t.mspy = $replace(%t.mspy,&artist,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).artist)
n145= var %t.mspy = $replace(%t.mspy,&year,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).year)
n146= var %t.mspy = $replace(%t.mspy,&comment,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).comment)
n147= var %t.mspy = $replace(%t.mspy,&genre,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).genre)
n148= var %t.mspy = $replace(%t.mspy,&track,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).track)
n149= var %t.mspy = $replace(%t.mspy,&length,$asctime($calc($mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).length / 1000),nn:ss))
n150= var %t.mspy = $replace(%t.mspy,&version,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).version)
n151= var %t.mspy = $replace(%t.mspy,&bitrate,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).bitrate)
n152= var %t.mspy = $replace(%t.mspy,&vbr,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).vbr)
n153= var %t.mspy = $replace(%t.mspy,&sample,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).sample)
n154= var %t.mspy = $replace(%t.mspy,&mode,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).mode)
n155= var %t.mspy = $replace(%t.mspy,©right,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).copyright)
n156= var %t.mspy = $replace(%t.mspy,&private,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).private)
n157= var %t.mspy = $replace(%t.mspy,&crc,$mp3($read -l [ $+ [ %cache.media.i ] ] %cache.medialist).crc)
n158= var %t.mspy = $replace(%t.mspy,&fullsong,$returnMP3at($read -l [ $+ [ %cache.media.i ] ] %cache.medialist))
n159= return %t.mspy
n160= :preview
n161= var %t.mspy = $1-
n162= var %t.mspy = $replace(%t.mspy,&album,album)
n163= var %t.mspy = $replace(%t.mspy,&title,song title)
n164= var %t.mspy = $replace(%t.mspy,&artist,artist)
n165= var %t.mspy = $replace(%t.mspy,&year,year)
n166= var %t.mspy = $replace(%t.mspy,&comment,comment)
n167= var %t.mspy = $replace(%t.mspy,&genre,genre)
n168= var %t.mspy = $replace(%t.mspy,&track,track nr)
n169= var %t.mspy = $replace(%t.mspy,&length,00:00)
n170= var %t.mspy = $replace(%t.mspy,&version,version)
n171= var %t.mspy = $replace(%t.mspy,&bitrate,000)
n172= var %t.mspy = $replace(%t.mspy,&vbr,vbr)
n173= var %t.mspy = $replace(%t.mspy,&sample,sample)
n174= var %t.mspy = $replace(%t.mspy,&mode,mode)
n175= var %t.mspy = $replace(%t.mspy,©right,copyright ©)
n176= var %t.mspy = $replace(%t.mspy,&private,private)
n177= var %t.mspy = $replace(%t.mspy,&crc,crc)
n178= var %t.mspy = $replace(%t.mspy,&fullsong,Artist - Song)
n179= return %t.mspy
n180=}
n181=
n182=alias clearall clearall | if ($window(@mp3player)) drawpic -s @Mp3Player 0 0 $mircdirdata\images\Mp3Player.bmp
n183=
n184=; HennesScript <NW> Onjoin notice
n185=;
n186=
n187=dialog DLGojNotice {
n188= title "Onjoin notice"
n189= size -1 -1 160 72
n190= option dbu
n191= button "Done", 1, 55 59 50 12, default,ok
n192= button "Cancel", 2, 107 59 50 12,cancel
n193= check "Enable", 22, 3 5 30 10
n194= box "Configure notice", 4, 2 18 155 38
n195= text "Text:", 5, 7 29 12 8
n196= edit "Edit Box", 25, 22 28 107 10, autohs
n197= text "Style:", 7, 7 39 13 8
n198= combo 27, 22 39 107 50, size drop
n199= link "Info", 28, 37 6 9 8
n200=}
n201=
n202=on 1:DIALOG:DLGOJnotice:sclick:22: did $iif($did(DLGojNotice,22).state,-e,-b) $dname 4,5,25,7,27
n203=on 1:DIALOG:DLGOJnotice:init:*: if (%OJNotice.Use) did -c DLGojNotice 22 | did -ra DLGojNotice 25 %OJnotice.Text | did -a DLGojNotice 27 No style | did -a DLGojNotice 27 Basic | did -a DLGojNotice 27 Stripes | did -a DLGojNotice 27 Roses | did -a DLGojNotice 27 Blue | did -a DLGojNotice 27 Hearts-n-Arrows | did -a DLGojNotice 27 Colors | did -a DLGojNotice 27 ¸.·`¯`·.¸¸.·`¯`· | did -a DLGojNotice 27 ,.¤'`^`'¤§¤'`^`'¤§| | did -c DLGojNotice 27 %OJNotice.style | did $iif($did(DLGojNotice,22).state,-e,-b) $dname 4,5,25,7,27
n204=on 1:DIALOG:DLGOJnotice:sclick:28:DLGmsg What is Onjoin notice?|If Onjoin notice is enabled, you will send a notice to the whole channel when you join a channel.|Example: Hi everyone! I'm back! :)
n205=on 1:DIALOG:DLGOJnotice:sclick:1: set %OJnotice.use $did(DLGojNotice,22).state | set %OJnotice.text $did(DLGojNotice,25) | set %OJnotice.style $did(DLGojNotice,27).sel
n206=alias OJnotice { Xdialog -m DLGojNotice DLGojNotice }
n207=alias doOJnotice {
n208= if (!%OJnotice.use) { goto end }
n209= goto %OJnotice.style
n210= :1 | .notice $1 %OJnotice.text $data(x).version-nw-c | goto end
n211= :2 | .notice $1 10»15» %OJnotice.text 14«10« $data(x).version-nw-c | goto end
n212= :3 | .notice $1 \\|\\ %OJnotice.text //|// $data(x).version-nw-c | goto end
n213= :4 | .notice $1 4@3}-->-->--- %OJnotice.text 4@3}-->-->--- $data(x).version-nw-c | goto end
n214= :5 | .notice $1 2,1\1,2\12,2\2,12\0,12\12,0\0,0-15,0\0,15\14,15\15,14\1,14\14,1\1,1-0,1 %OJnotice.text 1,1-14,1/1,14/15,14/14,15/0,15/15,0/0,0-12,0/0,12/2,12/12,2/1,2/2,1/ $data(x).version-nw-c | goto end
n215= :6 | .notice $1 12»»-4(¯`v´¯)12--»6 %OJnotice.text 12»»-4(¯`v´¯)12--» $data(x).version-nw-c | goto end
n216= :7 | .notice $1 6,12|12,6|13,6|6,13|4,13|13,4|7,4|4,7|8,7|7,8|9,8|8,9|10,9|9,10|12,10|10,12|0,1 %OJnotice.text 10,12|12,10|9,10|10,9|8,9|9,8|7,8|8,7|4,7|7,4|13,4|4,13|6,13|13,6|12,6|6,12| $data(x).version-nw-c | goto end
n217= :8 | .notice $1 12¸.9·`¯8`·.7¸¸6.·`4¯`·12 %OJnotice.text 12¸.9·`¯8`·.7¸¸6.·`4¯`· $data(x).version-nw-c | goto end
n218= :9 | .notice $1 14,.¤'`^`'¤§¤'`^`'¤§| %OJnotice.text 14|§¤'`^`'¤§¤'`^`'¤., $data(x).version-nw-c
n219= :%OJnotice.style | return
n220= :end
n221=}
n222=
n223=alias runBOT Xdialog -m DLGbot DLGbot
n224=dialog DLGbot {
n225= title "Bot mode settings"
n226= icon $mircdirdata\images\hsnw.ico, 0
n227= option dbu
n228= size 97 171 142 77
n229= button "OK", 3, 90 60 47 13,ok
n230= text "Enter bot mode prefix:", 4, 15 10 56 8
n231= edit ".", 5, 70 10 14 10,center ,autohs
n232= link "Help", 6, 88 10 22 7
n233= box "Bot mode user file", 7, 15 25 109 27
n234= link "Click here to open the bot mode user file", 8, 20 37 98 8
n235=}
n236=
n237=on *:DIALOG:DLGbot:init:*: did -ra DLGbot 5 %bot.prefix
n238=on *:DIALOG:DLGbot:sclick:6: DLGmsg Bot mode prefix|Enter the prefix which users must use to make the bot preform commands|Example: if prefix is: '@' then the users must use @+v @-v @kick... etc to make the bot preform commands.
n239=on *:DIALOG:DLGbot:sclick:8: .run $mircdirdata\bot_users.ini
n240=on *:DIALOG:DLGbot:sclick:3: set %bot.prefix $did($dname,5)
n241=
n242=; HennesScript <NW> Script source manager
n243=
n244=alias runSSM Xdialog -m DLGssm DLGssm
n245=dialog DLGssm {
n246= title "Module manager"
n247= size -1 -1 272 140
n248= option dbu
n249= box "Modules", 1, 2 2 220 122
n250= list 2, 5 9 214 112, size
n251= button "Load", 3, 225 5 45 12
n252= button "Unload", 4, 225 19 45 13
n253= box "", 5, -38 120 329 4
n254= button "Done", 6, 225 127 45 12, ok
n255=}
n256=
n257=on *:DIALOG:DLGssm:init:*: mdx MarkDialog $dname | mdx SetControlMDX 2 ListView report > $mircdirdata\mdx\views.mdx | did -i $dname 2 1 headerdims 118:1 235:2 52:3 | did -i $dname 2 1 headertext + 0 Name $+ $chr(9) $+ 0 Description $+ $chr(9) $+ 0 Loaded | did -i $dname 2 1 seticon list 0 $mircdirdata\mdx\cl_yes.ico | did -i $dname 2 1 seticon list 0 $mircdirdata\mdx\cl_no.ico | did -i $dname 2 1 seticon list 0 $mircdirdata\mdx\ssm_ssf.ico | ssm_load
n258=alias -l ssm_load did -r $dname 2 | var %i = 1 | while ($findfile(addons\,*.ssf,%i,1)) { did -ia $dname 2 0 3 $gettok($read -l1 $findfile(addons\,*.ssf,%i,1),2,124) $+ $chr(9) $+ $gettok($read -l1 $findfile(addons\,*.ssf,%i,1),3,124) $+ $chr(9) $+ $iif($script($findfile(addons\,*.ssf,%i,1)),1,2) $iif($script($findfile(addons\,*.ssf,%i,1)),Yes,No) | inc %i }
n259=on *:DIALOG:DLGssm:sclick:3: if (!$did($dname,2).seltext) { DLGmsg Error|Select an add-on from the list, then press the load or unload button | halt } | .load -rs " $+ $findfile(addons\,*.ssf,$calc($gettok($did($dname,2,1),3,32) - 1),1) $+ " | ssm_load
n260=on *:DIALOG:DLGssm:sclick:4: var %t.unload = $hsnw__ [ $+ [ $replace($gettok($gettok($did($dname,2,$gettok($did($dname,2,1),3,32)),1,9),6-,32),$chr(32),_) ] ] | .Xunload -rs %t.unload | ssm_load
n261=on *:DIALOG:DLGssm:dclick:2: if ($script($hsnw__ [ $+ [ $replace($gettok($gettok($did($dname,2,$gettok($did($dname,2,1),3,32)),1,9),6-,32),$chr(32),_) ] ])) { .Xunload -rs " $+ $script($hsnw__ [ $+ [ $replace($gettok($gettok($did($dname,2,$gettok($did($dname,2,1),3,32)),1,9),6-,32),$chr(32),_) ] ]) $+ " | inc -u1 %t.loading 1 } | else { if (!%t.loading) .load -rs " $+ $findfile(addons\,*.ssf,$calc($gettok($did($dname,2,1),3,32) - 1),1) $+ " } | ssm_load
n262=on *:DIALOG:DLGssm:sclick:2: did -i $dname 2 1 page event
n263=
n264=; HennesScript <NW> Topic creator
n265=;
n266=
n267=dialog DLGtp {
n268= title "Topic creator"
n269= size 120 90 247 66
n270= option dbu
n271= box "", 1, -44 18 327 32
n272= text "Enter topic:", 2, 3 25 32 8
n273= edit "Enter text", 3, 33 24 213 10, autohs
n274= text "Style:", 4, 17 36 13 8
n275= combo 5, 33 35 81 87, size drop
n276= check "Stripped (no colors, bold etc.)", 6, 118 35 84 10
n277= button "Cancel", 7, 195 53 50 12,cancel
n278= button "OK", 8, 143 53 50 12, default,ok
n279=}
n280=
n281=alias runTP set %t.tp_style $1 | set %t.tp_chan $2 | Xdialog -m DLGtp DLgtp
n282=alias tp_load tp_topic | did -c DLGtp 5 1 | set %t.topic.preview $replace($read -l $+ $did(DLGtp,5).sel $mircdirdata\topic\topics $+ %t.tp_style $+ .txt,!¿Custum¿!-Text,$did(DLGtp,3))
n283=alias tp_topic did -r DLGtp 5 | var %i = 1 | while ($read -l $+ %i $mircdirdata\topic\TopicsIndex $+ %t.tp_style $+ .txt != $null) { did -a DLGtp 5 $read -l $+ %i $mircdirdata\topic\TopicsIndex $+ %t.tp_style $+ .txt | inc %i }
n284=on *:DIALOG:DLGtp:sclick:7: unset %t.tp_*
n285=on *:DIALOG:DLGtp:init:*: tp_load | if (%t.tp_style == 1) did -ra $dname 3 $chan(%t.tp_chan).topic | set %t.topic.preview $replace($read -l $+ $did(DLGtp,5).sel $mircdirdata\topic\topics $+ %t.tp_style $+ .txt,!¿Custum¿!-Text,$did(DLGtp,3)) | window -hkdo +dL @topic.preview $calc($dialog(DLGtp).x + 1) $calc($dialog(DLGtp).y + 21) 496 42 | window -a @topic.preview | if (%t.tp_style == 1) dialog -t $dname Enter topic for %t.tp_chan | if (%t.tp_style == 2) dialog -t $dname Enter onjoin message for %t.tp_chan | if (%t.tp_style == 3) dialog -t $dname Enter onpart message for %t.tp_chan | .timertopicpreview2 -mo 1 100 { tp_load } | .timertopicpreview -mo 0 200 { refresh.topic.preview } | !echo @topic.preview $iif($did(DLGtp,6).state,$strip(%t.topic.preview),%t.topic.preview)
n286=on *:DIALOG:DLGtp:edit:3: set %t.topic.preview $replace($read -l $+ $did(DLGtp,5).sel $mircdirdata\topic\topics $+ %t.tp_style $+ .txt,!¿Custum¿!-Text,$did(DLGtp,3)) | if (%t.topic.preview) { clear @topic.preview | !echo @topic.preview $iif($did(DLGtp,6).state,$strip(%t.topic.preview),%t.topic.preview) }
n287=on *:DIALOG:DLGtp:sclick:5: set %t.topic.preview $replace($read -l $+ $did(DLGtp,5).sel $mircdirdata\topic\topics $+ %t.tp_style $+ .txt,!¿Custum¿!-Text,$did(DLGtp,3)) | if (%t.topic.preview) { clear @topic.preview | !echo @topic.preview $iif($did(DLGtp,6).state,$strip(%t.topic.preview),%t.topic.preview) }
n288=on *:DIALOG:DLGtp:sclick:8: if (%t.tp_style == 1) topic %t.tp_chan $iif($did(DLGtp,6).state,$strip(%t.topic.preview),%t.topic.preview) | if (%t.tp_style == 2) prop %t.tp_chan onjoin : $iif($did(DLGtp,6).state,$strip(%t.topic.preview),%t.topic.preview) | if (%t.tp_style == 3) prop %t.tp_chan onpart : $iif($did(DLGtp,6).state,$strip(%t.topic.preview),%t.topic.preview) | unset %t.tp_*
n289=alias refresh.topic.preview if ($dialog(DLGtp)) { window @topic.preview $calc($dialog(DLGtp).x + 1) $calc($dialog(DLGtp).y + 21) 496 42 } | else { window -c @topic.preview | .timertopicpreview off | unset %t.topic.preview }
n290=
n291=alias _load Xdialog -m DLGload DLGload | dialog -t DLGload Loading $1-
n292=alias _loadcheck if ($dialog(DLGload)) { if ($1 >= $2) { dialog -x DLGload } | else did -a DLGload 1 $1 0 $2 }
n293=dialog DLGload {
n294= title "Loading"
n295= size -1 -1 302 28
n296= text "Please wait while loading", 1, 13 5 275 16
n297= button "Button", 3, 9 122 75 25, disable default,ok
n298=}
n299=on *:DIALOG:DLGload:INIT:*: mdx MarkDialog $dname | mdx SetDialog $dname style title border | mdx SetControlMDX 1 ProgressBar smooth> $mircdirdata\mdx\ctl_gen.mdx
n300=
n301=; HennesScript <NW> first time setup
n302=
n303=alias runFTS Xdialog -m DLGfts DLGfts
n304=dialog DLGfts {
n305= title "Welcome!"
n306= size -1 -1 211 134
n307= option dbu
n308= box "", 1, -13 28 258 89
n309= icon 2, -8 0 226 31, $mircdirdata\images\hsnwfts.jpg, 0
n310= button "Done", 3, 74 120 42 12, default ok
n311= text "Welcome, this is the first time you are running this edition of HennesScript.", 4, 4 38 174 7
n312= text "To make this program fit you the best, you must configure a few settings...", 5, 4 44 173 8
n313= text "In this program, I would like to use:", 6, 4 62 82 8
n314= check "Newbie features (popups/greetings/extras)", 9, 19 74 119 10
n315= check "Advanced features", 10, 19 83 64 10
n316= check "As many features ass possible (all features)", 11, 19 92 152 10
n317= button "Next >>", 12, 166 120 42 12
n318= button "<< Back", 13, 122 120 42 12, disable
n319= text "Step 1 of 3", 14, 3 124 26 8
n320=
n321= text "Before you can start chatting, you have to configure a server where you want to", 15, 4 38 188 7, hide
n322= text "chat on, you can either quickly enter an address here, or open the connection dialog", 16, 4 45 199 7, hide
n323= text "Enter server address (example: irc.chatvalley.nl 6667):", 17, 4 66 127 8, hide
n324= text "to configure more connection settings", 18, 4 52 89 6, hide
n325= edit "irc.chatvalley.nl", 19, 61 76 86 10, autohs hide
n326= text "If you want to configure more connection options, click", 20, 4 92 129 8, hide
n327= link "here", 21, 134 92 11 8, hide
n328=
n329= text "Now choose what kind of environment you would like to use:", 22, 4 38 144 7, hide
n330= radio "White background", 23, 81 53 60 10, hide
n331= radio "Black background", 24, 81 63 61 10, hide
n332= icon 25, 12 56 56 41, $mircdirdata\images\fts_white.JPG, 0, hide
n333=}
n334=
n335=alias unload_ssf {
n336= var %y = 0
n337= var %i = $script(0)
n338= while (%i != 5) {
n339= if ($right($script(%i),3) == ssf) { .unload -rs " $+ $script(%i) $+ " | inc %y }
n340= dec %i
n341= }
n342= if (%y) es Unloaded %y modules.
n343=}
n344=
n345=on *:DIALOG:DLGfts:init:*: {
n346= .timerX -m 1 100 unload_ssf
n347= .timerY -m 1 100 reset_vars
n348= titlebar $chr(124) $data(x).script $data(x).version-full $chr(124) Current lag: N/A $chr(124) Average lag: N/A
n349= did -c $dname 23
n350= did -c $dname 11
n351=}
n352=on *:DIALOG:DLGfts:sclick:12: {
n353= if ($did($dname,14) == Step 1 of 3) { did -h $dname 4,5,6,9,10,11 | did -v $dname 15,16,17,18,19,20,21 | did -ra $dname 14 Step 2 of 3 | did -e $dname 12 | did -e $dname 13 }
n354= elseif ($did($dname,14) == Step 2 of 3) { did -h $dname 15,16,17,18,19,20,21 | did -v $dname 22,23,24,25 | did -ra $dname 14 Step 3 of 3 | did -b $dname 12 | did -e $dname 13 }
n355=}
n356=on *:DIALOG:DLGfts:sclick:13: {
n357= if ($did($dname,14) == Step 2 of 3) { did -v $dname 4,5,6,9,10,11 | did -h $dname 15,16,17,18,19,20,21 | did -ra $dname 14 Step 1 of 3 | did -b $dname 13 | did -e $dname 12 }
n358= elseif ($did($dname,14) == Step 3 of 3) { did -v $dname 15,16,17,18,19,20,21 | did -h $dname 22,23,24,25 | did -ra $dname 14 Step 2 of 3 | did -e $dname 13 | did -e $dname 12 }
n359=}
n360=on *:DIALOG:DLGfts:sclick:23: did -g $dname 25 " $+ $mircdirdata\images\fts_white.jpg"
n361=on *:DIALOG:DLGfts:sclick:24: did -g $dname 25 " $+ $mircdirdata\images\fts_black.jpg"
n362=on *:DIALOG:DLGfts:sclick:21: set %t.noserversave 1 | runOPTIONS 6 | .timerLS -m 1 100 load.groups&servers | halt
n363=on *:DIALOG:DLGfts:sclick:3: {
n364= if (!%t.noserversave) { if ($did($dname,19)) .server $did($dname,19) }
n365= if ($did($dname,9).state) {
n366= .load -rs addons\hsnw_clone_protection.ssf
n367= .load -rs addons\hsnw_logview.ssf
n368= .load -rs addons\hsnw_media_dialog.ssf
n369= .load -rs addons\hsnw_newbie.ssf
n370= .load -rs addons\hsnw_notifylist.ssf
n371= .load -rs addons\hsnw_qib.ssf
n372= .load -rs addons\hsnw_seen.ssf
n373= .load -rs addons\hsnw_webserver.ssf
n374= ; .load -rs addons\hsnw_nickserv.ssf
n375= }
n376= if ($did($dname,10).state) {
n377= .load -rs addons\hsnw_clone_protection.ssf
n378= .load -rs addons\hsnw_botmode.ssf
n379= .load -rs addons\hsnw_prot_bot.ssf
n380= ; .load -rs addons\hsnw_rangescanner.ssf
n381= .load -rs addons\hsnw_spy.ssf
n382= ; .load -rs addons\hsnw_unmasker.ssf
n383= .load -rs addons\hsnw_websearch.ssf
n384= .load -rs addons\hsnw_logview.ssf
n385= .load -rs addons\hsnw_media_dialog.ssf
n386= .load -rs addons\hsnw_notifylist.ssf
n387= .load -rs addons\hsnw_seen.ssf
n388= ; .load -rs addons\hsnw_nickserv.ssf
n389= .load -rs addons\hsnw_webserver.ssf
n390= }
n391= if ($did($dname,11).state) {
n392= .load -rs addons\hsnw_botmode.ssf
n393= .load -rs addons\hsnw_clone_protection.ssf
n394= .load -rs addons\hsnw_ircx_sysop.ssf
n395= .load -rs addons\hsnw_logview.ssf
n396= .load -rs addons\hsnw_media_dialog.ssf
n397= .load -rs addons\hsnw_newbie.ssf
n398= .load -rs addons\hsnw_notifylist.ssf
n399= .load -rs addons\hsnw_prot_bot.ssf
n400= .load -rs addons\hsnw_q-chatvalley.ssf
n401= .load -rs addons\hsnw_qib.ssf
n402= ; .load -rs addons\hsnw_rangescanner.ssf
n403= .load -rs addons\hsnw_script_tweak.ssf
n404= .load -rs addons\hsnw_seen.ssf
n405= .load -rs addons\hsnw_spy.ssf
n406= ; .load -rs addons\hsnw_unmasker.ssf
n407= .load -rs addons\hsnw_websearch.ssf
n408= ; .load -rs addons\hsnw_nickserv.ssf
n409= .load -rs addons\hsnw_webserver.ssf
n410= }
n411= if ($did($dname,23).state) { theme.load " $+ $mircdirthemes\mts\hennesscript\hennesscript.mts" }
n412= else {
n413= theme.load " $+ $mircdirthemes\mts\hennesscript\hennesscript.mts"
n414= theme.load " $+ $mircdirthemes\mts\hennesscript\hennesscript.mts" 1
n415= }
n416= unset %t.noserversave
n417= Xset settings first_start 0
n418=}