shop credit feedback (trunk only)

Fix the first of a couple of minor things I noticed when viewing
that guy's ttyrec about a hidden inventory item which turned out to be
scrolls of scare monster on the used-up items section of his shop bill.

     Be more precise when a shopkeeper gives the hero credit for dropped
gold.  Instead of just displaying
  N zorkmids are added to your credit.
show either
  You have established N zorkmids credit.
when you had no previous credit, or
  N zorkmids added to your credit; total is now X zorkmids.
when adding to existing credit.
This commit is contained in:
nethack.rankin
2011-07-23 03:53:09 +00:00
parent ddabaab385
commit 236c3524d2

View File

@@ -2722,11 +2722,16 @@ xchar x, y;
eshkp->loan = 0L;
Your("debt is paid off.");
}
pline("%ld %s %s added to your credit.",
delta, currency(delta), delta > 1L ? "are" : "is");
if (eshkp->credit == delta)
You("have established %ld %s credit.",
delta, currency(delta));
else
pline("%ld %s added to your credit; total is now %ld %s.",
delta, currency(delta),
eshkp->credit, currency(eshkp->credit));
}
if(offer) goto move_on;
else {
if (!offer) {
if(!isgold) {
if (container)
dropped_container(obj, shkp, FALSE);
@@ -2736,7 +2741,7 @@ xchar x, y;
return;
}
}
move_on:
if((!saleitem && !(container && cltmp > 0L))
|| eshkp->billct == BILLSZ
|| obj->oclass == BALL_CLASS