]> granicus.if.org Git - nethack/commitdiff
polymorphed two-weaponing
authornethack.rankin <nethack.rankin>
Mon, 24 Jun 2002 09:59:40 +0000 (09:59 +0000)
committernethack.rankin <nethack.rankin>
Mon, 24 Jun 2002 09:59:40 +0000 (09:59 +0000)
     Cease two-weapon combat if you're using it in polymorphed form
and revert to normal form for any of the roles which can't use it.

doc/fixes34.1
src/polyself.c

index 5cba6be94779e6e97f62c883612d827813902058..507d6fcadb4f24933b9d35fa74c7d3b6121be1c2 100644 (file)
@@ -37,7 +37,8 @@ touchstone entry in data.base
 specific message for engraving headstone with wand of digging
 wielded/quivered chained ball should be unwielded when thrown
 polymorphing into a form that cannot twoweapon should immediately disable
-       twoweapon mode
+       twoweapon mode; likewise when reverting from a monster form which
+       can use two weapons to a normal form which can't
 taking partial count of merged objects from a container while your pack
        was full split the object and did not re-merge
 animal_parts are not always appropriate for ravens
index ade9ddf51a7e056a4c617ff9ec203c25a9bec9ae..e080ba518966f0accaeac309a563902d2a276749 100644 (file)
@@ -1,4 +1,4 @@
-/*     SCCS Id: @(#)polyself.c 3.4     2002/03/24      */
+/*     SCCS Id: @(#)polyself.c 3.4     2002/06/23      */
 /*     Copyright (C) 1987, 1988, 1989 by Ken Arromdee */
 /* NetHack may be freely redistributed.  See license for details. */
 
@@ -83,6 +83,10 @@ const char *fmt, *arg;
            }
            done(GENOCIDED);
        }
+
+       if (u.twoweap && !could_twoweap(youmonst.data))
+           untwoweapon();
+
        if (was_blind && !Blind) {      /* reverting from eyeless */
            Blinded = 1L;
            make_blinded(0L, TRUE);     /* remove blindness */