summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorharanp <haranp@c06c8d41-db1a-0410-9941-cceddc491573>2007-11-30 14:13:37 +0000
committerharanp <haranp@c06c8d41-db1a-0410-9941-cceddc491573>2007-11-30 14:13:37 +0000
commit834433c3ecbe92a4cedd51f0b495838f78de1a16 (patch)
treea823acd31bf4e8dfb9b39dba7743bd03b696026e
parentd943fb6050fa7d57b9c158530000861250cf9458 (diff)
downloadcrawl-ref-834433c3ecbe92a4cedd51f0b495838f78de1a16.tar.gz
crawl-ref-834433c3ecbe92a4cedd51f0b495838f78de1a16.zip
Caps and wizard hats are now embroidered, not shiny [1829930]
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@2950 c06c8d41-db1a-0410-9941-cceddc491573
-rw-r--r--crawl-ref/source/itemname.cc5
-rw-r--r--crawl-ref/source/items.cc7
2 files changed, 7 insertions, 5 deletions
diff --git a/crawl-ref/source/itemname.cc b/crawl-ref/source/itemname.cc
index 0ca583f975..8c3561ffa3 100644
--- a/crawl-ref/source/itemname.cc
+++ b/crawl-ref/source/itemname.cc
@@ -1145,7 +1145,10 @@ std::string item_def::name_aux( description_level_type desc,
if (testbits(ignore_flags, ISFLAG_EMBROIDERED_SHINY))
break;
if (item_typ == ARM_ROBE || item_typ == ARM_CLOAK
- || item_typ == ARM_GLOVES || item_typ == ARM_BOOTS)
+ || item_typ == ARM_GLOVES || item_typ == ARM_BOOTS
+ || (item_typ == ARM_HELMET &&
+ (get_helmet_type( *this ) == THELM_CAP ||
+ get_helmet_type( *this ) == THELM_WIZARD_HAT)))
{
buff << "embroidered ";
}
diff --git a/crawl-ref/source/items.cc b/crawl-ref/source/items.cc
index d3801e4b06..30f69c4acc 100644
--- a/crawl-ref/source/items.cc
+++ b/crawl-ref/source/items.cc
@@ -2962,7 +2962,6 @@ bool can_autopickup()
static void do_autopickup()
{
//David Loewenstern 6/99
- int result, o, next;
int n_did_pickup = 0;
int n_tried_pickup = 0;
@@ -2974,11 +2973,11 @@ static void do_autopickup()
return;
}
- o = igrd[you.x_pos][you.y_pos];
+ int o = igrd[you.x_pos][you.y_pos];
while (o != NON_ITEM)
{
- next = mitm[o].link;
+ const int next = mitm[o].link;
if (item_needs_autopickup(mitm[o]))
{
@@ -3008,7 +3007,7 @@ static void do_autopickup()
const unsigned long iflags(mitm[o].flags);
mitm[o].flags &= ~(ISFLAG_THROWN | ISFLAG_DROPPED);
- result = move_item_to_player(o, num_to_take);
+ const int result = move_item_to_player(o, num_to_take);
if (result == 0 || result == -1)
{