diff options
| author | historia <[not public]> | 2026-06-29 04:21:37 -0400 |
|---|---|---|
| committer | historia <[not public]> | 2026-06-29 04:21:37 -0400 |
| commit | 0fe67cfd5def4ac3e919fd611fe5acc55ca2d253 (patch) | |
| tree | fbcdcdeb355bd6c9d3afab006f052a8b465f7feb /internal/game/act_talk.go | |
| parent | 72dbe734015916f98020d6a617981956f0509e26 (diff) | |
| download | thehouseoficarus-0fe67cfd5def4ac3e919fd611fe5acc55ca2d253.tar.gz | |
better dialog color, edge cases on blocked map links fixed
Diffstat (limited to 'internal/game/act_talk.go')
| -rw-r--r-- | internal/game/act_talk.go | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/internal/game/act_talk.go b/internal/game/act_talk.go index c87e3c5..bd5a091 100644 --- a/internal/game/act_talk.go +++ b/internal/game/act_talk.go @@ -106,18 +106,18 @@ func (g *Game) showTalkNode(sess *net.Session, node behavior.TalkNode) { td.SeqIndex = 0 msg := node.Sequence[0] if msg != "" { - sess.WriteLine(color.ExpandTagsDefault(g.colorMode(sess), dialogSpec, msg)) + sess.WriteLine(color.ExpandDialogTags(g.colorMode(sess), dialogSpec, msg)) } td.SeqIndex = 1 if td.SeqIndex < len(node.Sequence) { sess.State = net.StateTalkSequence - sess.Write("[enter to continue]\n") + sess.Write(g.colorize(sess, "dialog_options", "[enter to continue]\n")) return } } else { msg := node.Message.Pick() if msg != "" { - sess.WriteLine(color.ExpandTagsDefault(g.colorMode(sess), dialogSpec, msg)) + sess.WriteLine(color.ExpandDialogTags(g.colorMode(sess), dialogSpec, msg)) } if node.Action != nil { if g.handleNodeAction(sess, node.Action) { @@ -128,7 +128,7 @@ func (g *Game) showTalkNode(sess *net.Session, node behavior.TalkNode) { visible := g.visibleOptions(sess, node.Options) if len(visible) > 0 { for i, opt := range visible { - sess.WriteLine(fmt.Sprintf(" %d. %s", i+1, opt.Text)) + sess.WriteLine(fmt.Sprintf(" %d. %s", i+1, color.ExpandDialogTags(g.colorMode(sess), g.resolveColor(sess, "dialog_options"), opt.Text))) } sess.State = net.StateTalk g.reprompt(sess) @@ -168,7 +168,7 @@ func (g *Game) finishSequence(sess *net.Session, node behavior.TalkNode) { visible := g.visibleOptions(sess, node.Options) if len(visible) > 0 { for i, opt := range visible { - sess.WriteLine(fmt.Sprintf(" %d. %s", i+1, opt.Text)) + sess.WriteLine(fmt.Sprintf(" %d. %s", i+1, color.ExpandDialogTags(g.colorMode(sess), g.resolveColor(sess, "dialog_options"), opt.Text))) } sess.State = net.StateTalk g.reprompt(sess) @@ -304,7 +304,7 @@ func (g *Game) advanceTalk(sess *net.Session, p *player.Player) { if td.SeqIndex < len(node.Sequence) { msg := node.Sequence[td.SeqIndex] if msg != "" { - sess.WriteLine(color.ExpandTagsDefault(g.colorMode(sess), dialogSpec, msg)) + sess.WriteLine(color.ExpandDialogTags(g.colorMode(sess), dialogSpec, msg)) } td.SeqIndex++ } |
