mIRC Home    About    Download    Register    News    Help

Print Thread
#117399 15/04/05 06:29 PM
W
wouziap
wouziap
W
on *:CHAT:*:{
if (FSrv* iswm $nick && %dccse == on) {
if ($strip($1) isnum) {
var %tmp.dccse.pav = 3
var %tmp.dccse.pavaz = $strip($2)
while ($right(%tmp.dccse.pavaz,$calc($len(%tmp.dccse.pavaz)-4)) != .mp3) {
var %priedas = $strip($chr(36) $+ %tm.dccse.pav $+)
var %tmp.dccse.pavaz = %tmp.dccse.pavaz $+ %priedas
inc %tmp.dccse.pav
}
did -a e8 1 + 0 0 0 %tmp.dccse.pavaz
}
}
}
i want to get the song's title and artist from text. For example, from:
<FSrv[Leonard]> 13 foje - kitoks pasaulis.mp3 <<128 Kbs>> <<3.62 MB>>
i want to get only foje - kitoks pasaulis.mp3
could somebody help me?

#117400 15/04/05 06:59 PM
Joined: Dec 2002
Posts: 3,534
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,534
Type //echo -a $gettok(13 foje - kitoks pasaulis.mp3 <<128 Kbs>> <<3.62 MB>>,1,60)

#117401 16/04/05 12:26 AM
D
DaveC
DaveC
D
on *:CHAT:*:{ tokenize 32 $strip($1-) | if ((FSrv* iswm $nick) && (%dccse == on) && ($1 isnum)) { did -a e8 1 + 0 0 0 $left($2-,$iif($pos($2-,.mp3),$calc($v1 + 3),$len($2-))) } }

#117402 16/04/05 08:37 AM
W
wouziap
wouziap
W
thank's.
and how to get the bitrate - 128 Kbs - from:
13 foje - kitoks pasaulis.mp3 <<128 Kbs>> <<3.62 MB>> ? confused

#117403 16/04/05 10:59 AM
D
DaveC
DaveC
D
Assuming $1- contains the text

$gettok($gettok($1-,2,$asc(<)),1,$asc(>))

* I have used $asc() instead of the raw asc values, so as to show you what is being done, I could have used $gettok($gettok($1-,2,60),1,62)

* Also IF you have used << & >> here instead of « » which may have been hard for you to insert into a forum thread, then you should use $gettok($gettok($1-,2,$asc(«)),1,$asc(»)) OR $gettok($gettok($1-,2,171),1,187)

#117404 16/04/05 11:30 AM
W
wouziap
wouziap
W
//echo $gettok($gettok($strip(13 foje - kitoks pasaulis.mp3 <<128 Kbs>> <<3.62 MB>>),2,$asc(<)),1,$asc(>))
returns only:
Kbs
i need:
128 Kbs
really don't understand what's wrong :\

#117405 16/04/05 02:34 PM
Joined: Dec 2002
Posts: 3,534
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,534
Try //echo -a $gettok($gettok($strip(13 foje - kitoks pasaulis.mp3 <<128 Kbs>> <<3.62 MB>>),2,$asc(<)),1,$asc(>))

#117406 16/04/05 03:15 PM
W
wouziap
wouziap
W
but on dialog only "Kbs" frown
did -a e8 1 + 0 0 0 $gettok($gettok($strip($1-),2,$asc(<)),1,$asc(>))

#117407 16/04/05 11:34 PM
D
DaveC
DaveC
D
The 128 is being evaluated as something to do with the dialog, i dont use it myself, but i assume thats a mdx dialog, as the + 0 0 0 reminds me of one i have seen before (i think) you well need to find how to fill that space as well likely a 0

did -a e8 1 + 0 0 0 0 $gettok($gettok($strip($1-),2,$asc(<)),1,$asc(>)) [/quote]

and if that dont work try

did -a e8 1 + 0 0 0 0 $replace($gettok($gettok($strip($1-),2,$asc(<)),1,$asc(>)),$chr(32),$chr(160))

#117408 17/04/05 06:05 AM
W
wouziap
wouziap
W
thank you very much again smile

#117409 17/04/05 06:50 AM
C
CSUH
CSUH
C
can anyone help me out with Pansat 2500 Code for dish network? thanks alot

#117410 17/04/05 08:23 AM
Joined: Aug 2004
Posts: 7,168
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,168
This has nothing to do with mIRC or the IRC chat network. It appears to be an attempt to override coding on that dish network, which is illegal, and will not be assisted with on here.


Link Copied to Clipboard