Jump to content

Colors: Difference between revisions

From fCraft Wiki
 
(5 intermediate revisions by the same user not shown)
Line 5: Line 5:
'''<code><span style="color:#ff4040">Hello</span><span style="color:#00bfbf">!</span></code>'''.
'''<code><span style="color:#ff4040">Hello</span><span style="color:#00bfbf">!</span></code>'''.


To use a percent mark (<code>%</code>) normally, without producing a color code, add a backslash (<code>\</code>) in front of it. For example, typing <code>\%Applejack</code> produces <code>%Applejack</code> in chat, instead of '''<code><span style="color:#40ff40">pplejack</span></code>'''.
To use a percent mark (<code>%</code>) normally, without producing a color code, add a backslash (<code>\</code>) in front of it. For example, typing <code>\%Applejack</code> produces '''<code>%Applejack</code>''' in chat, instead of '''<code><span style="color:#40ff40">pplejack</span></code>'''.


The backslash itself can be escaped! Typing in <code>\\%Derpy</code> produces '''<code>\<span style="color:#ff40ff">erpy</span></code>''' in chat (%D becomes magenta color code).
The backslash itself can be escaped! Typing in <code>\\%Derpy</code> produces '''<code>\<span style="color:#ff40ff">erpy</span></code>''' in chat (%D becomes magenta color code).
Line 34: Line 34:
|<CODE>&Y</CODE>
|<CODE>&Y</CODE>
|{{ColorGreen}}
|{{ColorGreen}}
|Color of messages produced by /Say command.
|Color of messages produced by {{cmd|Say}} command.
|-
|-
|<CODE>&R</CODE>
|<CODE>&R</CODE>
Line 46: Line 46:
|<CODE>&M</CODE>
|<CODE>&M</CODE>
|{{ColorPurple}}
|{{ColorPurple}}
|Color of /Me command messages.
|Color of {{cmd|Me}} command messages.
|-
|-
|<CODE>&W</CODE>
|<CODE>&W</CODE>
Line 68: Line 68:
*[http://www.minecraftwiki.net/wiki/Classic_server_protocol#Color_Codes Color code information] on the Minecraft wiki
*[http://www.minecraftwiki.net/wiki/Classic_server_protocol#Color_Codes Color code information] on the Minecraft wiki
*[[/Colors]] command, that lists color codes.
*[[/Colors]] command, that lists color codes.
*[[Emotes]]
{{ChatStuff}}
*[[Constants]]
*For block colors, see [[Blocks]].
 
{{LastUpdated|1800}}
{{LastUpdated|1800}}
[[Category:Chat Features]]

Latest revision as of 02:56, 31 May 2013

Minecraft can display text in 16 different colors. Two-letter codes are used to set colors in messages. A color code is am ampersand (&) followed by a digit or a letter. Color codes can be used in chat messages, command parameters (e.g. kick reasons or world greetings), /Rules files, announcements.txt, greeting.txt, as well as in mods. Multiple color codes can be used in the same message.

Using colors in chat

Since Minecraft client does not allow typing in ampersands (&) in chat, a percent mark (%) is used instead. Although any player can call /Colors to see this list, only players with UseColorCodes permission can use them. For example, typing in %CHello%3! will produce Hello!.

To use a percent mark (%) normally, without producing a color code, add a backslash (\) in front of it. For example, typing \%Applejack produces %Applejack in chat, instead of pplejack.

The backslash itself can be escaped! Typing in \\%Derpy produces \erpy in chat (%D becomes magenta color code).

Standard Colors

Black (0) Navy (1) Green (2) Teal (3) Maroon (4) Purple (5) Olive (6) Silver (7)


Gray (8) Blue (9) Lime (A) Aqua (B) Red (C) Magenta (D) Yellow (E) White (F)

Symbolic Colors

To simplify customizing chat appearance, fCraft provides several symbolic color codes, which are replaced on the fly with configured colors.

Code Default Description
&S Yellow (E) Color of normal system messages (e.g. command feedback).
&H Lime (A) Color of command usage examples in help.
&Y Green (2) Color of messages produced by /Say command.
&R Green (2) Color of announcements and rules. Default is dark-green. Note that this default color can be overridden by colorcodes in announcement and rule files.
&P Aqua (B) Color of private and rank-wide messages.
&M Purple (5) Color of /Me command messages.
&W Red (C) Color of error and warning messages.
&I Purple (5) Color of IRC messages and event announcements, as seen on the server/in-game.

Newlines

In addition to colors, players with UseColorCodes are able to use the newline keyword %N to force a line break mid-message.

IRC

IRC also supports colors, and fCraft's IRC bot can translate colors between IRC and Minecraft colors on the fly. The following configuration keys control this functionality:

  • IRCUseColor (default: true) controls whether IRC bots should use colors/formatting when writing messages TO IRC.
  • IRCStripMinecraftColors (default: true) controls whether colors and color codes in IRC messages should be sent to the Minecraft server.

See also

Chat Features
Command TipsConstantsColorsEmotesPrivate Messages