mIRC Home    About    Download    Register    News    Help

Print Thread
Page 1 of 2 1 2
#71409 14/02/04 10:18 PM
Joined: Sep 2003
Posts: 584
B
bunar Offline OP
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Sep 2003
Posts: 584
is this possible using /ison, whois etc...

on connect, ison nick, if nick is on (/ison) serv then /whois,
show his [email]nick@host.domain[/email] ?

this dumb post is added coz i know that /ison has only 2 states YES and NO, and dunno how to make (if nick ison serv then do this and that)...

is this even possible ???????????????

#71410 14/02/04 10:37 PM
Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
just do the /ison on the server your checking if there on

#71411 14/02/04 10:38 PM
Joined: Sep 2003
Posts: 584
B
bunar Offline OP
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Sep 2003
Posts: 584
i do and it reports NICK is online or is not online, but i want it to check/show his info IF he is online

like:

/ison nick
if nick is online
/who nick
/echo his [email]nick@host.domain[/email]

Last edited by bunar; 14/02/04 10:39 PM.
#71412 14/02/04 10:49 PM
Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
/ison blah
replied to me with a

RAW 303 MYNICK BLAH
ison: BLAH

and
/ison BLAH1
replied to me with a

RAR 303 MYNICK
ison: no such user

So i guess you hook the raw 303 event and whois the person ($$2)

#71413 14/02/04 11:40 PM
Joined: Sep 2003
Posts: 584
B
bunar Offline OP
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Sep 2003
Posts: 584
sub-question on this:

at me:

raw 303:*:{
if ($var(%ison)) {
if ($2) var %reply = online, %nicks = $2-
else var %reply = offline, %nicks = %ison
thmecho $replace(%nicks, $chr(32),$chr(44) $+ $chr(32)) $& $iif(* * iswm %nicks,are,is) %reply
unset %ison
halt
}
}

(this was made by Cold all rights to him)

so i dont want to change anything with this nice code by HOOKING to raw 303 for my 1st question, is it possible and how, and if yes, how can i do it so my script in 1st case (for searching with ison and who) dont show NICK is online... (but only in this case!!! - so when i do normal /ison it works normal) ??

#71414 15/02/04 12:30 AM
Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
alt-r
click remotes TAB
click file
click new
type in the following...
Code:
 
raw 303:*:whois303 $2-
alias whois303 {
  whois $$1
  .timer 0 1 whois303 $$2-
}
 


click ok

that should whois anyone that was online from a /ison

#71415 15/02/04 02:02 AM
Joined: Sep 2003
Posts: 584
B
bunar Offline OP
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Sep 2003
Posts: 584
good, you understund me...
but 1 thing sux..

now when i ALWAYS press /ison it will execute whois, but i wanted it to do only on this special event

like /check

but when i do normal /ison it dont do /whois...

if you understand me


so itz like this:

if i do /check it should do what you made,
BUT if i do just /ison it just do ison, not /whois with it...

possible?

Last edited by bunar; 15/02/04 02:05 AM.
#71416 15/02/04 03:49 AM
Joined: Dec 2002
Posts: 332
C
Fjord artisan
Offline
Fjord artisan
C
Joined: Dec 2002
Posts: 332
not sure if this is what you want ?
Code:
  
RAW 303:*: {
  if ( $2 ) { whois $2 | halt }
}


#71417 15/02/04 04:17 AM
Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
Code:
 
alias check {
  ison $$1-
  set -u10 %check.ison.flag $true
}
raw 303:*:{
  if (%check.ison.flag == $true) {
    unset %check.ison.flag
    whois303 $$2-
  }
}
alias whois303 {
  whois $$1
  .timer 1 1 whois303 $$2-
}


I made a mistake on the timer before should be 1 1 (as above) not 0 1 (thanks Iori for the point out, else i would have copied it here without looking)

#71418 15/02/04 07:55 AM
Joined: Jan 2003
Posts: 428
P
Fjord artisan
Offline
Fjord artisan
P
Joined: Jan 2003
Posts: 428
If you have a large number of people to check for, and you then run an on:Connect to run a whois if the nick is online... you may end up flooding yourself off.

You could intercept the /notify reply instead. Have notify check on join. I don't see it mentioned much, but on some networks (like DALnet), you can actually get the user's host from the /notify reply - meaning you don't need to use /ison or /whois at all smile

PastMaster


IRCnet & DALnet @#travelersinn
:-: IRC for fun and relaxation :-:
#71419 15/02/04 12:54 PM
Joined: Sep 2003
Posts: 584
B
bunar Offline OP
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Sep 2003
Posts: 584
good, dave C i thank you, it solved my question.

thank you !

#71420 15/02/04 12:55 PM
Joined: Sep 2003
Posts: 584
B
bunar Offline OP
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Sep 2003
Posts: 584
to pastmaster:

