mIRC Homepage
Posted By: Marco Need a bit of help please - 17/02/03 03:57 AM
Hi
I have a script that says a phrase when i get in the channel but should only say the message in the channels that are listed on the ini files it works but when I join a channel that is not on the list it sends a blank message like this <marco>
how to avoid to send this blank line sto the channels that are not on the list?
Code:
 
on 1:join:*:{ 
  if ($nick == $me)  {
    set %joinmsg $readini system\joinchans.ini join $chan  
    msg $chan 7  [ [ %joinmsg ] ] 


  }
}
 

Posted By: hyp0r Re: Need a bit of help please - 17/02/03 04:03 AM
Code:
if (%joinmsg) msg $chan 7  [ [ %joinmsg ] ] 

This code should work, basically we're just checking to see if %joinmsg has a value before we send the msg to the chan.
Posted By: Cheech Re: Need a bit of help please - 17/02/03 04:04 AM
on 1:join:*:{
if ($nick == $me) && ( $chan isin $read(channels.txt) ) {

that might not be exactly rite but along that lines basically you should need to scan the ini file with the channels for a match then execute
Posted By: Marco Re: Need a bit of help please - 17/02/03 05:03 AM
thanks guys smile
© mIRC Discussion Forums