From 7f8b6d85697774a182b3f40aca21e2286d5c32a3 Mon Sep 17 00:00:00 2001 From: Adam Borowski Date: Tue, 3 Nov 2009 13:11:56 +0100 Subject: Cosmetic desc of gloves: 50% of them will be "gauntlets", 0% "bracers". --- crawl-ref/source/itemprop.cc | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'crawl-ref/source/itemprop.cc') diff --git a/crawl-ref/source/itemprop.cc b/crawl-ref/source/itemprop.cc index eebf239bb2..eed9ac927d 100644 --- a/crawl-ref/source/itemprop.cc +++ b/crawl-ref/source/itemprop.cc @@ -893,6 +893,20 @@ void set_helmet_random_desc( item_def &item ) item.plus2 = random2(THELM_DESC_MAX_SOFT + 1); } +short get_gloves_desc( const item_def &item ) +{ + ASSERT( item.base_type == OBJ_ARMOUR && item.sub_type == ARM_GLOVES ); + + return item.plus2; +} + +void set_gloves_random_desc( item_def &item ) +{ + ASSERT( item.base_type == OBJ_ARMOUR && item.sub_type == ARM_GLOVES ); + + item.plus2 = coinflip() ? TGLOV_DESC_GLOVES : TGLOV_DESC_GAUNTLETS; +} + // // Ego item functions: // -- cgit v1.2.3-54-g00ecf