summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--crawl-ref/source/effects.cc10
-rw-r--r--crawl-ref/source/item_use.cc3
-rw-r--r--crawl-ref/source/itemprop.cc10
-rw-r--r--crawl-ref/source/itemprop.h2
-rw-r--r--crawl-ref/source/randart.cc9
5 files changed, 14 insertions, 20 deletions
diff --git a/crawl-ref/source/effects.cc b/crawl-ref/source/effects.cc
index 1503094343..93a9b50410 100644
--- a/crawl-ref/source/effects.cc
+++ b/crawl-ref/source/effects.cc
@@ -1496,11 +1496,11 @@ bool acquirement(object_class_type class_wanted, int agent,
continue;
}
- // Only TSO gifts blessed weapons, and currently
- // not through acquirement, but make sure of this anyway
+ // Only TSO gifts blessed blades, and currently not through
+ // acquirement, but make sure of this anyway
if (agent != GOD_SHINING_ONE)
{
- if (is_blessed(doodad))
+ if (is_blessed_blade(doodad))
{
destroy_item(thing_created, true);
thing_created = NON_ITEM;
@@ -1508,8 +1508,8 @@ bool acquirement(object_class_type class_wanted, int agent,
}
}
- // Trog does not gift the Wrath of Trog, nor
- // weapons of pain (work together with Necromantic magic)
+ // Trog does not gift the Wrath of Trog, nor weapons of pain
+ // (which work together with Necromantic magic)
if (agent == GOD_TROG)
{
int brand = get_weapon_brand(doodad);
diff --git a/crawl-ref/source/item_use.cc b/crawl-ref/source/item_use.cc
index 71bc3207cf..2e36f37bd9 100644
--- a/crawl-ref/source/item_use.cc
+++ b/crawl-ref/source/item_use.cc
@@ -171,8 +171,7 @@ bool can_wield(const item_def *weapon, bool say_reason,
if ((you.is_undead || you.species == SP_DEMONSPAWN)
&& (!is_fixed_artefact( *weapon )
&& (weap_brand == SPWPN_HOLY_WRATH
- || (weapon->base_type == OBJ_WEAPONS
- && is_blessed(*weapon)))))
+ || is_blessed_blade(*weapon))))
{
SAY(mpr("This weapon will not allow you to wield it."));
return false;
diff --git a/crawl-ref/source/itemprop.cc b/crawl-ref/source/itemprop.cc
index 8ef02ed116..adf95714fe 100644
--- a/crawl-ref/source/itemprop.cc
+++ b/crawl-ref/source/itemprop.cc
@@ -676,7 +676,7 @@ void set_equip_race( item_def &item, unsigned long flags )
|| item.sub_type == WPN_DEMON_BLADE
|| item.sub_type == WPN_DEMON_WHIP
|| item.sub_type == WPN_DEMON_TRIDENT
- || is_blessed(item))
+ || is_blessed_blade(item))
{
return;
}
@@ -1634,7 +1634,7 @@ bool is_demonic( const item_def &item )
return (false);
} // end is_demonic()
-bool is_blessed( const item_def &item )
+bool is_blessed_blade( const item_def &item )
{
if (item.base_type == OBJ_WEAPONS)
{
@@ -1656,7 +1656,7 @@ bool is_blessed( const item_def &item )
}
return (false);
-} // end is_blessed()
+} // end is_blessed_blade()
bool is_convertible( const item_def &item )
{
@@ -1734,7 +1734,7 @@ bool convert2good( item_def &item, bool allow_blessed )
break;
}
- if (is_blessed(item))
+ if (is_blessed_blade(item))
item.flags &= ~ISFLAG_RACIAL_MASK;
return (true);
@@ -1940,7 +1940,7 @@ bool check_weapon_shape( const item_def &item, bool quiet, bool check_id )
if ((!check_id || item_type_known( item ))
&& ((item.base_type == OBJ_WEAPONS
- && is_blessed(item))
+ && is_blessed_blade(item))
|| brand == SPWPN_HOLY_WRATH)
&& (you.is_undead || you.species == SP_DEMONSPAWN))
{
diff --git a/crawl-ref/source/itemprop.h b/crawl-ref/source/itemprop.h
index 0301819c12..4d09609ce1 100644
--- a/crawl-ref/source/itemprop.h
+++ b/crawl-ref/source/itemprop.h
@@ -668,7 +668,7 @@ bool is_double_ended( const item_def &item );
int double_wpn_awkward_speed( const item_def &item );
bool is_demonic( const item_def &item );
-bool is_blessed( const item_def &item );
+bool is_blessed_blade( const item_def &item );
bool is_convertible( const item_def &item );
bool convert2good( item_def &item, bool allow_blessed = true );
diff --git a/crawl-ref/source/randart.cc b/crawl-ref/source/randart.cc
index fda4b23af6..ac7fe811ba 100644
--- a/crawl-ref/source/randart.cc
+++ b/crawl-ref/source/randart.cc
@@ -102,12 +102,6 @@ static bool _god_fits_artefact(const god_type which_god, const item_def &item)
{
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
@@ -1259,7 +1253,8 @@ static std::string _get_artefact_type(const int type)
static bool _pick_db_name( const item_def &item )
{
- if (is_blessed(item))
+ // Blessed blades always get database names.
+ if (is_blessed_blade(item))
return true;
switch (item.base_type)