Rename item-subsystem methods (refactor step 5, items)
getItem→promptPackItem now returns (obj, ok) instead of a nil-signaling pointer; invName→inventoryName; doPot→applyPotionFuse. C breadcrumbs kept. Behavior unchanged; suite green.
This commit is contained in:
@@ -7,8 +7,8 @@ package game
|
||||
func (g *RogueGame) readScroll() {
|
||||
p := &g.Player
|
||||
|
||||
obj := g.getItem("read", KindScroll)
|
||||
if obj == nil {
|
||||
obj, ok := g.promptPackItem("read", KindScroll)
|
||||
if !ok {
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user