summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/randart.cc
diff options
context:
space:
mode:
authordolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-04-21 05:00:38 +0000
committerdolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-04-21 05:00:38 +0000
commitaa3d47d0610ee14663c7920b166933c27bc453b3 (patch)
tree28b88e5da5505aafd5c3bdf37982e9be0fda7c50 /crawl-ref/source/randart.cc
parent97b6ef8fb2c5e2784cb18ba8a887b94304e189ad (diff)
downloadcrawl-ref-aa3d47d0610ee14663c7920b166933c27bc453b3.tar.gz
crawl-ref-aa3d47d0610ee14663c7920b166933c27bc453b3.zip
Make TSO's blessed blade artefacts only get the holy wrath brand, by
filtering out all other effects. There should be a better way to do this eventually... git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@4437 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/randart.cc')
-rw-r--r--crawl-ref/source/randart.cc27
1 files changed, 5 insertions, 22 deletions
diff --git a/crawl-ref/source/randart.cc b/crawl-ref/source/randart.cc
index 63ceabbeac..4b0d9306fd 100644
--- a/crawl-ref/source/randart.cc
+++ b/crawl-ref/source/randart.cc
@@ -100,28 +100,11 @@ static bool _god_fits_artefact(const god_type which_god, const item_def &item)
return (false);
}
- if (is_blessed(item)) // remove negative effects on blessed weapons
- {
- if (randart_wpn_property( item, RAP_AC ) < 0
- || randart_wpn_property( item, RAP_EVASION ) < 0
- || randart_wpn_property( item, RAP_STRENGTH ) < 0
- || randart_wpn_property( item, RAP_INTELLIGENCE ) < 0
- || randart_wpn_property( item, RAP_DEXTERITY ) < 0
- || randart_wpn_property( item, RAP_FIRE ) < 0
- || randart_wpn_property( item, RAP_COLD ) < 0
- || randart_wpn_property( item, RAP_NOISES )
- || randart_wpn_property( item, RAP_PREVENT_SPELLCASTING )
- || randart_wpn_property( item, RAP_CAUSE_TELEPORTATION )
- || randart_wpn_property( item, RAP_PREVENT_TELEPORTATION )
- || randart_wpn_property( item, RAP_ANGRY )
- || randart_wpn_property( item, RAP_METABOLISM )
- || randart_wpn_property( item, RAP_MUTAGENIC )
- || randart_wpn_property( item, RAP_ACCURACY ) < 0
- || randart_wpn_property( item, RAP_DAMAGE ) < 0)
- {
- return (false);
- }
- }
+ // XXX: There should be a better way to do this!
+ // Remove all other effects on blessed weapons, so that they
+ // only have the holy wrath brand.
+ if (is_blessed(item) && randart_wpn_num_props(item) > 1)
+ return (false);
break;
case GOD_LUGONU: // corruption