diff options
| author | historia <[not public]> | 2026-09-18 16:13:49 -0400 |
|---|---|---|
| committer | historia <[not public]> | 2026-09-18 16:13:49 -0400 |
| commit | 194164a77eb4f2479b94c19e6f0e1278ab608781 (patch) | |
| tree | 53413add8ed6f32a34d1733397e380cc98ef70ef /internal/game/act_talk.go | |
| parent | 67e01aab85607b9e601185c7d62dff576af3bb43 (diff) | |
| download | thehouseoficarus-194164a77eb4f2479b94c19e6f0e1278ab608781.tar.gz | |
fix: more casino, economy, gameplay, security, and world data hardening gaps
Diffstat (limited to 'internal/game/act_talk.go')
| -rw-r--r-- | internal/game/act_talk.go | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/internal/game/act_talk.go b/internal/game/act_talk.go index 9ae9959..239e6f5 100644 --- a/internal/game/act_talk.go +++ b/internal/game/act_talk.go @@ -192,7 +192,16 @@ func (g *Game) handleTalkInput(sess *net.Session, input string) { } td, ok := p.Action.Data.(*behavior.TalkData) - if !ok || td.Cfg == nil { + if !ok { + g.cancelAction(p) + sess.SetState(net.StateGame) + g.writePrompt(sess) + return + } + // The estate-directory prompt is a talk action with no dialogue tree + // (Cfg == nil), so it must be allowed through to its own handler below + // instead of being cancelled as a malformed talk node. + if td.Cfg == nil && !td.EstateDirectory { g.cancelAction(p) sess.SetState(net.StateGame) g.writePrompt(sess) |
