Plugin Info:
|
Modification: ALL
Category: General Purpose
|
AMX Mod X Plugin Approver
Join Date: Dec 2006
Location: malloc(null)
|
10-01-2012
, 12:06
Block Advertising
|
#1
|
○Description- As title suggests this is a plugin for blocking most of the adverts typed in chat. First i want to say that i know there is a similar plugin by JGHG (maybe others? but i don't remember) but this has a different approach. First, it doesn't use RegEx, i know it's powerful and flexible but not as much as this type of plugin needs because of the much cases where it can have false detects. It's based on string manipulation and can be customized in different ways. This plugin aims to block most of the adverts that can be written in chat under different forms (normal, with delimiters, white spaces, symbols, letters and so...) plus it's still in development. Before start to talk and write that something like this already exists or it can be done in a easiest way using RegEx or any other methods you know, try it! Then you may suggest improvements and post possible bugs or false detects. Thank you
○Detect
Code:
11.1.1.1
11.1.1.1:20715
11...1...1...1 (or any number of dots)
11/1/1/1
11 / 1 / 1 / 1 (any number of spaces and delimiters)
1/1.2.3/1.2/3 (any combination of delimiters)
11 1 1 1
1 2 3 1 1 3 1 2
22 l 2 l 2 l 2 (l - from leather. It can recognize letters delimiters too)
Remember, it's working for any ip format but if IP it's written without any delimiters like 123.22.4.1, an IP block (3 different blocks) must contain at least 2 digits. If IP it's written with delimiters like 1-2-3/3-1/1/2 then it must contain 3 different digits.
○Cvar- amx_advblock (Default: "abd") - Plugin mod flags
Flags
Code:
a - Block chat lines that have been detected as advert
b - Warn player that he made an advert
c - Kick player if he make more than MAX_WARNINGS adverts (per session)
d - Log chat lines that have been detected as advert ( Name and Chat line )
e - Bypass advertise check for admins with BYPASS_FLAG
○Changelog
○Requirments
○Modifications- ColorChat Use - If you want to use colors in chat, uncomment the following lines then recompile
Code:
#include <colorchat>
#define USE_COLORCHAT
- Maximum warnings before kick if you use cvar flag "c"
Code:
#define MAX_WARNINGS 3
- Bypass advertise check on admins with the following flag
Code:
#define BYPASS_FLAG ADMIN_RCON
○Files- advblock_config.ini - Configuration file must be copied into /addons/amxmodx/configs folder
- advblock_logs.log - Logs file will be created automatically in /addons/amxmodx/logs folder
Find updated plugin HERE
__________________
Still...lovin' . Connor noob! Hello
Last edited by hornet; 03-06-2015 at 19:50.
|
|
|
|