mIRC Home    About    Download    Register    News    Help

Print Thread
#239400 22/10/12 10:42 PM
Joined: Oct 2012
Posts: 28
H
HeRiNo Offline OP
Ameglian cow
OP Offline
Ameglian cow
H
Joined: Oct 2012
Posts: 28
Hi, I have one more problem and then my new chanBot is finished. I tryed to find it but I can't. Its about a script against wrong nicknames like with swear in it or sex. this script gives you with a wrong nickname onjoin 60 seconds to change the nick, if not changed in 60 secs the nick should be banned not the mask so the user can change and return to the room. Well, the scripts bans the mask. so thats wrong and second issue is: When user changed to an acceptable nick the script should thank newnick. It don't thanks the nick. I hope there is some one who want to look into this and can help me. The script:

Code:
;Name: Offensive Nicknames Auto Kick.
;Written By: JOMARO
;jomaro@zdnetmail.com
;http://welcome.to/jomaro
;Feb 2000
;=========================
;===Offensive Nick Kick===>
on @*:JOIN:#:{
  if (%offensive-nick-kick == on) {
    if ($nick isop $chan) || ($nick isvo $chan) || (guest isin $nick) { goto unset }
    if (coco isin $nick) || (shit isin $nick) || (goddamn isin $nick) || (dick isin $nick) || (slut isin $nick) || (bitch isin $nick) || (pussy isin $nick) || (fag isin $nick) || (horny isin $nick) || (nigger isin $nick) || (69 isin $nick) || (beaner isin $nick) || (sadam isin $nick) || (saddam isin $nick) || (qa7bah isin $nick) || (qawadah isin $nick) || (mam7onah isin $nick) || (fucker isin $nick) || (sex isin $nick) { goto warn }
    else { goto end }
    :warn
    set %offensive-chan $chan
    set %offensive-nick $nick
    .msg $chan 4 $nick 14Jouw nicknaam is hier niet toegestaan!! 10Je hebt nu4 60 seconden 10om dit te veranderen. 4Type /nick nieuwe-nick 3@ 12Room-Bot 3@
    .timer 1 60 kick-offensive-nick
    goto end
    :unset
    unset %offensive-chan
    unset %offensive-nick
    :end
  }
}
on @*:NICK:{
  if ($nick == %offensive-nick) {
    if (fuck isin $newnick) || (shit isin $newnick) || (goddamn isin $newnick) || (coco isin $newnick) || (slut isin $newnick) || (bitch isin $newnick) || (pussy isin $newnick) || (fag isin $newnick) || (horny isin $newnick) || (nigger isin $newnick) || (69 isin $newnick) || (beaner isin $newnick) || (sadam isin $newnick) || (saddam isin $newnick) || (qa7bah isin $newnick) || (qawadah isin $newnick) || (mam7onah isin $newnick) || (fucker isin $newnick) || (sex isin $newnick) { goto set }
    .msg $chan 4 $newnick 14Bedankt voor het veranderen van je nicknaam. 3@ 12Room-Bot 3@
    unset %offensive-nick
    unset %offensive-chan
    goto end
    :set
    set %offensive-nick $newnick
    halt
  }
  if (fuck isin $newnick) || (shit isin $newnick) || (goddamn isin $newnick) || (dick isin $newnick) || (slut isin $newnick) || (bitch isin $newnick) || (pussy isin $newnick) || (fag isin $newnick) || (horny isin $newnick) || (nigger isin $newnick) || (69 isin $newnick) || (beaner isin $newnick) || (sadam isin $newnick) || (saddam isin $newnick) || (qa7bah isin $newnick) || (qawadah isin $newnick) || (mam7onah isin $newnick) || (fucker isin $newnick) || (sex isin $newnick) { 
    set %on.cha.no 0
    :loop
    inc %on.cha.no
    set %on.cha $comchan($newnick,%on.cha.no)
    if (%on.cha == $null) { goto end }
    if ($me !isop %on.cha) { goto loop }
    if ($newnick isop %on.cha) || ($newnick isvo %on.cha) { goto loop }
    if (guest isin $newnick) { goto end }
    ban -u300 %on.cha $newnick 2
    kick %on.cha $newnick 4 $nick 14Jouw nicknaam is hier niet toegestaan!! 3@ 12Room-Bot 3@
    goto loop
    :end
    unset %on.cha %on.cha.no
  }
}    

alias kick-offensive-nick {
  if (%offensive-nick != $null) && (%offensive-nick ison %offensive-chan) {
    ban -u300 %offensive-chan %offensive-nick 2
    kick %offensive-chan %offensive-nick 4 $nick 14Jouw nicknaam is hier niet toegestaan!! 3@ 12Room-Bot 3@
    unset %offensive-chan
    unset %offensive-nick
  }
}
menu status,menubar,channel {
  Offensive Nicks Kick
  .ON:/set %offensive-nick-kick on | echo 3 *** De foute nick auto kick staat nu AAN
  .OFF:/set %offensive-nick-kick off | echo 3 *** De foute nick auto kick staat nu UIT
}
alias thank dialog -mo thank thank
dialog thank {
  title "Add-ons By Jomaro 2000"
  size -1 -1 200 180
  box "",1,5 0 190 70
  text "Thank you for loading this Add-on written by jomaro. Please visit my website for more add-ons and other IRC tools. Have fun.",2,10 12 180 50,left
  box "",3,5 68 190 86
  text "jomaro@zdnetmail.com",4,10 80 180 15,center
  edit "http://welcome.to/jomaro",5,33 100 130 22,center,read
  button "Visit",6,70 127 50 20
  button "Close",7,5 158 190 20,ok
}
on *:dialog:thank:init:0:/did -f thank 6
on *:dialog:thank:sclick:6:/run http://welcome.to/jomaro
on *:load:if ($version >= 5.51) { thank }


