mIRC Home    About    Download    Register    News    Help

Print Thread
#153371 15/07/06 08:01 AM
Joined: Feb 2005
Posts: 344
B
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Feb 2005
Posts: 344
I have this as on input:
Code:
 on *:input:*: {
  if (/* !iswm $1) && (!* !iswm $1) && (~* !iswm $1) {
    hdef
    var %msg = $1- 
    var %ccode =  
    if (!%checkr) {
      var %ccode =  $+ $iif((%checkrv),) $+ $iif((%checkrk),$+(,%f,$chr(44),%b)) $+ $iif((%checkro),) 
      if (%ran.ztext == 1) { var %a = $replace($rand(2,15),8,4) | if (%a <= 9) { var %b = $+(0,%a) } | else { var %b = %a } | var %ccode =    $+  $iif((%checkrv),)  $+  $iif((%checkrk),$+(,%b))  $+  $iif((%checkro),) }
      if (%ran.wtext == 1) { var %msg =  $ranw(%msg) }
    }
    if (%talkers) { var %msg = $talkers(%ccode, %msg) }    
    if (<sound isin %msg) { talk.proc %msg | if ($exists($wavedir $+ %z)) { .sound %z } | var %tmp = <sound %z $+ > | set -nu %msg $remove(%msg,$chr(32) $+ %tmp) | /sound %z }
    if (%nickcom) { var %msg = $nickcom(%ccode, $active, %msg) }
    if (!%checkr) { var %msg = %ccode $+ %msg }
    msg $active %msg
    unset %z %zz 
  }
}
 

In the channel window all the names have tags around them using this:
Code:
 on ^*:TEXT:*:#: { 
  if ($nick isop $chan) {
    echo -ti2mbfl # 4«« $nick 4»» $1- | haltdef
  }
  elseif ($nick ishop $chan) {
    echo -ti2mbfl # 15«« $nick 15»» $1- | haltdef
  }
  elseif ($nick isvoice $chan) {
    echo -ti2mbfl # 10«« $nick 10»» $1- | haltdef
  }
  else {
    echo -ti2mbfl # 6«« $nick 6»» $1- | haltdef
  }
}
 

Now I wouls like to have that on my name to.
But then the on input has to be changed And I dont know how.
Any help is welcome
my thanks upfront.

Greetzz

#153372 15/07/06 12:01 PM
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
1) Copy the IF statements and responses as you have them in the ON TEXT event, to the ON INPUT event, and place them after the first IF statement in the ON INPUT event.

2) Change all occurances of $nick in the section that you just copied to $me

Those two instructions should give you what you're looking for.

Off topic, but something I noticed, you could change
Code:
if (%a <= 9) { var %b = $+(0,%a) } | else { var %b = %a }  
to
Code:
 var %b = $iif(%a <= 9,$+(0,%a),%a) 

#153373 15/07/06 08:25 PM
Joined: Feb 2005
Posts: 344
B
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Feb 2005
Posts: 344
Thank you RusselB
Only one thing.
All the talkers aint working............
I found out i had to place them after the LAST if.
That way all the talkers still work smile


Link Copied to Clipboard