1.x/Message Formatting

From Citizens Wiki

< 1.x

Revision as of 12:13, 19 February 2012 by AgentKid (talk | contribs) (moved Message Formatting to 1.x/Message Formatting)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Not Supported!
This page is about Citizens 1.x, while the current version is Citizens 2.0.2. This page's content may be outdated, and shouldn't be trusted as being correct. See this page's talk page for more information. If you were looking for the 2.0.2 equivalent of this page, try Message Formatting. If you feel this message was displayed in error, please contact an administrator.

Citizens has a number of enhanced messaging features - most messages should support these features (if they don't, please tell us).

If you think of any extra features, we'd love to hear them.

General

Messages can be coloured by using both the colour codes and names.

  • <[colour code]> - eg. '<1> Hello.' prints out a dark blue 'Hello.'
  • <colour name> - eg. '<gray> Hello.' - note that the names follow Bukkit's convention, with dark replaced by d ('dred' not 'dark red') and light replaced by l ('lpurple' not 'light purple'). <g> and <y> are special short cuts for green and yellow.

Newlines are represented by < br> (replace leading space). Eg: 'This is a long < br>piece of text.' will come out as: 'This is a long piece of text.'

Messages can be delayed by using the <delay=ticks> tag. Remember, there are ~20 ticks in a second. 'This is <delay=100> a piece of text.' will display 'This is ' first, then ' a piece of text.' five seconds later. You can use multiple <delay> tags in a single message.

Player Messages

When a player is involved (ie. most of the time), the following features are available.

  • <name> - is replaced by the player's name.
  • <world> - is replaced by the name of the player's current world.
  • <h> - is replaced by the player's health.

NPC Messages

When there is an NPC involved in the message or events surrounding the message, the following features are available.

  • <npc> - is replaced by the NPC's name.
  • <npcid> - is replaced by the NPC's ID.