diff options
author | dshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573> | 2007-10-29 06:52:14 +0000 |
---|---|---|
committer | dshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573> | 2007-10-29 06:52:14 +0000 |
commit | 2c0a2b2364fbb07b596aba9c0b8e46dc524c27b3 (patch) | |
tree | 28aab9ed116d6dd80dac9611c6094197674970d0 /crawl-ref/source/itemprop.cc | |
parent | 5cc1ceda72618d37faa0113353e356fa78ce908f (diff) | |
download | crawl-ref-2c0a2b2364fbb07b596aba9c0b8e46dc524c27b3.tar.gz crawl-ref-2c0a2b2364fbb07b596aba9c0b8e46dc524c27b3.zip |
[1817715] Fixed autopickup trying to pick up nets you're caught in.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@2651 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/itemprop.cc')
-rw-r--r-- | crawl-ref/source/itemprop.cc | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/crawl-ref/source/itemprop.cc b/crawl-ref/source/itemprop.cc index f9f4857332..7163e965f0 100644 --- a/crawl-ref/source/itemprop.cc +++ b/crawl-ref/source/itemprop.cc @@ -479,17 +479,22 @@ void do_uncurse_item( item_def &item ) // void set_item_stationary( item_def &item ) { - item.plus2 = 1; + if (item.base_type == OBJ_MISSILES && item.sub_type == MI_THROWING_NET) + item.plus2 = 1; } void remove_item_stationary( item_def &item ) { - item.plus2 = 0; + if (item.base_type == OBJ_MISSILES && item.sub_type == MI_THROWING_NET) + item.plus2 = 0; } bool item_is_stationary( const item_def &item ) { - return (item.plus2); + return (you.attribute[ATTR_HELD] + && item.base_type == OBJ_MISSILES + && item.sub_type == MI_THROWING_NET + && item.plus2); } // |