From 834433c3ecbe92a4cedd51f0b495838f78de1a16 Mon Sep 17 00:00:00 2001 From: haranp Date: Fri, 30 Nov 2007 14:13:37 +0000 Subject: 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 --- crawl-ref/source/itemname.cc | 5 ++++- crawl-ref/source/items.cc | 7 +++---- 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) { -- cgit v1.2.3-54-g00ecf