summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/itemprop.cc
diff options
context:
space:
mode:
authordolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-04-16 01:29:47 +0000
committerdolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-04-16 01:29:47 +0000
commit59eb3c3f326a284b63b58b95d9396746d9664bbe (patch)
tree83fa66c5169ace694a3ab6fe42819b2e64cbba17 /crawl-ref/source/itemprop.cc
parent851431b610b7a161ca5bc5ffbddbb76a4a870472 (diff)
downloadcrawl-ref-59eb3c3f326a284b63b58b95d9396746d9664bbe.tar.gz
crawl-ref-59eb3c3f326a284b63b58b95d9396746d9664bbe.zip
Let TSO's weapon blessing for players work on weapons that have the holy
wrath brand, and which can be in a blessed form but aren't. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@4253 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/itemprop.cc')
-rw-r--r--crawl-ref/source/itemprop.cc24
1 files changed, 24 insertions, 0 deletions
diff --git a/crawl-ref/source/itemprop.cc b/crawl-ref/source/itemprop.cc
index 5c531b280f..5fae319d04 100644
--- a/crawl-ref/source/itemprop.cc
+++ b/crawl-ref/source/itemprop.cc
@@ -1648,6 +1648,30 @@ bool is_blessed( const item_def &item )
return (false);
} // end is_blessed()
+bool is_blessable( const item_def &item )
+{
+ if (item.base_type == OBJ_WEAPONS)
+ {
+ switch (item.sub_type)
+ {
+ case WPN_FALCHION:
+ case WPN_LONG_SWORD:
+ case WPN_SCIMITAR:
+ case WPN_KATANA:
+ case WPN_DEMON_BLADE:
+ case WPN_DOUBLE_SWORD:
+ case WPN_GREAT_SWORD:
+ case WPN_TRIPLE_SWORD:
+ return (true);
+
+ default:
+ break;
+ }
+ }
+
+ return (false);
+} // end is_blessable()
+
bool normal2good( item_def &item, bool allow_blessed )
{
if (item.base_type != OBJ_WEAPONS)