mIRC Homepage
Posted By: bl4cks small question - 31/05/06 12:12 PM
Hello

I have problem with reannouncing text. THe thing is that if someone writes [-something-]in channel in this format, when this text is reannounced in my channel. I could easily write (-something- isin $1-) and it wont be reannounced, but the thing is that when text is announces normaly, without brackets and this (-), script filters as its the same as [-something-]. The thing i need is that this [-something-] should be not reannounced, but word something would be.
Posted By: RusselB Re: small question - 31/05/06 01:45 PM
As this is obviously a problem with a script that you have, it would help if you'd supply the code for the part of the script that is causing the problem. Please remember to use the Code tags when posting the code.
Posted By: bl4cks Re: small question - 31/05/06 02:02 PM
Code:
ON 10:TEXT:*:#:{

  if ((PRETIME isin $1-) ||  (French isin $1-) || (SWEDiSH isin $1-) || (DANiSH isin $1-) || (German isin $1-) || (DUTCH isin $1-) || (.KOR. isin $1-) || (.iTALiAN. isin $1-) || (.SATRip. isin $1-) || (.PL. isin $1-) || (.*-pre*. isin $1-)) { return }
  { msg #chan $1- }


}
  


So the problem is, that from the channel im reannouncing stuff, someone says !pre smth and bot gives him
[-NUKE-] >> (MP3) << [something [9w 2d 15m 10s] [27.03.2006] [fake]

All the time, bot announces stuff, and sometimes he announces like this:
(16:45) · @BoT · >> (NUKE) << [Tribu-Piero_Pelu_(live_totp_it_27-05-06)-XviD-IT-2006-LCF] [LCF] [oversized]

So the problem is, that i need the script to reannounce this (NUKE), which i wrote last and not to announce [-NUKE-]. Cause i dont want to see in channel, were im reannouncing, some peoples requests, given by bot. So the difference is with [-NUKE-]. and (NUKE) i need, that [-NUKE-] should be taken off of reannouncing as PRETIME in my code.
Posted By: RusselB Re: small question - 31/05/06 10:35 PM
Try this
Code:
 on 10:text:*:#:{
if $istok($1-,pretime french swedish danish german dutch .kor. .italian. .satrip. .pl.,32) { return }
elseif (.*-pre*. isin $1-) { return }
elseif ($left($1,1) == $chr(40) &amp;&amp; $right($1,1) == $chr(41)) { .msg $chan $1- }
else { return }
 


Personally I don't like using the return command like that, but in this case this was the simplest way to handle it.

Hope it works, but it is untested.
Posted By: bl4cks Re: small question - 01/06/06 12:14 AM
RusselB thanks for helping, but it doesnt work. With your code, script dont announce anything smirk
Posted By: RusselB Re: small question - 01/06/06 01:45 AM
I don't know if this is the reason it's not working or not, but I just realized I forgot a } at the end of the code. If you didn't catch that yourself, give it a try and see if that works. If it still doesn't work, leave me a pm with your network & channel, and I'll come in and see what I can do.
© mIRC Discussion Forums