no, i want a check QuakeNet Services (mainly Q and L) during netsplit someone could take their nicknames and i could auth to fake lamer

#71421 15/02/04 04:56 PM
Joined: Sep 2003
Posts: 584
B
bunar Offline OP
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Sep 2003
Posts: 584
yet another sub-question on this (coz i am retarded)

alias check {
ison Q
set -u10 %check.ison.flag $true
}
raw 303:*:{
if (%check.ison.flag == $true) {
unset %check.ison.flag
who303 Q
}
}
alias who303 {
who Q
.timer 1 1 who303 Q
if (Cserve isin $4) { .echo -s real Q is online }
}

-> now tell me ...
this code checks who on Q bot and itz full info is this:
TheQBot@CServe.quakenet.org

now i gave if (CServe isin $4) for searching CServe word in CServe.quakenet.org, but it dont work (and this is only way to see if this is valid network bot)

can anyone tell me how to fix this?

#71422 15/02/04 05:52 PM
Joined: Aug 2003
Posts: 1,831
I
Hoopy frood
Offline
Hoopy frood
I
Joined: Aug 2003
Posts: 1,831
Try this instead, it's a lot simpler IMHO
Code:
alias Qcheck { inc -u5 %qcheck | userip Q }
raw 340:*:{
  if %qcheck {
    if Q*TheQBot@127.0.0.1 iswm $2 { echo -site * The real Q is online | halt }
    elseif !$2 { echo -site * Q is not online }
    else { echo -site * Fake Q online $+([,$2,]) }
  }
}

#71423 15/02/04 07:59 PM
Joined: Sep 2003
Posts: 584
B
bunar Offline OP
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Sep 2003
Posts: 584
wow, it is much simplier !
thanx much, 1 crap happens tho...

after echoing real Q is online i get this echo:

(20:58) Q*=+TheQBot@127.0.0.1

how to remove it?

and can you pls explain what does this line do:
if Q*TheQBot@127.0.0.1 iswm $2

if you call userip then why itz 127.0.0.1 and all that?

Last edited by bunar; 15/02/04 08:04 PM.
#71424 15/02/04 08:11 PM
Joined: Aug 2003
Posts: 1,831
I
Hoopy frood
Offline
Hoopy frood
I
Joined: Aug 2003
Posts: 1,831
I think that is a script echo from a different script. wink

It wouldn't be timestamped if it wasn't scripted, and also my raw 304 event is halted.

and can you pls explain what does this line do:
if Q*TheQBot@127.0.0.1 iswm $2

That means if "Q*TheQBot@127.0.0.1" is a wildcard match for whatever $2 is in the 340 reply. laugh

if you call userip then why itz 127.0.0.1
The ip is set to 127.0.0.1 so that it cannot be "nuked", if you tried, you would be nuking yourself.

Edit:
Re-readi9ng it I noticed I had only halted if Q was really Q.
Code:
alias Qcheck { inc -u5 %qcheck | userip Q }
raw 340:*:{
  if %qcheck {
    if Q*TheQBot@127.0.0.1 iswm $2 { echo -site * The real Q is online }
    elseif !$2 { echo -site * Q is not online }
    else { echo -site * Fake Q online $+([,$2,]) }
    halt
  }
}

Last edited by Iori; 15/02/04 08:16 PM.
#71425 15/02/04 08:43 PM
Joined: Sep 2003
Posts: 584
B
bunar Offline OP
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Sep 2003
Posts: 584
i looked in my script, i cant find raw340 in other than your
code and while debuging i got this:
:ludd.se.quakenet.org 340 mynick :Q*=+TheQBot@127.0.0.1

so it is raw 340

and for raw 304 i only found this:
:304 | return Not Modified

#71426 15/02/04 08:49 PM
Joined: Aug 2003
Posts: 1,831
I
Hoopy frood
Offline
Hoopy frood
I
Joined: Aug 2003
Posts: 1,831
Uh yeah, It's 340, 304 was a typo blush

"(20:58) Q*=+TheQBot@127.0.0.1" That timestamp isn't in what mIRC normally prints.

Have you a "raw *:*:" event?


#71427 15/02/04 08:58 PM
Joined: Sep 2003
Posts: 584
B
bunar Offline OP
Fjord artisan
OP Offline
Fjord artisan
B
Joined: Sep 2003
Posts: 584
i got this:

raw *:* { echo $color(info2) -s $timestamps $+ $theme(logo) $2- | halt }

#71428 15/02/04 09:00 PM
Joined: Aug 2003
Posts: 1,831
I
Hoopy frood
Offline
Hoopy frood
I
Joined: Aug 2003
Posts: 1,831
LOL exactly!

Change that one to
raw &*:* { echo $color(info2) -s $timestamps $+ $theme(logo) $2- | halt }

Page 1 of 2 1 2

Link Copied to Clipboard