aboutsummaryrefslogtreecommitdiff
path: root/internal/validate/checks.go
diff options
context:
space:
mode:
authorhistoria <[not public]>2026-07-09 19:29:17 -0400
committerhistoria <[not public]>2026-07-09 19:29:17 -0400
commitb3d4c616f59ad2519f3a0b77e3b47d6571cd2486 (patch)
tree6f1f6a314e0550da68264a79381fc269db803312 /internal/validate/checks.go
parent18c7af94b30c2767b6633d050324c1db34074ce2 (diff)
downloadthehouseoficarus-b3d4c616f59ad2519f3a0b77e3b47d6571cd2486.tar.gz
feat: message actions are now sequences of messages with settable delays
Diffstat (limited to 'internal/validate/checks.go')
-rw-r--r--internal/validate/checks.go11
1 files changed, 11 insertions, 0 deletions
diff --git a/internal/validate/checks.go b/internal/validate/checks.go
index 47bbd1a..2e70323 100644
--- a/internal/validate/checks.go
+++ b/internal/validate/checks.go
@@ -1244,6 +1244,17 @@ func validateStepAction(prefix string, step *behavior.StepAction, itemIDs map[st
return issues
}
+ for i, msg := range step.Messages {
+ if msg.Delay < 0 {
+ issues = append(issues, Issue{
+ Level: "WARN",
+ Type: "semantic",
+ Message: fmt.Sprintf("%s: messages[%d].delay is negative (%d)",
+ prefix, i, msg.Delay),
+ })
+ }
+ }
+
// Validate the embedded NodeAction subset.
if step.GiveItem != "" && !itemIDs[step.GiveItem] {
issues = append(issues, Issue{