Page 1 of 23 12311 ... LastLast
Results 1 to 10 of 225
  1. #1
    Plugin Developer
    Join Date
    Mar 2014
    Location
    Austria
    Posts
    104

    Language Enforcer [1.0.3.0] (Apr 11.)

    Hello Procon-Forum!

    I want to present my LanguageEnforcer plugin to you. It is written for best performance and only uses 62KB on the harddisk.

    Background Information

    The idea for the plugin comes from Soarda and his "Watchdog - Language" Plugin. Since he was offline for over a year from today and I had a different architectural concept in mind I wrote the plugin from scratch with some of the more basic code "borrowed" from the ProconRulz Plugin (e.g. Logging, Say, Kill, Kick, ...). It was written to maintain peace of mind as a Funclan server admin in the first place and now I want to share my efforts with the community.


    What does it do?

    Basically the plugin aims to prevent swearing orgies. It warns Players for bad language and will take further measures when they continue to swear. Since we don't want to punish players for things they have said weeks ago the plugin has a cooldown mechanism. The measures are freely configurable and can contain the following: Warn, Kill, Kick, TBan, PermBan. There are different options for each of them.
    Since no wordlist can ever be perfect I included commands for manually punishing players and for resetting a player's history.


    How can I get it?

    No payment is required for the full version and for any following update. Since 14th July 2014 the plugin contains a "Donate"-Button at the end of the plugin description, which is to be used completely voluntarily. I certainly will not feel obligated to fulfill requests just based on donations.

    Current Version is 1.0.3.0
    The newest release version can always be downloaded here: >>> Release.zip <<<

    To install just copy "LanguageEnforcer.cs" to the Plugins/BF4 directory. You can also copy the 2 wordlists there to have them loaded after a fresh install or after you enable the plugin.

    If you're dealing with racism you can have a look at post #94 which contains a well tested regex to recognize variations of the most common racist word.

    This was tested with BF4.
    Should work flawlessly with any other game. It has been reported to work with BF3 and BF Hardline.


    Detailed feature list - Blue ones are already covered by Soarda


    • 2 Wordlists with wordlist sections (1 simple and 1 with regular expressions)
    • AdKats support (Get admins from Adkats and AdKats punish or Ban/Kick/Kill via AdKats)
    • Possibility to trigger Procon console commands
    • 2 modes for Whitelisting ( do nothing / warn only )
    • Freely configurable sequence of actions (e.g. warn can follow kick)
    • Freely configurable messages for every single step (with placeholder and globalization functionality)
    • Configurable cooldown (similar to the Watchdog)
    • Commands for manual punishing, reprieving, reading and modifying a player's counter
    • Wait for spawn to kill if the swearing player is dead (can be disabled)
    • Loads and saves badwords from/to file (if possible)
    • Is able to persist counters for each player in a file (if possible)
    • Additional commands If needed: !admin, !rules, !help
    • Customizable messages


    The way of finding a Badword itself should be ~35-40% faster than the way the Watchdog uses (according to my test cases). Since some of my improvements can easily be applied to most plugins and especially the Watchdog, I posted a List of them here.


    How to configure messages


    Following placeholders work in ANY configurable message:
    %player% name of the player
    %time% TBan minutes or Yell seconds
    %count% current language counter for the player
    %cooldown% ------------- The cooldown setting
    %quote% The exact thing that was written by the player
    {any text} Text between curly brackets will only be shown if the next measure is different from the current one (e.g. warn is not kill). This is only done for measure related messages. It just will be removed anywhere else.
    {{countrycode}} Must stand in front of a message. For instance a message starting with {{at,ch}} will only be visible for players from Austria and Switzerland. Explained here
    {{-countrycode}} Must stand in front of a message. For instance a message starting with {{-at,ch}} will NOT be visible for players from Austria and Switzerland, but to all others.
    Please note, that curly brackets cannot be used for messages in procon anyways.


    How to configure commands


    This plugin allows to define custom commands to interface with other plugins for instance.
    Each measure and each section has a command setting where you can put them. Custom commands work exactly the same as it works in ProconRulz. You can for instance use this to trigger certain functions in AdKats. It also offers the possibility to only execute a command when a certain counter is exceeded.
    Attention! This limit is checked BEFORE the counter is increased!
    So if you wanted to call another Plugin, but just not the first time the player wrote a badword you can use the following command:
    Code:
    le.isMinCounter 1 procon.protected.plugins.call SuperAwesomePlugin SuperAwesomeFunction %player%
    If you want to trigger it at any time it looks like this:
    Code:
    procon.protected.plugins.call SuperAwesomePlugin SuperAwesomeFunction %player%


    What if I find a BUG?

    Feel free to report any bug on my issue tracker.
    If you provide code within the Issue Tracker I sure will review it and integrate the code if it really helps.
    Developers also can easily create a fork of my source code there to make their own enhancements.

    Changelog


    1.0.2.0 --> 1.0.3.0
    • Added command functionality to all measures.
    • Added le.isMinCounter command prefix.
    • Settings added to ban via PB Guid instead of EA Guid
    • Added %quote% placeholder to be able to log what the player actually said.
    • Messages can now be defined by country (I will refer to that as "localization")

    1.0.1.1 --> 1.0.2.0
    • AdKats support (Get admins from Adkats and AdKats punish or Ban/Kick/Kill via AdKats)
    • Measure overrides can now decide not to use AdKats punish and use e.g. AdKats ban instead.
    • New Measure: Custom, which executes a Command on the Procon Commandline. (Code stolen from ProconRulz )
    • New Measure: Show Rules
    • All in-game messages can now be more than one line.
    • Made PayPal Donate button smaller and moved it to the top

    1.0.1.0 --> 1.0.1.1
    • Fixed Bug where measure overrides were not saved
    • Fixed Bug to ignore character casing of commands.
    • Made PayPal Donate button work properly

    1.0.0.0 --> 1.0.1.0
    • Fixed Bug on July 16th to prevent the server from warning itself for Language
    • Introduced Wordlist sections with section overrides.
    • Changed Details tab design to match this post

    0.9.8.4 --> 1.0.0.0
    • Fixed Bug on April 20th where the plugin didn't show settings due to non-present wordlist TXTs.
    • Fixed Bug where regex completely messed up due to encoding (Thanks, PapaCharlie9, for your help!)
    • Successive countermeasures completely rewritten as a bunch of settings (adaptive to what is selected) to allow individual messages and tban/yell time settings
    • Added message placeholder functionality
    • Added option to write the counters to a file to load after layer restart (done when the server is empty, with option to write after every punish)
    • Added separate cooldown for admin-users
    • Regex Lines may now be empty or contain only a comment
    • Added in-game command for reading/writing a player's counter
    • Added configurable update-checks
    • Moved Commands to the top of the settings for faster access
    • Now puts the matched word into the logfile
    • Added timestamps to the logfile
    • Added special thanks section to the plugin description.
    • Licence: Now using LGPL v3 instead of no licence

    0.9.8.2 --> 0.9.8.4
    • Fixed Bug where settings didn't save at all

    0.9.8.0 --> 0.9.8.2
    • Fixed Bug where the "4 - Messages" settings were overwritten
    • Fixed Bug where !rules could be triggered if ext. functions were disabled
    • Message settings for ext. functions now disappear if ext. functions are disabled
    • Added warning if the wordlist contains unnecessary entries
    • Added option to ignore the Squad Chat

    0.9.7.2 --> 0.9.8.0
    • Fixed Bug: Now allows empty wordlists
    • Removed all occurences of "BF4" in the code to support all Procon supported games
    • Commands can now be triggered via ! @ # / instead of ! only
    • Most messages can now be customized
    • Cooldown now allows steps of 0.01 per day
    • Settings categorized
    • Setting "kick admins" replaced by "warn whitelisted"
    • Punish/Reset via settings trims off whitespaces
    • Performance improvement by not registering to all events






    Have fun!
    Last edited by PacmanTRT; 11-04-2015 at 12:16. Reason: new Version released

  2. #2
    Nice. Thanks for your effort and for sharing.

    I'll definitely check it out.

  3. #3
    The BF4 tag got lost in the post move. @Pacman, you can re-add it by editing post #1 in Advanced Mode. Is there any reason exclude BF3? Has it not been tested on BF3?
    Don't send me private messages (PMs) unless you really need privacy, like your game server password. If you just have a question or need help, post in one of the threads. It's extra work for me to answer questions and give help in private messages and no one else gets the benefit of the answer.

  4. #4
    Plugin Developer
    Join Date
    Mar 2014
    Location
    Austria
    Posts
    104
    The core features should work with BF3, but it will at least try to read/write to the BF4 plugins folder (logging + badword lists). You can fix that by searching for "BF4" in the code.
    Since I have no possibility of testing it with BF3, I do not officially support it.
    Last edited by PacmanTRT; 06-04-2014 at 12:25. Reason: Code doesn't conatain "BF4" anymore

  5. #5
    Awesome work, I'll have a look.

    edit: It doesn't seem to have any word list sections like watchdog I just loaded it to have a look.
    Last edited by -Slayer-; 03-04-2014 at 05:22.


    Donating keeps them going, please help out. (click sigs)

  6. #6
    Plugin Developer
    Join Date
    Mar 2014
    Location
    Austria
    Posts
    104
    It does have Settings for the Wordlists. "Badwords" and "Regex Badwords".
    It just does not have 6 of each.

    I know the settings could be better organized than just this bunch of settings, but this is the very first release and it was OK for my own needs. I already set up an item in my issue tracker for categorizing the settings.
    Last edited by PacmanTRT; 03-04-2014 at 06:40.

  7. #7
    Quote Originally Posted by PacmanTRT View Post
    It does have Settings for the Wordlists. "Badwords" and "Regex Badwords".
    It just does not have 6 of each.

    I know the settings could be better organized than just this bunch of settings, but this is the very first release and it was OK for my own needs. I already set up an item in my issue tracker for categorizing the settings.
    Yeah no drama I know it's new and all good things take time, I also must not have read it right in the first post or was mixing up thoughts with watchdog which works across BF3/BF4, the best thing that would fix watchdog and yours in the future would be separate timers for each word list when you get it to that stage, for normal swearing a timed ban then for say racist swearing a separate ban time you can set separate to the rest and longer.

    As great as watchdog is the same timed ban across the board is limiting but still a great plugin to say the least.

    Good luck with yours in the future, I'll be watching.


    Donating keeps them going, please help out. (click sigs)

  8. #8
    Plugin Developer
    Join Date
    Mar 2014
    Location
    Austria
    Posts
    104
    My plugin might work with BF3. I just don't have a BF3 server to test that yet.

    I'll add the "really bad words" thing as a feature request.
    Just to get it right: Would it be OK for you if you have a second set of Lists and settings named "minimum measure" and "minimum tban minutes" for the second set? Maybe I could also use that if he posts a configurable number of "normal badwords" (but that primarily would be a source of bugs).

  9. #9
    Quote Originally Posted by PacmanTRT View Post
    My plugin might work with BF3. I just don't have a BF3 server to test that yet.

    I'll add the "really bad words" thing as a feature request.
    Just to get it right: Would it be OK for you if you have a second set of Lists and settings named "minimum measure" and "minimum tban minutes" for the second set? Maybe I could also use that if he posts a configurable number of "normal badwords" (but that primarily would be a source of bugs).
    I'll try and find some time to test it as it sits on BF3 with one of my word lists.

    In BF3/4 I run three word lists which all have the same TBan time, normal language, racist language & regex string lines for admin abuse.

    I can see how things could get heavy with all the extra scripting and all and I wouldn't even know how to do what you lot do it boggles my mind.

    So you would know the best way to do your own plugin, with how you want it to be.

    Your idea sounds ok having the 2 timers for each of the 2 lists.


    Donating keeps them going, please help out. (click sigs)

  10. #10
    Procon Plugin Tester
    Join Date
    May 2011
    Location
    Brazil
    Posts
    554
    Instead of kicking and banning, is prohibited truncating words?

    Example:

    Get out black

    Get out "....."
    http://www.phogue.net/forumvb/image.php?type=sigpic&userid=3215&dateline=1326598  261

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •