aboutsummaryrefslogtreecommitdiff
path: root/internal/game/cmd_inventory.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/game/cmd_inventory.go')
-rw-r--r--internal/game/cmd_inventory.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/internal/game/cmd_inventory.go b/internal/game/cmd_inventory.go
index b7b52ed..fbde186 100644
--- a/internal/game/cmd_inventory.go
+++ b/internal/game/cmd_inventory.go
@@ -4,6 +4,7 @@ import (
"fmt"
"thehouseoficarus/internal/net"
+ "thehouseoficarus/internal/player"
)
func (g *Game) executeInventory(sess *net.Session, args []string, rawInput string) {
@@ -15,7 +16,7 @@ func (g *Game) doInventory(sess *net.Session) {
sess.WriteLine(fmt.Sprintf("Inventory (%d free):", p.FreeSlots()))
num := 0
- for i := 0; i < 28; i++ {
+ for i := 0; i < player.MaxInventorySlots; i++ {
slot := p.InvSlot(i)
if slot == nil {
continue