theft detection

Shop items stolen or destroyed without being in inventory were handled
inconsistently compared to simply picking up unpaid items because different
criteria got used to decide whether the shk cares about something.  Last
December a hack to deal with this for container contents was introduced but
that left the problem for ordinary items.  This patch attempts to address
it by using a common check for theft and for pickup's add-to-bill.

     It hasn't had nearly enough testing and I won't be very surprised if
one or more new obscure shop bugs have now come into being, but perhaps
they'll at least be consistent bugs as far as shop billing is concerned....
This commit is contained in:
nethack.rankin
2005-03-06 06:58:46 +00:00
parent 3d3088554c
commit 5d25ed46aa
2 changed files with 79 additions and 72 deletions

View File

@@ -67,6 +67,7 @@ various helmet messages changed to distinguish between "helm" and "hat"
helmets don't protect against cockatrice eggs thrown straight up
breaking container contents in a shop didn't always charge for them
some types of shop theft of a stack of items only charged for a single one
some thefts weren't charged at all even though shopkeeper noticed
wizard mode: WIZKIT wish for own quest artifact triggered crash at startup
avoid "your steed is still eating" message when going through a magic portal
cannot drink from fountain, sink or surrounding water while swallowed