aboutsummaryrefslogtreecommitdiff
path: root/internal/game/cmd_option.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/game/cmd_option.go')
-rw-r--r--internal/game/cmd_option.go20
1 files changed, 12 insertions, 8 deletions
diff --git a/internal/game/cmd_option.go b/internal/game/cmd_option.go
index 2d6f3f0..55a04de 100644
--- a/internal/game/cmd_option.go
+++ b/internal/game/cmd_option.go
@@ -16,12 +16,16 @@ func (g *Game) doOption(sess *net.Session, input string) {
mode := g.colorMode(sess)
if input == "" {
+ hLabel := g.resolveConstant(sess, "table_header_label")
+ hValue := g.resolveConstant(sess, "table_header_value")
+ hDetail := g.resolveConstant(sess, "table_header_detail")
+ hDesc := g.resolveConstant(sess, "table_header_desc")
table := &ui.Table{
Columns: []string{
- color.Render(mode, color.Parse("49"), "Option"),
- color.Render(mode, color.Parse("FA"), "Value"),
- color.Render(mode, color.Parse("F5"), "Valid"),
- color.Render(mode, color.Parse("FF"), "Description"),
+ color.Render(mode, hLabel, "Option"),
+ color.Render(mode, hValue, "Value"),
+ color.Render(mode, hDetail, "Valid"),
+ color.Render(mode, hDesc, "Description"),
},
}
for _, def := range player.OptionDefs {
@@ -29,10 +33,10 @@ func (g *Game) doOption(sess *net.Session, input string) {
val = truncateForTable(val, p.OptionBool("unicode"))
valid := formatValidValues(&def)
table.Rows = append(table.Rows, []string{
- color.Render(mode, color.Parse("49"), def.Name),
- color.Render(mode, color.Parse("FA"), val),
- color.Render(mode, color.Parse("F5"), valid),
- color.Render(mode, color.Parse("FF"), def.Description),
+ color.Render(mode, hLabel, def.Name),
+ color.Render(mode, hValue, val),
+ color.Render(mode, hDetail, valid),
+ color.Render(mode, hDesc, def.Description),
})
}
for _, line := range table.Render(p.OptionBool("unicode"), p.OptionInt("wrap_width")) {