aboutsummaryrefslogtreecommitdiff
path: root/internal/game/cmd_craft.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_craft.go
parentfee376102192dc6f24297a7b11324636ace3a07d (diff)
downloadthehouseoficarus-5f37dc9b6f6b79da04da70ae0c33ec8d02998587.tar.gz
feat: qol improvements to items crud in admin gui
Diffstat (limited to 'internal/game/cmd_craft.go')
-rw-r--r--internal/game/cmd_craft.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/internal/game/cmd_craft.go b/internal/game/cmd_craft.go
index 0fe3d5b..3d23f85 100644
--- a/internal/game/cmd_craft.go
+++ b/internal/game/cmd_craft.go
@@ -171,7 +171,7 @@ func (g *Game) startItem(sess *net.Session, p *player.Player, def *item.ItemDef,
}
func (g *Game) hasGrimyHerbs(p *player.Player) bool {
- items := g.CraftIndex.ByType("clean")
+ items := g.CraftIndex.BySubtype("clean")
for _, def := range items {
if def.FindCraft(func(c item.CraftDef) bool {
return craftHasAllItems(&c, p.HasItem)
@@ -188,10 +188,10 @@ func (g *Game) findCraftItems(p *player.Player, itemAID, itemBID string) []*item
toolTypeA := ""
toolTypeB := ""
if defA, _ := g.ItemStore.Load(itemAID); defA != nil {
- toolTypeA = defA.ToolType
+ toolTypeA = defA.ToolType()
}
if defB, _ := g.ItemStore.Load(itemBID); defB != nil {
- toolTypeB = defB.ToolType
+ toolTypeB = defB.ToolType()
}
var matched []*item.ItemDef