mIRC Home    About    Download    Register    News    Help

Print Thread
#150309 31/05/06 12:12 PM
Joined: May 2006
Posts: 5
B
bl4cks Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
B
Joined: May 2006
Posts: 5
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.

#150310 31/05/06 01:45 PM
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
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.

#150311 31/05/06 02:02 PM
Joined: May 2006
Posts: 5
B
bl4cks Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
B
Joined: May 2006
Posts: 5
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.

Last edited by bl4cks; 31/05/06 02:02 PM.
#150312 31/05/06 10:35 PM
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
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.

#150313 01/06/06 12:14 AM
Joined: May 2006
Posts: 5
B
bl4cks Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
B
Joined: May 2006
Posts: 5
RusselB thanks for helping, but it doesnt work. With your code, script dont announce anything smirk

#150314 01/06/06 01:45 AM
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
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.


Link Copied to Clipboard