mIRC Homepage
Posted By: xyzzy alias bad nick - 23/01/09 05:53 AM
alias kotunick /msg # $1 ur nick is bad change it | /.timer 1 60 mode # +b * $+ $1 $+ !*@* | /.timer 1 60 kick # $1 bye bye
what i want to do after warn it if nick is not on the room after 60 sec i want i dont anything if its still on ban it confused
Posted By: bluenzo Re: alias bad nick - 23/01/09 06:12 AM
alias kotunick {
msg # $1 $+ , Your nick is bad, please change it.
timerck $+ $nick 1 1 checknick $chan $1
}
alias -l checknick {
if ($2 ison $1) {
mode $1 +b * $+ $2 $+ !*@*
kick $1 $2 Your nick is bad, please change it.
}
}
Posted By: Tomao Re: alias bad nick - 23/01/09 07:30 AM
Code:
alias kotunick {
  msg $chan $1 $+ , your nick is bad. Please change it in 60 secs or you will be kicked and banned.
  .timerck $nick 1 60 checknick $chan $1
}
alias -l checknick { mode $chan +b * $+ $1 $+ !*@* | kick $chan $1 bye bye. }
Posted By: xyzzy Re: alias bad nick - 23/01/09 09:19 AM
thnx bluenzo works well smile
Posted By: xyzzy Re: alias bad nick - 21/02/09 05:11 AM
Originally Posted By: bluenzo
alias kotunick {
msg # $1 $+ , Your nick is bad, please change it.
timerck $+ $nick 1 1 checknick $chan $1
}
alias -l checknick {
if ($2 ison $1) {
mode $1 +b * $+ $2 $+ !*@*
kick $1 $2 Your nick is bad, please change it.
}
}

got a problem with the code when i warn more nick than 1
ex 2 nicks its not gonna ban/kick othes just ban/kick the last one i warned so need some changes i think to kick/ban all nicks i warned ??
Posted By: argv0 Re: alias bad nick - 21/02/09 05:33 AM
you only scripted it to do anything with $1, so that's all it's going to do.

you can use a while loop to perform the command for all nicks in the command (loop over $1-), or add a new alias:

alias kotunicka { kotunick $* }

that will perform the command on all the nicknames individually (or you could script that more elegantly to use one alias)

but I'm not here to write code for you, just throw out some ideas.
Posted By: xyzzy Re: alias bad nick - 21/02/09 05:37 AM
the same its warning all nicks but
doing ban/kicks only the last nick
Posted By: argv0 Re: alias bad nick - 21/02/09 06:13 AM
That's pretty well impossible, given that you have /msg $1 with no loop, so it can only message one nick. How are you using this alias?
Posted By: xyzzy Re: alias bad nick - 21/02/09 06:16 AM
menu nicklist {
.kicker { kotunick $* }
}
well what i want is this code opening timer for warned nick
but if i warn much nicks its works on last nick
need make it work for all nicks i warned
Posted By: argv0 Re: alias bad nick - 21/02/09 06:21 AM
timerck $+ $nick 1 1 checknick $chan $1

should be

timerck $+ $1 1 60 checknick $chan $1
Posted By: Tomao Re: alias bad nick - 21/02/09 06:24 AM
Why not use the $snicks identifier:
Code:
alias kotunick {
  msg $chan $snicks $+ , your nick is bad. Please change it in 60 secs or you will be kicked and banned.
  .timerkick 1 60 kicksnicks
  .timerban 1 60 bansnicks
}
alias -l kicksnicks { 
  tokenize 44 $snicks
  mode # +b $* $+ !*@*
}
alias -l bansnicks {
  tokenize 44 $snicks
  kick # $* Your nick is bad, please change it.
}

Just highlight the nicks you want to kick and ban.
Posted By: xyzzy Re: alias bad nick - 21/02/09 06:29 AM
man ur not geting what i did ask
thats ok i know how to change the timer time
im asking abt
ex; i warn 3 nicks in 20 sec
the code only ban/kick the last nick i warned
--
ok tried urs Tomao
(01:27:27) <@Away> nick1, your nick is bad. Please change it in 60 secs or you will be kicked and banned.
(01:27:29) <@Away> nick2, your nick is bad. Please change it in 60 secs or you will be kicked and banned.
(01:27:31) <@Away> nick3, your nick is bad. Please change it in 60 secs or you will be kicked and banned.
(01:27:34) * Away sets mode: +b nick3!*@*
i hope u guys got me what i meant now its only banning last nick


Posted By: Tomao Re: alias bad nick - 21/02/09 06:37 AM
If you used $snicks, your nick should be listed horizontally, not vertically.

<Tomao> >bot1,>bot2, your nick is bad. Please change it in 60 secs or you will be kicked and banned.

It works for me. First you need to highlight the nicks (press down the ctrl key and click as many nick as you wish in your nicklist), then you enter /kotunick
Posted By: xyzzy Re: alias bad nick - 21/02/09 06:41 AM
yup its work if u warn nick1,nick2,nick3 at the same time
pls check what i posted before nicks warned at different times

Posted By: Tomao Re: alias bad nick - 21/02/09 06:47 AM
I did read your post before I posted mine. But what your showed me should have looked like this:

(01:27:27) <@Away> nick1,nick2,nick3,your nick is bad. Please change it in 60 secs or you will be kicked and banned.

Did you see the difference?
Posted By: xyzzy Re: alias bad nick - 21/02/09 06:53 AM
menu nicklist {
.kicker { kotunick $* }
}
im using it with this
thats why and i warn one by one
need it like that warn one by one not at the same time
and all warned nicks should ban/kick as urs do for warned nicks at the same time
Posted By: argv0 Re: alias bad nick - 21/02/09 06:55 AM
the last change i made resolved the issue to the original script. i'm not sure why people feel the need to double the confusion factor by injecting a completely new script into the mix.
Posted By: argv0 Re: alias bad nick - 21/02/09 06:56 AM
you're obviously having problems following directions so I'll make it easy on you

Code:
menu nicklist {
.kicker { kotunick $* }
}
alias kotunick {
msg # $1 $+ , Your nick is bad, please change it.
timerck $+ $1 1 60 checknick $chan $1
}
alias -l checknick {
if ($2 ison $1) {
mode $1 +b * $+ $2 $+ !*@*
kick $1 $2 Your nick is bad, please change it.
}
}


use the above.
Posted By: xyzzy Re: alias bad nick - 21/02/09 06:58 AM
Great! thank you smile
© mIRC Discussion Forums