mIRC Home    About    Download    Register    News    Help

Print Thread
#129090 02/09/05 01:41 PM
Joined: Jan 2004
Posts: 133
W
Vogon poet
OP Offline
Vogon poet
W
Joined: Jan 2004
Posts: 133
Why Does This Not Work ?

on ^*:TEXT:*:#chan1,#chan2,#chan3:{
set %nsanenick $nick
set %bottxt2 $1-
if (!close isin %bottxt2) /iline @badbot 1 $nick - %bottxt2 | goto next
goto next
:next
if (%nsanenick isin BADBOT) /iline @badbot 1 $nick - %bottxt2 | goto stop
goto end
:stop
haltdef
goto end
:end
}


It Seems To ONLY work in #chan3 its weird ..
i wana stop the badbot text from being displayed in the room
darn thing says something every 2 secs lol HELP!

Is there a better faster way ?

Joined: Apr 2005
Posts: 1,009
Hoopy frood
Offline
Hoopy frood
Joined: Apr 2005
Posts: 1,009
/ignore it?


IceCapped
Joined: Jan 2004
Posts: 133
W
Vogon poet
OP Offline
Vogon poet
W
Joined: Jan 2004
Posts: 133
i cant ...

i need to have the info .. just NOT in the channel window !

lol

HELP !

Joined: Dec 2002
Posts: 83
D
Babel fish
Offline
Babel fish
D
Joined: Dec 2002
Posts: 83
after an if don't forget to set {} or mIRC could think the second term is a new line

example :
Code:
 if (!close isin %bottxt2) iline @badbot 1 $nick - %bottxt2 | goto next
 

is same as :
Code:
if (!close isin %bottxt2) iline @badbot 1 $nick - %bottxt2
goto next

take this :
Code:
 if (!close isin %bottxt2) { iline @badbot 1 $nick - %bottxt2 | goto next }
 

PS: the goto is useless here

Your new code :
Code:
on ^*:TEXT:*:#chan1,#chan2,#chan3:{
set %nsanenick $nick
set %bottxt2 $1-
if (!close isin %bottxt2) { iline @badbot 1 $nick - %bottxt2 | goto next }
goto next
:next
if (BADBOT isin %nsanenick) { iline @badbot 1 $nick - %bottxt2 | goto stop }
goto end
:stop
haltdef
goto end
:end
}


But I don't understand what you want ! If you can explain better ....
[edit]the second if was reversed ! I'm in doubt it worked before !

Last edited by dunkelzahn; 02/09/05 03:02 PM.
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
What about:

Code:
on ^*:text:*:#: {
  if ($nick == BADBOT) {
    iline @badbot 1 $nick - $1-
    haltdef
  }
}


That assumes you already have the @badbot window open. I didn't bother putting the code in to open it since you didn't have it in there either.

It will put the text from the bot in your window and nowhere else. If the bot doesn't change nicks, this should do what you need. If it does, make the if statement check multiple nicks using ||. It's set to work for all channels, but it's probably not likely to have that same nick in other channels you're in, unless it's a common nick on the bot. Just makes it easier that way rather than listing out the channels.


Invision Support
#Invision on irc.irchighway.net
Joined: Jan 2004
Posts: 133
W
Vogon poet
OP Offline
Vogon poet
W
Joined: Jan 2004
Posts: 133
Sigh ..

Well It KINDA works ..
but .. it still isnt stoping the text in the channel window !

adds it fine to the @badbot < window

the haltdef dont seem to be working ..

any thoughts ?

Joined: Dec 2002
Posts: 1,245
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Dec 2002
Posts: 1,245
there is no default to halt in an on text event.
what text are you trying to halt? the person who is inputting text in channel?

if you dont want to see the command in channel then the user who is sending a command should use a mesage or notice which can capture the text but not show the default.

Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
I'm thinking he can't control the bot and just wants text from the bot in one location and not see it in the channel. If that's not "default" text, is there a way to not display text sent in a channel or query?

I know you could manage to do it with saving/editing/loading the buffer, but that's very time consuming for the CPU to do constantly. There must be some way of doing it, I'd think.


Invision Support
#Invision on irc.irchighway.net
Joined: Dec 2002
Posts: 1,245
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Dec 2002
Posts: 1,245
hmm, I stand corrected

sample
Code:
on ^*:text:*:#:{
  echo -a $nick $1-
  haltdef
}

VS doing:

on *:text:*:#:{
  echo -a $nick $1-
  halt
}

the haltdef worked where the halt did not (for me in 6.16)
so if the haltdef is not working for you the way you want is there some other script that is handling channel text and conflicting?

Maybe change yours a bit:
on ^*:text:*:#: {
if ($nick == BADBOT) {
iline @badbot 1 $nick - $1-
haltdef
}
}
to
on ^*:text:*:#: {
if ($nick == BADBOT) {
iline @badbot 1 $nick - $1-
}
haltdef
}

Joined: Jan 2004
Posts: 133
W
Vogon poet
OP Offline
Vogon poet
W
Joined: Jan 2004
Posts: 133
yea must be a different text .. the bot is sending ...
or some other script .. blocking it ..

or something ..

cause it should work darn it !! But isnt frown

I just want it not to display the text of a bot .. in the channel window frown

Joined: Dec 2002
Posts: 1,245
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Dec 2002
Posts: 1,245
Quote:

i wana stop the badbot text from being displayed in the room
darn thing says something every 2 secs lol HELP!


your original script and any that have been posted do not have the bot "say" anything. There must be another script that has the bot posting comments on some other event(s) related to the commands in the "on text"

Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
on ^*:TEXT:*:#chan1,#chan2,#chan3:{ if ((!close isin $strip($1-)) || ($nick == BADBOT)) { iline $badbot 1 $nick - $1- | haltdef } }
alias -l badbot { var %w = @badbot | if (!$window(%w)) { window -<insert your window parameters here> %w } | return %w }


If that doesnt work then, you likely have a another ON TEXT event that is displaying the bots/others messages in the channel.
If Thats the case its alot harder but not impossable to stop it displaying.

Joined: Jan 2004
Posts: 133
W
Vogon poet
OP Offline
Vogon poet
W
Joined: Jan 2004
Posts: 133

FINALLY !

OMG What A Pain ! lol

Thanks ! That Works smile)

laugh cool smile blush grin smirk

Joined: Dec 2002
Posts: 1,245
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Dec 2002
Posts: 1,245
so.... you were trying to iline to a window that wasn't open???

good catch Dave, even though Riamus2 did indicate the window had to be opened first several posts back. Seems it wasnt.

Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
lol i wasnt even trying to catch that, thats just how i try to always refrence custom windows, i just found its easier than checking if they exist in different places in the script, just do it in the windowname identifier.


Link Copied to Clipboard