Jump to content
  • 0

[Help] Command \n


drakoo

Question

7 answers to this question

Recommended Posts

  • 0

Easy fix..

 

Just go to clientpackets/Say2.java

 

and add this

 

	if (_text.contains("\n"))
		_text.replace("\n", "");

 

it will replace all \n with space (blank)

Link to comment
Share on other sites

  • 0

you are in wrong place...error about client here and i thyn is in systemmsg.dat

 

He is in the right section, btw, do as Versus told u but replace this with a letter, i think it will works, they will just spam a letter, and they will get chatbanned from the system, i'm i right?

 

This will maybe work...

	if (_text.contains("\n"))
		_text.replace("\n", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");

 

The character will get chatbanned because it is something like he write too much letters to a message, or no?

Link to comment
Share on other sites

  • 0

Versus the problem continues.

 

View Code:

 

	// player chat banned?
	if (activeChar.isChatBanned())
	{
		activeChar.checkBanChat(true);
		return;
	}


	+     // Block \n
	+      if (_text.contains("\n"))
	+	_text.replace("\n", "N");


	// player jailed?
	if (activeChar.isInJail() && Config.JAIL_DISABLE_CHAT)
	{
		if (_type == TELL || _type == SHOUT || _type == TRADE || _type == HERO_VOICE)
		{
			activeChar.sendMessage("You Have been Chat Banned");
			return;
		}
	}

Link to comment
Share on other sites

  • 0

What happens if you type in game \n? After you compiled your project with the code i gave you.

 

Btw to fix all your problems.. simply do that

 

	if (_text.contains("\n"))
		return;

 

Now when the player writes \n and hits enter nothing will happen, he won't write anything at the chat :)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...