From: PatR Date: Mon, 29 Feb 2016 01:42:12 +0000 (-0800) Subject: monk vs shuriken X-Git-Tag: NetHack-3.6.1_RC01~895 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=be084392d5d5c375d603b604efc9759b189ceaf7;p=nethack monk vs shuriken One entry among many in #H4216: make shuriken be a pre-discovered item for monk role. The word "shuriken" comes from Japanese and martial-arts monk is primarily Chinese, but shuriken/throwing-star is a martial-arts type of weapon and monks get a multi-shot bonus for it (even though they can't advance its skill beyond basic...). --- diff --git a/doc/fixes36.1 b/doc/fixes36.1 index dc0c8e9af..a45bffae8 100644 --- a/doc/fixes36.1 +++ b/doc/fixes36.1 @@ -218,7 +218,8 @@ allow knife and stiletto as possible tin opening tools wizard mode #wizintrinsic command additional tribute passages for The Colour of Magic, The Light Fantastic, Equal Rites, Mort, Sourcery, Wyrd Sisters, Pyramids, Guards! Guards!, - Eric, Moving Pictures, Reaper Man, Snuff, and Raising Steam + Eric, Moving Pictures, Reaper Man, Witches Abroad, Snuff, and + Raising Steam compile-time options SIMPLE_MAIL and SERVER_ADMIN_MSG for public server use database entries for Cleaver, Sunsword, Frost and Fire brands, and polymorph trap @@ -230,6 +231,7 @@ add extended command #kick when choosing an inventory item and '-' for bare-hands/fingers/no-ammo is a choice, include that in the inventory menu if player types '?' or '*' feedback from probing of long worm now includes number of segments it has +monk starts with 'shuriken' pre-discovered (despite language issue...) Platform- and/or Interface-Specific New Features diff --git a/src/u_init.c b/src/u_init.c index 50e90d9d7..34e3b4cc1 100644 --- a/src/u_init.c +++ b/src/u_init.c @@ -701,31 +701,25 @@ u_init() ini_inv(Knight); knows_class(WEAPON_CLASS); knows_class(ARMOR_CLASS); - /* give knights chess-like mobility - * -- idea from wooledge@skybridge.scl.cwru.edu */ + /* give knights chess-like mobility--idea from wooledge@..cwru.edu */ HJumping |= FROMOUTSIDE; skill_init(Skill_K); break; - case PM_MONK: - switch (rn2(90) / 30) { - case 0: - Monk[M_BOOK].trotyp = SPE_HEALING; - break; - case 1: - Monk[M_BOOK].trotyp = SPE_PROTECTION; - break; - case 2: - Monk[M_BOOK].trotyp = SPE_SLEEP; - break; - } + case PM_MONK: { + static short M_spell[] = { SPE_HEALING, SPE_PROTECTION, SPE_SLEEP }; + + Monk[M_BOOK].trotyp = M_spell[rn2(90) / 30]; /* [0..2] */ ini_inv(Monk); if (!rn2(5)) ini_inv(Magicmarker); else if (!rn2(10)) ini_inv(Lamp); knows_class(ARMOR_CLASS); + /* sufficiently martial-arts oriented item to ignore language issue */ + knows_object(SHURIKEN); skill_init(Skill_Mon); break; + } case PM_PRIEST: ini_inv(Priest); if (!rn2(10))