Jump to content

Archived

This topic is now archived and is closed to further replies.

chain

Wraith mp3

Recommended Posts

  • Administrators
This is my Wraith mp3 created by me. For though's of whom do not know i go by WraithRIOT on a lot of servers. This mp3 has been featured in many of my scripts that I privately release to friends. There is no riped code to this although the Sconamsg alias was not made by me it was made by Hitman Aka Maddy I do have his permission to use it in this script. Also this script requires the use of the MDX Dll for the coloring. Please comment on this and rate it.

 

XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

 

I have just fixed the bug with the remaining so should be 100% working

 

Alias Wmp3 { 

  if (!$dialog(Wmp3)) dialog -mdo Wmp3 Wmp3

  Else {

    Dialog -ie Wmp3 Wmp3

  }

}

alias Remaining {

  If ($dialog(Wmp3)) {

  did -ra Wmp3 4 $asctime($round($calc(($insong.length - $insong.pos) / 1000),0),nn:ss),none)

  Else { Halt }

}

}

dialog Wmp3 {

  title "WraithRIOT iRc Mp3"

  icon Icons\mp31.ico, 0

  size -1 -1 315 98

  option dbu

  list 2, 4 4 154 90, vsbar size sort

  edit "", 3, 164 3 121 10, read autohs autovs

  edit "", 4, 289 3 24 10, read autohs autovs right

  box "", 5, 165 16 148 56

  button "Play", 6, 168 25 32 12

  button "Pause", 7, 204 25 32 12

  button "Resume", 8, 240 25 32 12

  button "Stop", 9, 276 25 32 12

  button "Amsg", 10, 168 39 32 12

  button "Echo", 11, 240 39 32 12

  button "Active", 12, 204 39 32 12

  button "None", 13, 276 39 32 12

  button "Directory", 14, 276 53 32 12

  text "Wraith Mp3 By WraithRIOT ", 15, 165 75 149 19

  button "Con on", 16, 168 53 34 12

  button "Con off", 17, 204 53 34 12

  button "Skip", 18, 240 53 32 12

}

 

on *:Dialog:Wmp3:*:*:{

  if ($devent == InIt) {

    $mdxin

    dll $mdx SetMircVersion $version

    dll $mdx MarkDialog $dname

    dll $mdx SetControlMDX $dname 2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18, hasbuttons > $views

    dll $mdx SetFont $dname 2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18, -15 400 Times New Roman

    dll $mdx SetDialog $dname BGColor $color(1)

    dll $mdx SetColor $dname 2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18, background $color(1)

    dll $mdx SetColor $dname 2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18, textbg $color(1)

    dll $mdx SetColor $dname 2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18, text $color(0)

    Did -a Wmp3 2 $findfile(%dir, *.mp3,0,did -a Wmp3 2 $nopath($1-))

    did -ra Wmp3 3 Nothing is playing

    did -ra Wmp3 4 00:00 

  }

  If ($Devent == Sclick) {

    If ($did = 6) {

      var %Playing $Remove($did(Wmp3,2).seltext,.Wmp3)

      var %song $findfile(%dir,$did(Wmp3,2).seltext,1)

      set %length $gmt($round($calc($mp3(%song).length / 1000),0),nn:ss)

      splay %song

      Did -ra $dname 3 $remove($nopath($insong.fname)$1-,.mp3) 

      Did -ra $dname 4 %length

      Spam

      .timermp3 0 0 Remaining

    }

    If ($did = 7) {

      Splay Pause

    }

    If ($did = 8) {

      Splay Resume

    }

    If ($did = 9) {

      Splay stop

    }

    If ($did = 10) {

      Set %spam 1

    }

    If ($did = 11) {

      Set %Spam 3

    }

    If ($did = 12) {

      Set %Spam 2

    }

    If ($did = 13) {

      Set %Spam 4

    }

    If ($did = 14) {

      set %dir $sdir="Mp3 Directory"

      write mp3.txt

      noop $findfile(%dir,*.mp3,0,write mp3.txt $1-)

      var %num $findfile(%dir, *.mp3,0,did -a Wmp3 2 $nopath($1-))

    }

    If ($did = 16) {

      splay stop

      set %cplay on

      set %songnum 1

      splay $read(mp3.txt,%songnum)

      set %length $gmt($round($calc($mp3($insong.fname).length / 1000),0),nn:ss)

      did -ra Wmp3 3 $remove($nopath($insong.fname)$1-,.mp3)

      .timermp3 0 0 Remaining

      spam

    }

    If ($did = 17) {

      splay stop

      splay stop

      set %cplay off

      .timermp3 off

      did -ra Wmp3 3 Nothing is playing

      did -ra Wmp3 4 00:00

    }

    If ($did = 18) {

      if (%cplay == off) { Halt }

      splay stop

      inc %songnum

      splay $read(mp3.txt,%songnum)

      set %length $gmt($round($calc($mp3($insong.fname).length / 1000),0),nn:ss)

      did -ra Wmp3 3 $remove($nopath($insong.fname)$1-,.mp3)

      .timermp3 0 0 Remaining

      spam

    }

  }

  If ($devent == Dclick) {

    If ($did = 2) { 

      var %Playing $Remove($did(Wmp3,2).seltext,.Wmp3)

      var %song $findfile(%dir,$did(Wmp3,2).seltext,1)

      set %length $gmt($round($calc($mp3(%song).length / 1000),0),nn:ss)

      splay %song

      Did -ra $dname 3 $remove($nopath($insong.fname)$1-,.mp3) 

      Did -ra $dname 4 %length

      Spam

      .timermp3 0 0 Remaining

    }

  }

}

On *:Mp3end:{

  if (%cplay == on) {

    inc %songnum

    splay $read(mp3.txt,%songnum)

    set %length $gmt($round($calc($mp3($insong.fname).length / 1000),0),nn:ss)

    did -ra Wmp3 3 $remove($nopath($insong.fname)$1-,.mp3)

    spam

  }

}

Alias Spam {

  If (%spam = 1) {

    Sconamsg 14,1(4-0 $+ 15Wraith 15M4p15,1314:0 $remove($nopath($insong.fname)$1-,.mp3)  %length $+ 4-14)

  }

  If (%spam = 2) {

    Say 14,1(4-0 $+ 15Wraith 15M4p15,1314:0 $+ $remove($nopath($insong.fname)$1-,.mp3)  %length 4-14)

  }

  If (%Spam = 3) {

    Echo -a $Timestamp 14,1(4-0Now Playing4-14) 14,1(4-0 $+ 15Wraith 15M4p15,1314:0 $remove($nopath($insong.fname)$1-,.mp3)  %length 4-14)

  }

  If (%Spam = 4) {

    Halt

  }

}

 

alias sconamsg {

  var %x = 1

  var %chans = $chan(0)

  var %scid = $scon(0)

  var %scon = 1

  :started

  scon %scon

  if (!$server) && (%scon != scid) { inc %scon | goto started }

  if (!$server) && (%scon == %scid) { goto end }

  if ($chan(1)) amsg $1-

  if (!$chan(1)) && (%scon != %scid) { inc %scon | goto started }

  if (!$chan(1)) && (%scon == %scid) { goto end }

  if (%scid 

Link to comment
Share on other sites



×
×
  • Create New...