diff options
author | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2006-12-29 13:34:48 +0000 |
---|---|---|
committer | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2006-12-29 13:34:48 +0000 |
commit | ceb5c7b0604a41acf0708a12b8c9064e482c1055 (patch) | |
tree | 0393aeadfe643a3bbbd368c49ba9627d11f30d8d /crawl-ref/source/items.cc | |
parent | 79a23ebf3d81206085fe0980e5c9cc0bfe9953ba (diff) | |
download | crawl-ref-ceb5c7b0604a41acf0708a12b8c9064e482c1055.tar.gz crawl-ref-ceb5c7b0604a41acf0708a12b8c9064e482c1055.zip |
Refix autopickup so as not to kill greedy-explore.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@731 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/items.cc')
-rw-r--r-- | crawl-ref/source/items.cc | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/crawl-ref/source/items.cc b/crawl-ref/source/items.cc index 180e5d17a2..da54eeaf4f 100644 --- a/crawl-ref/source/items.cc +++ b/crawl-ref/source/items.cc @@ -2967,14 +2967,20 @@ void autopickup() (carrying_capacity(you.burden_state) - you.burden) / item_mass(mitm[o]); + if ( num_can_take < num_to_take ) + { + if (!tried_pickup) + mpr("You can't pick everything up without burdening " + "yourself."); + tried_pickup = true; + num_to_take = num_can_take; + } + if ( num_can_take == 0 ) { o = next; continue; } - - if ( num_can_take < num_to_take ) - num_to_take = num_can_take; } mitm[o].flags &= ~(ISFLAG_THROWN | ISFLAG_DROPPED); |