]> granicus.if.org Git - nethack/commitdiff
Reduce the amount of gold laying on the floor
authorPasi Kallinen <paxed@alt.org>
Wed, 1 Nov 2017 10:12:17 +0000 (12:12 +0200)
committerPasi Kallinen <paxed@alt.org>
Wed, 1 Nov 2017 13:23:05 +0000 (15:23 +0200)
There's far too much gold just laying around on the floor.
Didn't previous adventurers grab most of it?

This should incentivize gold detection and digging out vaults,
selling stuff to the shopkeeps, and making it harder to donate
for protection.

Most radical reduction on the first few levels, for dlevel 1,
average amount of gold was 80, is now 10, for dlevel 2, 95->15

Does not change the amount of gold deposited by mineralize,
in the vaults, or contained in chests and large boxes.

doc/fixes36.1
src/mkobj.c

index c56c2ffcc6f0833f4f7dd1bc221877a6f2d5853f..b5fc5822140ba1ef8b4260bd7a3749cc3c8b51e6 100644 (file)
@@ -469,6 +469,7 @@ assigning a type name to a potion on the floor which is actually a mimic could
 with perm_invent option enabled and no inventory, 'i' put up an empty menu
 charisma affects the leeway in demon lord bribes
 make Vlad slightly tougher
+reduce the amount of gold laying on the floor
 
 
 Fixes to Post-3.6.0 Problems that Were Exposed Via git Repository
index 43d62b6c23ae8aea48e8067f40a036cc6436c276..592633cac1dd6c6ecfc9fabecf1755d8be8f018d 100644 (file)
@@ -1418,8 +1418,10 @@ int x, y;
 {
     register struct obj *gold = g_at(x, y);
 
-    if (amount <= 0L)
-        amount = (long) (1 + rnd(level_difficulty() + 2) * rnd(30));
+    if (amount <= 0L) {
+        long mul = rnd(30 / max(12-depth(&u.uz), 2));
+        amount = (long) (1 + rnd(level_difficulty() + 2) * mul);
+    }
     if (gold) {
         gold->quan += amount;
     } else {