From a19e6b6ab01670a5932308c7bd0e0e5eed8cbcad Mon Sep 17 00:00:00 2001 From: historia <[not public]> Date: Fri, 12 Jun 2026 23:52:06 -0400 Subject: feat: firemaking skill implemented. overhauled how ground items and despawn are handled. --- internal/game/utils.go | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'internal/game/utils.go') diff --git a/internal/game/utils.go b/internal/game/utils.go index c78889d..969eba4 100644 --- a/internal/game/utils.go +++ b/internal/game/utils.go @@ -121,6 +121,19 @@ func actionDesc(p *player.Player) string { return "talking to " + target case "use": return "using a " + target + case "burn": + return "trying to start a fire" + case "stoke": + return "tending to a fire" } return "" } + +func (g *Game) newInvSlot(itemID string, qty int) *player.InventorySlot { + slot := &player.InventorySlot{ItemID: itemID, Quantity: qty} + if def, err := g.ItemStore.Load(itemID); err == nil && def.MaxQuality > 0 { + slot.Quality = def.Quality + slot.MaxQuality = def.MaxQuality + } + return slot +} -- cgit v1.2.3