When a new user is logged, we use Atlas Search to see if their username is offensize, this is a fuzzy Search against a corpus of 1300 offensive words.
The definition of fuzzy can be adjusted using Atlas Search and results are ranked by best match.
We can use this to determine an algorithm of what is an is not offensive including using differnent stryles of matching.
This page can be used to test the is used to test the isOffensiveUsername function.
For demonstration purposes the large list of offensive words the game uses to check has been replaced with a list of countries. View Atlas Function