regards, Herman.

HeRiNo #239434 26/10/12 09:40 PM
Joined: Sep 2005
Posts: 2,881
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,881
Change:

ban -u300 %offensive-chan %offensive-nick 2

To:

mode # +b $nick

hixxy #239446 27/10/12 11:33 AM
Joined: Oct 2012
Posts: 28
H
HeRiNo Offline OP
Ameglian cow
OP Offline
Ameglian cow
H
Joined: Oct 2012
Posts: 28
Hi Hixxy,

thanks for your reply. I tryed what you said but it doesnt work. When I do that there is nomore ban so problem not solved. Thans anyway

Regards, Herman.

HeRiNo #239448 27/10/12 05:06 PM
Joined: Jun 2007
Posts: 933
5
Hoopy frood
Offline
Hoopy frood
5
Joined: Jun 2007
Posts: 933
He should have said:

mode %offensive-chan +b %offensive-nick
.timer 1 300 mode %offensive-chan -b %offensive-nick

So you replace the 1 line with these 2.

5618 #239520 04/11/12 09:56 PM
Joined: Oct 2012
Posts: 28
H
HeRiNo Offline OP
Ameglian cow
OP Offline
Ameglian cow
H
Joined: Oct 2012
Posts: 28
Hi 5618,

thank you verry much for your help. ! part is working great now. ! part stil not good. Maybe yoy can help me with that too. When a wrong nick Joins the channel he get banned after he get 60 secs to change the nick. That also works but when you change the nick within 60 secs the script should thank you for changing the nick. That does not work. I hope you can help me. Thank you message is already in the script.

Regards, Herman.

HeRiNo #239555 07/11/12 04:50 PM
Joined: Oct 2012
Posts: 164
D
Vogon poet
Offline
Vogon poet
D
Joined: Oct 2012
Posts: 164
Here's a more up-to-date version of the script...
Code:
on @*:JOIN:#:{
  if (%offensive-nick-kick == on) {
    if ($nick(#,$nick,ov) || (guest isin $nick) { return }
    if ($regex($newnick,/fuck|shit|goddamn|dick|coco|slut|bitch|pussy|fag|horny|nigger|69|beaner|sadam|saddam|qa7bah|qawadah|mam7onah|sex/i)) {
      msg $chan 4 $nick 14Jouw nicknaam is hier niet toegestaan!! 10Je hebt nu4 60 seconden 10om dit te veranderen. 4Type /nick nieuwe-nick 3@ 12Room-Bot 3@
      .timeroffensive. $+ $nick 1 60 kick-offensive-nick # $nick
    }
  }
}
alias kick-offensive-nick {
  if ($2 ison $1) {
    ban -u300 $1-!*@*
    kick $1- 14Jouw nicknaam is hier niet toegestaan!! 3@ 12Room-Bot 3@
  }
}
on *:NICK:{
  if ($timer(offensive. $+ $nick)) {
    var %a = $v1
    if ($regex($newnick,/fuck|shit|goddamn|dick|coco|slut|bitch|pussy|fag|horny|nigger|69|beaner|sadam|saddam|qa7bah|qawadah|mam7onah|sex/i)) {
      .timeroffensive. $+ $newnick 1 $timer(%a).secs $replace($timer(%a).com,$nick,$newnick)
      .timeroffensive. $+ $nick off
    }
    else {
      var %i = 1
      while $comchan($newnick,%i) {
        var %a = $v1
        if ($me isop %a) && ($nick(%a,$newnick,r) { msg %a 4 $newnick 14Bedankt voor het veranderen van je nicknaam. 3@ 12Room-Bot 3@ }
        inc %i
    }
  }
  elseif ($regex($newnick,/fuck|shit|goddamn|dick|coco|slut|bitch|pussy|fag|horny|nigger|69|beaner|sadam|saddam|qa7bah|qawadah|mam7onah|sex/i)) {
    var %i = 1
    while $comchan($newnick,%i) {
      var %a = $v1
      if ($me isop %a) && ($nick(%a,$newnick,r) { kick-offensive-nick %a $newnick }
      inc %i
    }
  }
}

Deega #239560 07/11/12 08:46 PM
Joined: Oct 2012
Posts: 28
H
HeRiNo Offline OP
Ameglian cow
OP Offline
Ameglian cow
H
Joined: Oct 2012
Posts: 28
Thank you verry much. I try it out and let you know.

Regards, Herman.

Deega #239572 08/11/12 01:26 PM
Joined: Oct 2012
Posts: 28
H
HeRiNo Offline OP
Ameglian cow
OP Offline
Ameglian cow
H
Joined: Oct 2012
Posts: 28
Hi,

its working now thank you but there is an other problem wich I just saw happening. When some one does a nick change he get warned and kick/banned from the 3th time

Quote:
[17:14:57] * Nachtparel is now known as NP_dutje
[17:14:57] * Room-Bot sets mode: +b *!*@place2chat.com-BC01171C.direct-adsl.nl
[17:14:57] * NP_dutje was kicked by Room-Bot ( Nachtparel Jouw nicknaam is hier niet toegestaan!! @ Room-Bot @)
[17:15:01] * Room-Bot sets mode: +l 18


so the 3rd rule "17.14.57" is this script, kicking because of a nick change.
Does any one know what to do about this?
It happens in both versions BTW.

Regards, Herman.

Last edited by HeRiNo; 08/11/12 05:25 PM.

Link Copied to Clipboard