containers in shops
Fix a couple of bugs I stumbled across while testing something else. The sell prompt for a container dropped in a shop had phrasing issues. This fixes a couple but there are more. The message composition assumes that contents fall into two categories: those already owned by the shop and those the shopkeeper is offering to buy from the hero. But there is a third: stuff the shopkeeper doesn't care about so won't buy. The count_contents() routine can supply total contents or shop-owned contents. Subtracting one from the other yields combined hero-owned without any way to separate out shk-cares and don't-care.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.6 extern.h $NHDT-Date: 1567213888 2019/08/31 01:11:28 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.728 $ */
|
||||
/* NetHack 3.6 extern.h $NHDT-Date: 1571436000 2019/10/18 22:00:00 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.730 $ */
|
||||
/* Copyright (c) Steve Creps, 1988. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
|
||||
@@ -1047,7 +1047,8 @@ E int FDECL(count_unpaid, (struct obj *));
|
||||
E int FDECL(count_buc, (struct obj *, int, boolean (*)(OBJ_P)));
|
||||
E void FDECL(tally_BUCX, (struct obj *, BOOLEAN_P,
|
||||
int *, int *, int *, int *, int *));
|
||||
E long FDECL(count_contents, (struct obj *, BOOLEAN_P, BOOLEAN_P, BOOLEAN_P));
|
||||
E long FDECL(count_contents, (struct obj *,
|
||||
BOOLEAN_P, BOOLEAN_P, BOOLEAN_P, BOOLEAN_P));
|
||||
E void FDECL(carry_obj_effects, (struct obj *));
|
||||
E const char *FDECL(currency, (long));
|
||||
E void FDECL(silly_thing, (const char *, struct obj *));
|
||||
|
||||
Reference in New Issue
Block a user