From e9a58044e36966a261704a21681e1240f985ea45 Mon Sep 17 00:00:00 2001 From: dolorous Date: Mon, 1 Jun 2009 17:58:23 +0000 Subject: Fix [2794986]: Special damage descriptions weren't being displayed for weapons with multiple damage types. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9876 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/itemprop.h | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) (limited to 'crawl-ref/source/itemprop.h') diff --git a/crawl-ref/source/itemprop.h b/crawl-ref/source/itemprop.h index 5b035371d1..a8ef9e5547 100644 --- a/crawl-ref/source/itemprop.h +++ b/crawl-ref/source/itemprop.h @@ -536,16 +536,17 @@ enum weapon_property_type enum vorpal_damage_type { - // Types of damage a weapon can do... currently assuming that anything - // with BLUDGEON always does "AND" with any other specified types, - // and and sets not including BLUDGEON are "OR". + // These are the types of damage a weapon can do. You can set more + // than one of these. DAM_BASH = 0x0000, // non-melee weapon blugeoning DAM_BLUDGEON = 0x0001, // crushing DAM_SLICE = 0x0002, // slicing/chopping DAM_PIERCE = 0x0004, // stabbing/piercing DAM_WHIP = 0x0008, // whip slashing (no butcher) + DAM_MAX_TYPE = DAM_WHIP, - // These are used for vorpal weapon desc (don't set more than one) + // These are used for vorpal weapon descriptions. You shouldn't set + // more than one of these. DVORP_NONE = 0x0000, // used for non-melee weapons DVORP_CRUSHING = 0x1000, DVORP_SLICING = 0x2000, @@ -716,9 +717,10 @@ bool is_blessed_blade_convertible(const item_def &item); bool convert2good(item_def &item, bool allow_blessed = true); bool convert2bad(item_def &item); -int get_vorpal_type( const item_def &item ); -int get_damage_type( const item_def &item ); -bool does_damage_type( const item_def &item, int dam_type ); +int get_vorpal_type(const item_def &item); +int get_damage_type(const item_def &item); +bool does_damage_type(const item_def &item, int dam_type); +int single_damage_type(const item_def &item); int weapon_str_weight( const item_def &wpn ); int weapon_dex_weight( const item_def &wpn ); -- cgit v1.2.3-54-g00ecf