Raised This Month: $169 Target: $400
 42% 

[ANY] Anti Caps Lock


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Dr. McKay
Sir Dr. SourceMod Plugin Approver Esq. Ltd. M.D. PhD
Join Date: Aug 2011
Location: Atlantis
Plugin ID:
4350
Plugin Version:
1.1.0
Plugin Category:
General Purpose
Plugin Game:
Any
Plugin Dependencies:
Servers with this Plugin:
11 
Plugin Description:
Forces players' chat to lowercase if too many letters are uppercase
Old 09-13-2014 , 12:57   [ANY] Anti Caps Lock
Reply With Quote #1

[ANY] Anti Caps Lock

v1.1.0

Description:
Same idea as this plugin, but it uses Simple Chat Processor instead of blocking/sending the say/say_team commands.

Cvars:
  • anti_caps_lock_version - plugin version
  • anti_caps_lock_auto_update - enables automatic updating (has no effect if Updater is not installed)
  • anti_caps_lock_percent (default 0.9) - percent of letters that must be uppercase before the entire message is lowercased
  • anti_caps_lock_min_length (default 5) - minimum number of letters required before the uppercase check is performed

Overrides:
  • anti_caps_lock_immunity (default root) - admins with access to this override will not have their messages manipulated; this can be overridden in admin_overrides.cfg.

Requirements:
You need Simple Chat Processor (Redux)

Installation:
Install Simple Chat Processor (Redux) if you don't have it already, and then put anticapslock.smx into /addons/sourcemod/plugins and reboot your server or type "sm plugins load anticapslock" into your console or rcon.

Auto Update:
Install Updater. The plugin will be auto-updated according to your Updater settings. It'll work without Updater.

Changelog:
  • v1.1.0 (9/22/14)
    • Added admin immunity
  • v1.0.0 (9/13/14)
    • Initial release

Download Plugin (anticapslock.zip)
View Source (anticapslock.sp)


Requires updater.inc, scp.inc and mckayupdater.sp to compile.
__________________

Last edited by Dr. McKay; 09-22-2014 at 15:49.
Dr. McKay is offline
robotortoise
Senior Member
Join Date: Nov 2013
Location: Somewhere in the US
Old 09-14-2014 , 01:04   Re: [ANY] Anti Caps Lock
Reply With Quote #2

neat! Awesome idea.
__________________
-Robotortoise [Palutena's Bro]

If you ever need help with Wii/Gamecube/DS sounds/music/ect., I'm your man!

Contact me via Steam

I don't bite.


How to loop and compress .wav files

Me and my friends' server
robotortoise is offline
Happy DODs player
AlliedModders Donor
Join Date: Sep 2009
Old 09-14-2014 , 05:08   Re: [ANY] Anti Caps Lock
Reply With Quote #3

Handy
__________________
Happy DODs player is offline
altair540
Member
Join Date: Dec 2012
Old 09-20-2014 , 22:20   Re: [ANY] Anti Caps Lock
Reply With Quote #4

Dr. McKay, How to add your language for example Russian?
Quote:
"А" - "Я"
"а" - "я"
altair540 is offline
Dr. McKay
Sir Dr. SourceMod Plugin Approver Esq. Ltd. M.D. PhD
Join Date: Aug 2011
Location: Atlantis
Old 09-21-2014 , 01:47   Re: [ANY] Anti Caps Lock
Reply With Quote #5

Quote:
Originally Posted by altair540 View Post
Dr. McKay, How to add your language for example Russian?
I don't plan to add support for multiple languages, but you could edit the plugin and replace 'A' with your language's first uppercase letter, 'Z' with your language's last uppercase letter, 'a' with your language's first lowercase letter, 'z' with your language's last lowercase letter.

I don't know if CharToLower works in languages other than English though.
__________________
Dr. McKay is offline
altair540
Member
Join Date: Dec 2012
Old 09-21-2014 , 05:56   Re: [ANY] Anti Caps Lock
Reply With Quote #6

Quote:
Originally Posted by Dr. McKay View Post
I don't plan to add support for multiple languages, but you could edit the plugin and replace 'A' with your language's first uppercase letter, 'Z' with your language's last uppercase letter, 'a' with your language's first lowercase letter, 'z' with your language's last lowercase letter.

I don't know if CharToLower works in languages other than English though.
With the replacement I know, I just wanted to, and English and Russian.
altair540 is offline
altair540
Member
Join Date: Dec 2012
Old 09-21-2014 , 06:08   Re: [ANY] Anti Caps Lock
Reply With Quote #7

With the replacement on his tongue did not work, the error when you compile the plugin.
altair540 is offline
eric0279
AlliedModders Donor
Join Date: May 2007
Old 09-21-2014 , 06:15   Re: [ANY] Anti Caps Lock
Reply With Quote #8

Hello,

great plugin! Could you add a immunity for a flag?
eric0279 is offline
Dr. McKay
Sir Dr. SourceMod Plugin Approver Esq. Ltd. M.D. PhD
Join Date: Aug 2011
Location: Atlantis
Old 09-22-2014 , 15:49   Re: [ANY] Anti Caps Lock
Reply With Quote #9

Quote:
Originally Posted by eric0279 View Post
Hello,

great plugin! Could you add a immunity for a flag?
Done, see the first post.
__________________
Dr. McKay is offline
eric0279
AlliedModders Donor
Join Date: May 2007
Old 09-23-2014 , 12:06   Re: [ANY] Anti Caps Lock
Reply With Quote #10

Thanks!
eric0279 is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 18:03.


Powered by vBulletin®
Copyright ©2000 - 2018, vBulletin Solutions, Inc.
Theme made by Freecode