mIRC Homepage
Posted By: Bullseye on join - 31/07/05 06:47 PM
I have a script that changes the "your now talking in" message.
Now i thougt it would be nice to lett it say "your now in controle of" when i'm a op in the channel that i join and "your now a guest in" when i'm not a op.
The script that i have is this:
Code:
on ^*:JOIN:#:{ 
haltdef
if ($nick == $me) {
if ($chan != $chan:) { echo # 5********* 2Your now a guest in4 # $+ . 5*********  | cline 4 $chan $me  }
}
 }
  


Now i hoped to get it with something like this:
Code:
 
 on ^*:JOIN:#:{ 
haltdef
if ($nick == $me) {
if ($chan != $chan:) { echo # 5********* 2Your now a guest in4 # $+ . 5*********  | cline 4 $chan $me  }
}
elseif ($nick isop $chan) {
if ($chan != $chan:) { echo # 5********* 2Your now in controle of4 # $+ . 5*********  | cline 4 $chan $me  }
}
}


But i can't check it because i have no idea where to and how to put a timer in there because the message is been send before i get my ops.
So i always get the message "your now a guest in".
Thanks for helping.

Greetzz
Posted By: RusselB Re: on join - 31/07/05 09:31 PM
Give this a try
Code:
 on me:*:join:#:{
var %chan = $chan
.timer 1 3 echo -a $iif($me isop %chan,You are now in control of %chan,You are now a guest in %chan)
cline 4 $chan $me
}
 


I'm not sure what the cline does, but I noted that it was the same whether you had ops in the room or not
Posted By: Bullseye Re: on join - 01/08/05 05:37 AM
some how that don't works for me .... frown
Posted By: RusselB Re: on join - 01/08/05 07:31 AM
Code:
on me:*:join:#:echo -a You are now a guest in $chan
on *:op:#:{ if ($me == $opnick) { echo -a You have now been given control in $chan by $nick }
on *:serverop:#:{ if ($me == $opnick) { echo -a You have now been given control in $chan by $nick }  


Since my first one didn't work, that one will...although it's not exactly what you were asking for.
Posted By: xDaeMoN Re: on join - 02/08/05 08:27 PM
Try this, I revised Russelb's code

Code:
on me:^*:join:#:{
  .timer 1 3 echo -t $chan * You are now $!iif( $me isop $chan ,in control of $chan ,a guest in $chan )
  cline 4 $chan $me
  haltdef
} 
© mIRC Discussion Forums