mirror of
https://github.com/ShadowNinja/name_restrictions.git
synced 2024-11-16 07:10:37 +01:00
Add a comment on similar name restriction
This commit is contained in:
parent
edecfee654
commit
f44f45d36e
1
init.lua
1
init.lua
|
@ -120,6 +120,7 @@ all_chars = all_chars .. "]"
|
||||||
minetest.register_on_prejoinplayer(function(name, ip)
|
minetest.register_on_prejoinplayer(function(name, ip)
|
||||||
if exemptions[name] then return end
|
if exemptions[name] then return end
|
||||||
|
|
||||||
|
-- Generate a regular expression to match all similar names
|
||||||
local re = name:gsub(all_chars, char_map)
|
local re = name:gsub(all_chars, char_map)
|
||||||
re = "^[_-]*" .. re .. "[_-]*$"
|
re = "^[_-]*" .. re .. "[_-]*$"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user