Chat Color Help

Discussion in 'Plugin Development' started by zachoooo, Mar 11, 2012.

Thread Status:
Not open for further replies.
  1. In my plugin I have a system in which it breaks up messages into an array. This way the words will wrap.

    My chat wrapper would convert that to:

    The only problem is that colors dont persist. Since the messages are split up into an array, the colors dont continue onto the next line. Does anyone have an idea on how to get the color that the old message was in and continue it onto the next line? Thanks in advance!
  2. Anyone know how to do this?
  3. Use the new util.ChatPaginator class. It's the foundation of the new help system and gives you proper word wrap, colors persisting across multiple lines, and a way to display really long messages across multiple screens. CommandSender.sendMessage() has also been overloaded to accept an array of strings so otter output of the ChatPaginator can be sent directly to the player.

    See the implementation of HelpCommand for an example.
  4. What RB were these fixes made in?
  5. The latest 1.2.3-0.2 beta.
  6. Well I guess I have to wait for the new bukkit release to get this fixed then... Thanks for your help.
Thread Status:
Not open for further replies.

Share This Page