GOLDOBJ zero payment in money2mon

backport of fix to slashem-Bugs-566538 from <Someone>.  money2mon
only makes sense if called with a non-zero amount.
This commit is contained in:
cohrs
2002-06-29 18:04:30 +00:00
parent d70a3772f3
commit 60f057ff8e
2 changed files with 2 additions and 1 deletions
+1
View File
@@ -126,6 +126,7 @@ naming an already wielded elven dagger "Sting" activates warning against orcs
naming either of the wielded weapons unintentionally ends two-weapon combat naming either of the wielded weapons unintentionally ends two-weapon combat
Various nemesis monsters must resist stoning so their death messages make sense Various nemesis monsters must resist stoning so their death messages make sense
don't call DEBUG impossible in rn2 when a level 0 monster tries to cast a spell don't call DEBUG impossible in rn2 when a level 0 monster tries to cast a spell
GOLDOBJ: don't call money2mon with 0 zero when killed by shopkeeper
Platform- and/or Interface-Specific Fixes Platform- and/or Interface-Specific Fixes
+1 -1
View File
@@ -1666,7 +1666,7 @@ boolean croaked;
if (loss > umoney || !loss || roomno == eshkp->shoproom) { if (loss > umoney || !loss || roomno == eshkp->shoproom) {
eshkp->robbed -= umoney; eshkp->robbed -= umoney;
if (eshkp->robbed < 0L) eshkp->robbed = 0L; if (eshkp->robbed < 0L) eshkp->robbed = 0L;
money2mon(shkp, umoney); if (umoney > 0) money2mon(shkp, umoney);
#endif #endif
flags.botl = 1; flags.botl = 1;
pline("%s %s all your possessions.", pline("%s %s all your possessions.",