Attempting to open down or at yourself is same as #loot
authorPasi Kallinen <paxed@alt.org>
Wed, 14 Mar 2018 18:06:35 +0000 (20:06 +0200)
committerPasi Kallinen <paxed@alt.org>
Wed, 14 Mar 2018 18:15:21 +0000 (20:15 +0200)
Trying to open at the same location as you did nothing,
make it loot instead. Apparently #looting is also annoying
when using vi-keys.

Based on code by aosdict

doc/fixes36.1
src/lock.c

index 4e616831e704fe65a34e59e4cfdf85001b003363..c01208ca73427394844691c513b16417c84e3025 100644 (file)
@@ -526,6 +526,7 @@ fix 'object lost' panic if hero with lycanthropy but in human form is wielding
        were-transformation and drop of wielded weapon
 prevent segfault if pline() is called recursively (which could happen if the
        interface code issues a debugpline() while processing putstr())
+open at yourself is the same as #loot
 
 
 Fixes to Post-3.6.0 Problems that Were Exposed Via git Repository
index 426e8a35f866fa2e2add6bdfedfd34780f47209b..594351124a6733f768ee63a742d8d5e3f0419383 100644 (file)
@@ -630,8 +630,9 @@ int x, y;
     } else if (!get_adjacent_loc((char *) 0, (char *) 0, u.ux, u.uy, &cc))
         return 0;
 
+    /* open at yourself/up/down */
     if ((cc.x == u.ux) && (cc.y == u.uy))
-        return 0;
+        return doloot();
 
     if (stumble_on_door_mimic(cc.x, cc.y))
         return 1;