|
Joined: Feb 2006
Posts: 307
Fjord artisan
|
OP
Fjord artisan
Joined: Feb 2006
Posts: 307 |
hello
is it possible to write all operators ip/host and the ip of a specific nick and ident in a text file when I join in every channel?
thanks
|
|
|
|
Joined: Aug 2004
Posts: 7,252
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,252 |
Yes. Writing of host addresses for active ops when you join the channel:Note this writes a different file for each channel that you join. on me:*:join:#:{
var %a = 1, %b = $nick($chan,0,o)
while %a <= %b {
.write $+($network,.,$chan,.IP.txt) $gettok($address($nick($chan,%a,o),2),-1,64)
inc %a
}
}
Regarding the IP and ident for a specific nick, note that some networks block the real IP from non-IRCops.
|
|
|
|
Joined: Feb 2006
Posts: 307
Fjord artisan
|
OP
Fjord artisan
Joined: Feb 2006
Posts: 307 |
thanks
where is the IP.txt supposed to be written?
I joined a channel and no IP.txt file created
|
|
|
|
Joined: Oct 2005
Posts: 1,741
Hoopy frood
|
Hoopy frood
Joined: Oct 2005
Posts: 1,741 |
The file will be called <network>.<channel>.IP.txt Where <network> is the current network and <channel> is the current channel (when the script executes).
-genius_at_work
|
|
|
|
Joined: Feb 2006
Posts: 307
Fjord artisan
|
OP
Fjord artisan
Joined: Feb 2006
Posts: 307 |
mmm it doesnt work for me
|
|
|
|
Joined: Aug 2004
Posts: 7,252
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,252 |
There's a possibility that you may have to use a different name for the file. I put the network and channel information into the file name, so that mIRC wouldn't recognize the windows reserved word of IP, although, that might not have worked. Try changing the IP in the file name to something else.
|
|
|
|
Joined: Feb 2006
Posts: 307
Fjord artisan
|
OP
Fjord artisan
Joined: Feb 2006
Posts: 307 |
can you transform this pseudocode into code please ? on me:join:#:
who $chan
timer 1 2
alias listip { //var %i = 1 | while ($nick($chan,%i,o,r)) { who $chan | protect $address($v1,2) | inc %i } } thanks
|
|
|
|
Joined: Aug 2004
Posts: 7,252
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,252 |
on me:*:join:#:{
updatenl
var %i = 1
while $nick($chan,%i,o) {
.protect $nick(#,%i,o) $chan 2 $network
inc %i
}
}
If you don't want the protection to be channel specific, remove the $chan from protect line, also, if you don't want it to be network specific, remove the $network from that same line.
|
|
|
|
Joined: Feb 2006
Posts: 307
Fjord artisan
|
OP
Fjord artisan
Joined: Feb 2006
Posts: 307 |
on me:*:join:#:{
updatenl
var %i = 1
while $nick($chan,%i,o) {
.protect $nick(#,%i,o) $chan 2 $network
inc %i
}
}
If you don't want the protection to be channel specific, remove the $chan from protect line, also, if you don't want it to be network specific, remove the $network from that same line. I leave the 2 or I remove it too? like this? on me:*:join:#:{
updatenl
var %i = 1
while $nick($chan,%i,o) {
.protect $nick(#,%i,o) 2
inc %i
}
} whats updatenl? I cant find it in the helpfile... which is better? this https://forums.mirc.com/ubbthreads.php?ubb=showflat&Number=175999&page=0#Post175950or this https://forums.mirc.com/ubbthreads.php?ubb=showflat&Number=175999&page=0#Post175964(both doesnt work for me)
Last edited by nataliad; 01/05/07 08:34 PM.
|
|
|
|
Joined: Aug 2004
Posts: 7,252
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,252 |
1) Leave the 2. That parameter is being used to tell the protect line what format to protect. For other options see /help $mask
2) I don't know why you can't find it, unless you're using a help file that is out of date, or you're entering the word incorrectly. I'm using the help file from mIRC 6.21 and here's the spelling using capitals, so that the letters are easier to distinguish. /help /UPDATENL 3) If neither of those posts work for you, then it makes little sense for me to review them and recommend one.
|
|
|
|
|