Jump to content
  • 0

Restriction of names aCis


l2jkain

Question

Hi, I'm trying to restrict certain names.  It says that the name is incorrect plus it creates the character.

 

Part : CharacterCreate.java
        if (Config.LIST_FORBIDDEN_NAMES.contains(_name.toLowerCase()))
        {
            sendPacket(CharCreateFail.REASON_INCORRECT_NAME);
            return;
        }

Part Config.java

public static List<String> LIST_FORBIDDEN_NAMES = new ArrayList<>();
  
  
		LIST_FORBIDDEN_NAMES = new ArrayList<>();
		for (String listid : server.getProperty("RestrictedNames", "fuck,dildo,admin").split(","))
		{
			LIST_FORBIDDEN_NAMES.add(String.valueOf(listid));
		}
		

 

error
      CztYtkA.png

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

Guest
This topic is now closed to further replies.


×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock