Raised This Month: $51 Target: $400
 12% 

[ANY] Regex Name Filter


Post New Thread Reply   
 
Thread Tools Display Modes
mikma
Junior Member
Join Date: Apr 2015
Old 04-17-2015 , 05:10   Re: [ANY] Regex Name Filter
Reply With Quote #11

Quote:
Originally Posted by friagram View Post
It might depend on the game, valve did recently change how names work so this could have broke, or it could just be that game
This happens with Insurgency 2014. the Unicode Name Filter does change the name properly, but it does not support scandinavian alphabets (åäöÅÄÖ).
mikma is offline
friagram
Veteran Member
Join Date: Sep 2012
Location: Silicon Valley
Old 04-22-2015 , 01:21   Re: [ANY] Regex Name Filter
Reply With Quote #12

Quote:
Originally Posted by mikma View Post
This happens with Insurgency 2014. the Unicode Name Filter does change the name properly, but it does not support scandinavian alphabets (åäöÅÄÖ).
Perhaps you can try changing the compileregex line,
https://sm.alliedmods.net/api/index....ad=file&id=52&

Right now it is using
PCRE_CASELESS 0x00000001 /* Ignore Case */

Perhaps try adding
PCRE_UTF8 0x00000800 /* Use UTF-8 Chars */

So change
PCRE_CASELESS
To
PCRE_CASELESS|PCRE_UTF8
__________________
Profile - Plugins
Add me on steam if you are seeking sp/map/model commissions.
friagram is offline
ijam_j
Member
Join Date: Mar 2007
Old 12-02-2015 , 22:24  
Reply With Quote #13

I want to convert names like me?badwords to me?******** or names like one>fword to one>*****

Is this the correct contents of namefilter for me?

Code:
"filters"
{                                                                           
    "censor"    "*" 
    "filter"    "[^A-Za-z0-9\s!@#$%^&*()_+=-`~\\\]\[{}|';:/.,?><]"         // not sure about this line
    
    "banned"                                                               
    {
        "1" "badword" // whats the purpose of 1?
        "2" "fword"     // whats the purpose of 2?
    }
}
thanks.

Quote:
Originally Posted by ijam_j View Post
I want to convert names like me?badwords to me?******** or names like one>fword to one>*****

Is this the correct contents of namefilter for me?

Code:
"filters"
{                                                                           
    "censor"    "*" 
    "filter"    "[^A-Za-z0-9\s!@#$%^&*()_+=-`~\\\]\[{}|';:/.,?><]"         // not sure about this line
    
    "banned"                                                               
    {
        "1" "badword" // whats the purpose of 1?
        "2" "fword"     // whats the purpose of 2?
    }
}
thanks.
With this, player name are replaced with bad_words. If i put name replacement, it will be replaced with name replacement.

what i want is to replace bad words with *. i dont want to replace with other names. how do i do that?

what is the point of the number before the bad words?

Quote:
Originally Posted by Schpraaankiii View Post
What do I change the filter to if I want the players to be able to use unicode symbols?
This. All i want is to filter bad word and replaced bad words with *.

This is what I use to whitelisted UTF8

Code:
"filter"    "[^\32-\151]/ ( == /[^!-~]/ )"

Last edited by sneaK; 06-13-2019 at 00:27. Reason: merged numerous posts
ijam_j is offline
Reply



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 03:06.


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