mIRC Home    About    Download    Register    News    Help

Print Thread
#164285 09/11/06 11:43 PM
Joined: Oct 2006
Posts: 342
L
learn3r Offline OP
Fjord artisan
OP Offline
Fjord artisan
L
Joined: Oct 2006
Posts: 342
how to get all the nicks that i kicked
and when i press f2
il get i have kicked nicks : nick , nick , nick , nick

#164286 09/11/06 11:51 PM
Joined: Jan 2006
Posts: 61
C
Babel fish
Offline
Babel fish
C
Joined: Jan 2006
Posts: 61
The same way you do for count how many kicks you have done you could do for set a var with the nick you kick, and then these nick is writed in a *.txt with all the nick you been kicked.
To view all the nicks all you need to do is creat a alias called F2 { ... }, and all you need is read the .txt file line by line using while command!

Thats all

*


The practice do the Master...
#164287 09/11/06 11:54 PM
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
or you could just store the nicks in a variable when the kick command is issued, then have the variable echoed when F2 is pressed

#164288 10/11/06 12:21 AM
Joined: Oct 2006
Posts: 342
L
learn3r Offline OP
Fjord artisan
OP Offline
Fjord artisan
L
Joined: Oct 2006
Posts: 342
Can i get a code pls?

#164289 10/11/06 01:07 AM
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Code:
 on *:kick:#:{
set $+(%,kick.,$chan) $addtok($($+(%,kick.,$chan),2),$knick,32)
}
alias F4 {
$iif($chan,echo $chan $($+(%,kick.,$chan),2))
}
 

Note, if there are a lot of different kicks, you might get an error indicating that the variable length is too long.

#164290 10/11/06 02:54 AM
Joined: Oct 2006
Posts: 342
L
learn3r Offline OP
Fjord artisan
OP Offline
Fjord artisan
L
Joined: Oct 2006
Posts: 342
How bout when it has to nicks set..?
and will echo Kicked: None


on ^*:kick:#:{
if ($nick == $me) && ($knick != $me) { set $+(%,kick.,$chan) $addtok($($+(%,kick.,$chan),2),$knick,32) }
}

Last edited by learn3r; 10/11/06 03:35 AM.
#164291 10/11/06 03:22 AM
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
RusselB, you're also including kicks by other people in that.

Crash N Burn, if you do it the way you suggested, there is no need for a variable because you can easily write it directly to the file. Also, the /play command would output the text file without needing a while loop.

Perhaps the best way, so you don't run into the variable length problem would be to use binvars.


Invision Support
#Invision on irc.irchighway.net
#164292 10/11/06 03:55 AM
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
I missed the fact that he only wanted the kicks that he did.
Here's a re-write
Code:
  on me:*:kick:#:{
set $+(%,kick.,$chan) $addtok($($+(%,kick.,$chan),2),$knick,32)
}
alias F4 {
$iif($chan,echo $chan $iif($($+(%,kick.,$chan),2),$v1,None))
} 

#164293 10/11/06 05:18 AM
Joined: Oct 2006
Posts: 342
L
learn3r Offline OP
Fjord artisan
OP Offline
Fjord artisan
L
Joined: Oct 2006
Posts: 342
ok Thanks working perfectly. grin

#164294 10/11/06 03:34 PM
Joined: Jan 2006
Posts: 61
C
Babel fish
Offline
Babel fish
C
Joined: Jan 2006
Posts: 61
Riamus2 you rigth, i dont even think about it =)!

Thats all

*


The practice do the Master...
#164295 11/11/06 12:02 PM
Joined: Apr 2004
Posts: 218
P
Fjord artisan
Offline
Fjord artisan
P
Joined: Apr 2004
Posts: 218
Something a little different from what you want but..

You could also in your alias (I think you're using the F2 { }) use something such as.

F2 { unset %knicks | doit $* }
doit {
set %knicks %knicks $1
kick $chan $1 "You're kicked! Mwahaha!"

; Remove this line, testing purposes only.
.echo -a :: %knicks
}

With this variation it will set the nicknames into the variable before it actually kicks them. So if you do not successfully kick them by whatever means the nickname will still appear in the %knicks variable.
(There may be a chance of the script halting do to errors aswell.)

%knicks will only return all the nicknames once the looping thru the nicknames is complete. If you echo the variable half-way thru the variable will only contain half the nicknames selected.


Live to Dream & Dream for Life

Link Copied to Clipboard