AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Approved Plugins (https://forums.alliedmods.net/forumdisplay.php?f=8)
-   -   Anti-Bigot with RegX matching (https://forums.alliedmods.net/showthread.php?t=7812)

Manip 11-22-2004 15:31

Anti-Bigot with RegX matching
 
2 Attachment(s)
Version: 1.2

This is an anti-racism plugin. I have taken the most advanced version I could find and added regular expression support to it.

Place a regular expression list in your AMXx config folder called Bigot.ini (basic list supplied).

The CVAR sv_bigotmode is used to control what happens each time someone uses racism apart from it being blocked.

1 - Bans the offender for 48 hours
2 - Kicks the offender off the server
3 - Bans the offender PERMANTLY
4 - Kills the offender

Commands:
amx_bigottest <String> - Test a string to see if it is detected.

Note: Requires Regular Expression support module activated (Modules.ini).

Originally written by Bad HAL 9000 with help from BAILOPAN and FreeCode which was based off of the 'Say BS' plugin by f117bomb.. modified by JTP10181 to add killing ..

JTP has written some improvements on the 1.0b version up to 1.2 and
also included a way better regular expressions list. THANKS JTP!

Spazz 11-22-2004 15:51

Nice post. Im giving it a try.

Manip 11-23-2004 01:52

The ^ issue has been resolved. This plugin can now be used on a full range of regular expressions.

pendragon 11-23-2004 13:45

do you possibly forsee using mysql with this?
It would be awesome to have this data sent to a mysql db.

ronin 11-24-2004 02:39

This is bloody wonderfull
Best plugin ever
Great job

ronin 11-24-2004 02:46

I think there might be a problem with \w\s*jew\b
It doesn't seem to ban on this one

Morpheus 11-24-2004 07:58

Hi there!

If I want this to work with amxbans, which also automatically kicks the player.. how should the ban be?

Normal when u ban, its like amx_ban 2880 name reason

I would like it to have the ban something like it.

Code:

server_cmd("banid 2880 `"%s`" kick;wait;writeid",authtoban)
Changed to

Code:

server_cmd("amx_ban 2880 %i %s Bad language",authtoban)
Correct?

And where should bigot.txt go in the amxmodx folder?

Cheers

Morpheus

Manip 11-24-2004 09:09

Quote:

Originally Posted by ronin
I think there might be a problem with \w\s*jew\b
It doesn't seem to ban on this one

Keep in mind \w means a letter. Please excuse this, but 'fucking jew' will get detected because it has a letter, then a space then the word jew.

Currently the term 'jew' ('j3w' and 'j3w' are though) alone is not counted as racism. You can however change that:

\bj[^aeou]*w\b
becomes
\bj[^aou]*w\b

That will detect the word 'jew' always.

Morpheus:

Code:

server_cmd("amx_ban %s 2880 Bad language",authtoban)
(You had the time and authID inverted.)

ronin 11-24-2004 13:40

Quote:

Originally Posted by Manip
Keep in mind \w means a letter. Please excuse this, but 'fucking jew' will get detected because it has a letter, then a space then the word jew.

Currently the term 'jew' ('j3w' and 'j3w' are though) alone is not counted as racism. You can however change that:

\bj[^aeou]*w\b
becomes
\bj[^aou]*w\b

That will detect the word 'jew' always.

I would keep it in mind if i could figure out how the expressions worked :)

Morpheus 11-24-2004 15:55

Quote:


Morpheus:

Code:

server_cmd("amx_ban %s 2880 Bad language",authtoban)
(You had the time and authID inverted.)
What does %s do?

Because the amxban command is like this:

amx_ban time name reason and not like amx_ban player time reason? Wrong

And where should the txt file go?

Cheers

Morpheus


All times are GMT -4. The time now is 07:10.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.