aboutsummaryrefslogtreecommitdiff
path: root/internal/game/sys_safespot.go
diff options
context:
space:
mode:
authorhistoria <[not public]>2026-06-29 04:41:40 -0400
committerhistoria <[not public]>2026-06-29 04:41:40 -0400
commit71ce47ca37566be8dc390434df4cd01422298094 (patch)
treec688dc5ff84af8c03a5c825dd6a3926281a8cae3 /internal/game/sys_safespot.go
parent0fe67cfd5def4ac3e919fd611fe5acc55ca2d253 (diff)
downloadthehouseoficarus-71ce47ca37566be8dc390434df4cd01422298094.tar.gz
fix: long fields truncated better in tables
Diffstat (limited to 'internal/game/sys_safespot.go')
-rw-r--r--internal/game/sys_safespot.go12
1 files changed, 2 insertions, 10 deletions
diff --git a/internal/game/sys_safespot.go b/internal/game/sys_safespot.go
index 5544667..cdb954b 100644
--- a/internal/game/sys_safespot.go
+++ b/internal/game/sys_safespot.go
@@ -191,12 +191,7 @@ func (g *Game) degradeSafespot(st *world.ObjState, objDef *object.ObjectDef, cfg
if occSess := g.sessionInRoom(name, roomSessions); occSess != nil {
occSess.WriteLine(color.ExpandTags(g.colorMode(occSess),
fmt.Sprintf("The %s crumbles away!", objDef.Name)))
- if occSess.Player != nil {
- alert := occSess.Player.OptionString("safespot_alert")
- if alert != "" {
- occSess.WriteLine(color.ExpandTags(g.colorMode(occSess), alert))
- }
- }
+ occSess.WriteLine(g.colorize(occSess, "safespot_alert", "Your safespot has been compromised!"))
g.writePrompt(occSess)
}
}
@@ -265,10 +260,7 @@ func (g *Game) forceLeaveSafespot(sess *net.Session, p *player.Player, ss *Safes
if reason != "" {
sess.WriteLine(reason)
- alert := p.OptionString("safespot_alert")
- if alert != "" {
- sess.WriteLine(color.ExpandTags(g.colorMode(sess), alert))
- }
+ sess.WriteLine(g.colorize(sess, "safespot_alert", "Your safespot has been compromised!"))
}
}