aboutsummaryrefslogtreecommitdiff
path: root/internal/game/cmd_verbs.go
diff options
context:
space:
mode:
authorhistoria <[not public]>2026-07-01 02:21:42 -0400
committerhistoria <[not public]>2026-07-01 02:21:42 -0400
commit5f37dc9b6f6b79da04da70ae0c33ec8d02998587 (patch)
treef7c309e36267a4c456fcf5bca800e614507a80af /internal/game/cmd_verbs.go
parentfee376102192dc6f24297a7b11324636ace3a07d (diff)
downloadthehouseoficarus-5f37dc9b6f6b79da04da70ae0c33ec8d02998587.tar.gz
feat: qol improvements to items crud in admin gui
Diffstat (limited to 'internal/game/cmd_verbs.go')
-rw-r--r--internal/game/cmd_verbs.go9
1 files changed, 7 insertions, 2 deletions
diff --git a/internal/game/cmd_verbs.go b/internal/game/cmd_verbs.go
index 70b2fb2..cad90c5 100644
--- a/internal/game/cmd_verbs.go
+++ b/internal/game/cmd_verbs.go
@@ -90,12 +90,17 @@ func (g *Game) executeVerbs(sess *net.Session, args []string, rawInput string) {
if len(recipes) > 0 {
addUnique(&sectionObjs, &seen, "use "+name)
for _, r := range recipes {
- if info, ok := productionTypes[r.FirstCraft().Type]; ok {
+ c := r.FirstCraft()
+ key := c.Subtype
+ if key == "" {
+ key = c.Type
+ }
+ if info, ok := productionTypes[key]; ok {
if info.ActionType != behavior.TypeCombine && info.ActionType != behavior.TypeFletch && info.ActionType != behavior.TypeMix {
addUnique(&sectionObjs, &seen, string(info.ActionType))
}
}
- for _, c := range r.FirstCraft().Consume {
+ for _, c := range r.FirstCraft().Ingredients {
for _, itemID := range c.Items {
if itemDef, err := g.ItemStore.Load(itemID); err == nil {
addUnique(&sectionObjs, &seen, "use "+itemDef.Name+" on "+name)