mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Apr 2018
Posts: 24
T
Tano Offline OP
Ameglian cow
OP Offline
Ameglian cow
T
Joined: Apr 2018
Posts: 24
stupi* badword is added at list of badword.
[22:44] * <Mike> stupid
[22:44] * Jimmy sets mode: +b *!*@Swift-AEFFBFBB.verizon.net

Problem here to match the badword stupid on text speaker:

[22:44] * <Mike> Jimmy you are so 'stupid' my friend
[22:44] * <Mike> Jimmy you are so 'stupid' my friend
[22:44] * <Mike> Jimmy you are so 'stupid' my friend

Here need to give ban a Mike when is say to Jimmy you are so 'stupid' my friend, but dont read or match from badwordlist like is match on first time in simple line only the word stupid
and when is take ban the user need to notice me the user Mike take band for this reason used badword *stupid* in channel

so guys this is the script any idea suggestion how need to be this script to recognise match the badword on users text and give ban to users for using badword in channel, TY in advance


on *:start:{ $iif(!$isfile(badword.list),.write badword.list) | .hmake badword 100 | .hload badword badword.list }
#bwaddon on
on !@*:text:*:#: badword $1-
on !@*:action:*:#: badword $1-
alias -l badword {
if (!$nick(#,$nick,rv,oh%&~)) return
if (($me isop $chan) || ($me ishelp $chan)) {
if $hfind(badword,$strip($1-),1,W).data {
ban -u600 # $mask($fulladdress,2)
}
}
}

Last edited by Tano; 16/04/18 10:00 PM.
Joined: Apr 2018
Posts: 24
T
Tano Offline OP
Ameglian cow
OP Offline
Ameglian cow
T
Joined: Apr 2018
Posts: 24
I have make some change put alias bwcontrol to read check match the badword but till now i didnt fixed get this problem frown

i am waiting suggestion from u guys to help me what is wrong in this code now , how to make it work to ban the user when is say in channel the badwords from the list i added with wildcard

alias bwcontrol {
var %:kontroll = 1 | while %:control <= $strip($1)(#,0) {
if $hfind(badword,$strip($1)(#,%:control),1,W).data {
.echo $token(%:c,%c,32) [ CONTROL ] $strip($1)(#,%:control) Badword Matched $+([,$chr(32),$hget(badword,$hfind(badword,$strip($1)(#,%:control),1,W).data),$chr(32),])
ban -u300 # $mask($fulladdress,2)(#,%:control)
}
inc %:control
}
}

on *:start:{ $iif(!$isfile(badword.list),.write badword.list) | .hmake badword 100 | .hload badword badword.list }
#bwaddon on
on *:text:*:#: badword $1-
on *:action:*:#: badword $1-
alias -l badword {
if (!$nick(#,$nick,rv,oh%&~)) return
if (($me isop $chan) || ($me ishelp $chan)) {
if $hfind(badword,$strip($1-),1,W).data {
echo $token(%:c,%c,32) [ BADWORD ] $strip($1-) Badword is Indetifier From The List. $+([,$chr(32),$hget(badword,$hfind(badword,$strip($1-),1,W).data),$chr(32),])
var %:c $regsubex($str(-,$read($strip($1-),0)),/./g, $iif($regex($badword($read($strip($1-),\n),$me).pbadword,/(%|@|&|~\.)/i),$read($strip($1-),\n) $chr(32)))
var %c = 1 | while %c <= $token(%:c,0,32) {
mode # $token(%:c,%c,32) +b $mask($fulladdress,2) | notice $nick 5Stop Dont Swear..
echo $chan [ Indetifier ] $strip($1-) Is Indetifier The Badword From The List. $+([,$chr(32),$hget(badword,$hfind(badword,$strip($1-),1,W).data),$chr(32),])
}
}
}
}

Example what i mean and what i need to do here :

[22:44] * <Mike> stupid
[22:44] * Jimmy sets mode: +b *!*@Swift-AEFFBFBB.verizon.net

This now is ok match the badword on line simple word

Here in second example down i want Mike when is say to Jimmy you are a *stupid" my friend, to get banned for the word *stupid* i have add in badword list (stupi* is added in badword list)

[22:44] * <Mike> Jimmy you are so 'stupid' my friend
[22:44] * <Mike> Jimmy you are so 'stupid' my friend
[22:44] * <Mike> Jimmy you are so 'stupid' my friend

Problem is here to match the badword stupid on text speaker

Mike didnt get ban here on his text frown

I added in badword list the word stupi* now when Mike say to Jimmy your so stupid my frined in teory need to ban Mike for the word *stupid* , so the script dont give notice to me with echo badword matched from Mike text and dont ban Mike, so guys help to fix this problem frown , TY in advance .

Last edited by Tano; 17/04/18 12:15 AM.

Link Copied to Clipboard