summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/item_use.cc
diff options
context:
space:
mode:
authordolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-03-22 15:55:27 +0000
committerdolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-03-22 15:55:27 +0000
commit19ed4f8f10de50fe68ef88cc05bfbedfce796790 (patch)
treee328fb81faa01385248736b915bd92200e9d0055 /crawl-ref/source/item_use.cc
parent79ab3930c258a9ca66b834c8196227d595e45815 (diff)
downloadcrawl-ref-19ed4f8f10de50fe68ef88cc05bfbedfce796790.tar.gz
crawl-ref-19ed4f8f10de50fe68ef88cc05bfbedfce796790.zip
Move all armor enchantment messages to enchant_armour().
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@3808 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/item_use.cc')
-rw-r--r--crawl-ref/source/item_use.cc10
1 files changed, 7 insertions, 3 deletions
diff --git a/crawl-ref/source/item_use.cc b/crawl-ref/source/item_use.cc
index a3206ca0a6..31c4582633 100644
--- a/crawl-ref/source/item_use.cc
+++ b/crawl-ref/source/item_use.cc
@@ -3921,7 +3921,10 @@ bool enchant_armour( int &ac_change, bool quiet, item_def &arm )
// cannot be enchanted nor uncursed
if (!is_enchantable_armour(arm, true))
+ {
+ canned_msg( MSG_NOTHING_HAPPENS );
return (false);
+ }
bool is_cursed = item_cursed(arm);
@@ -3960,7 +3963,10 @@ bool enchant_armour( int &ac_change, bool quiet, item_def &arm )
return (true);
}
else
+ {
+ canned_msg( MSG_NOTHING_HAPPENS );
return (false);
+ }
}
// output message before changing enchantment and curse status
@@ -3997,9 +4003,7 @@ static bool handle_enchant_armour( int item_slot )
int ac_change;
bool result = enchant_armour(ac_change, false, arm);
- if (!result)
- canned_msg( MSG_NOTHING_HAPPENS );
- else if (ac_change)
+ if (ac_change)
you.redraw_armour_class = true;
return result;