aboutsummaryrefslogtreecommitdiff
path: root/data/help
diff options
context:
space:
mode:
authorhistoria <[not public]>2026-06-16 01:59:27 -0400
committerhistoria <[not public]>2026-06-16 01:59:27 -0400
commit43f21aabae8924f35c12c8485e690aeefe0089fb (patch)
treeb5fbadb89df3cf4ffec86503bb8e2d7e52b27454 /data/help
parent4cc1ddcd185509080b4b3e15d1646567edd51c9d (diff)
downloadthehouseoficarus-43f21aabae8924f35c12c8485e690aeefe0089fb.tar.gz
feat: overhauled ansi color, added prompt options
Diffstat (limited to 'data/help')
-rw-r--r--data/help/color.yaml101
-rw-r--r--data/help/prompt.yaml35
2 files changed, 108 insertions, 28 deletions
diff --git a/data/help/color.yaml b/data/help/color.yaml
index e56512a..1d5ba54 100644
--- a/data/help/color.yaml
+++ b/data/help/color.yaml
@@ -1,31 +1,76 @@
name: "color"
category: "Options"
description: |
- Color output mode.
-
- Type: string
- Default: none
- Values: none, ansi, xterm256
-
- Controls the color output format used by the game.
- none - No color output, tags are stripped.
- ansi - Standard 16-color ANSI (works in most telnet clients + web client).
- xterm256 - 256-color xterm codes (works in PuTTY, iTerm, Kitty, etc.,
- but not in the web client).
-
- You can embed color tags in your prompt string, character description,
- and other free-text fields: <red>text</red> <bold>text</bold>
- Tags are stripped if color mode is "none".
-
- Available foreground colors:
- black, red, green, yellow, blue, magenta, cyan, white,
- bright_black, bright_red, bright_green, bright_yellow,
- bright_blue, bright_magenta, bright_cyan, bright_white
-
- Available styles:
- bold, dim, italic, underline
-
- Examples:
- option color ansi
- option prompt <green>Ready> </green>
- description <red>A tall warrior</red> with <bright_yellow>golden hair</bright_yellow>.
+ Color output customization.
+
+ The "color" command lets you customize the color of various game
+ elements on an account-wide basis. Colors are shared by all
+ characters on the same account.
+
+ Usage:
+ color List all targets and their current values
+ color <target> Show current color for a target
+ color <target> <string> Set a custom color
+ color <target> reset Reset to server default
+ color <target> off Disable color for this target entirely
+
+ Color string format (space-separated tokens):
+ fg=<color> Foreground color
+ bg=<color> Background color
+ bold Bold text
+ dim Dim text
+ italic Italic text
+ underline Underlined text
+
+ Example: fg=green bg=black bold
+
+ Available color names:
+ black, red, green, yellow, blue, magenta, cyan, white,
+ bright_black, bright_red, bright_green, bright_yellow,
+ bright_blue, bright_magenta, bright_cyan, bright_white
+
+ Color targets:
+ room_name Room name headers
+ room_number Room number display (#id)
+ room_desc Room description text
+ direction Movement direction text ("You walk north")
+ exit_direction Exit direction labels (north, south, etc.)
+ exit_name Exit destination room names
+ mob_name Mob names in combat
+ friendly_npc Friendly NPC names (cannot be attacked)
+ hostile_npc Hostile NPC/mob names in room listings
+ damage Damage numbers
+ enemy_hp Enemy HP in combat messages
+ character_hp Your HP in combat messages
+ xp XP gain messages
+ level_up Level-up announcements
+ item Item names on pickup/drop/gather
+ player_name Player names in broadcasts
+ death Death message
+ victory Combat victory message
+ miss Miss messages in combat
+ error Error messages
+
+ Resolution order:
+ 1. Account override (set via "color" command)
+ 2. Server default (set in config.yaml)
+ 3. Built-in fallback
+
+ Auto-colored elements (not configurable):
+ - Object names: colors are set per-object in their YAML definition
+ (fishing spots are blue, rocks are earth-toned, trees are green, etc.)
+ - Item names: colors are set per-item in their YAML definition
+ (ores, logs, fish, tools, etc.)
+ - Mob/player levels: displayed relative to your combat level
+ (red if higher, orange if <5 higher, white if equal,
+ yellow if <5 lower, green if much lower)
+
+ The "color" option (option color none/ansi/xterm256) controls
+ whether ANSI codes are emitted and which mode is used.
+ "none" strips all color; the "color" command settings are
+ still saved but have no visual effect until color mode is
+ enabled.
+
+ You can use color blocks in your prompt using the same format:
+ option prompt {fg=green bold}Ready>{/} %h/%Hhp
+ See 'help prompt' for full prompt customization.
diff --git a/data/help/prompt.yaml b/data/help/prompt.yaml
new file mode 100644
index 0000000..95d852b
--- /dev/null
+++ b/data/help/prompt.yaml
@@ -0,0 +1,35 @@
+name: "prompt"
+category: "Options"
+description: |
+ Customize your command prompt.
+
+ Set via: option prompt <string>
+
+ Your prompt string can include variables and color blocks.
+
+ Variables:
+ %h Current HP
+ %H Maximum HP
+ %c Credits
+ %m Current mob HP (blank unless in combat)
+ %M Mob max HP (blank unless in combat)
+ %s Attack style shorthand (acc, agg, def, bal)
+ %S Attack style longform (accurate, aggressive, defensive, balanced)
+ %i Free inventory slots
+ %x_<skill> XP to next level for a skill (e.g. %x_mining)
+ %X_<skill> Total XP for a skill (e.g. %X_attack)
+
+ Use %% for a literal % sign.
+
+ Color blocks use the same format as the color command:
+ {fg=green bold}text{/}
+
+ A color block starts with {color_string} and ends with {/}.
+
+ Examples:
+ option prompt "> "
+ option prompt "{fg=cyan}%h/%Hhp $%c %s{/} >"
+ option prompt "<{fg=green}%h{/}/{fg=red}%H{/}hp> "
+
+ To reset to the default "> ":
+ option prompt "> "