From 2fde3bce8e4fe796ca4152ed33b3c90d9f5addde Mon Sep 17 00:00:00 2001 From: cohrs Date: Mon, 12 Feb 2007 21:40:16 +0000 Subject: [PATCH] polymorph dropping in-use wielded leash part 2 forgot to handle the twoweapon case, and messed up the test logic (which appeared to work in previous, incomplete testing) --- src/polyself.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/polyself.c b/src/polyself.c index 62d2f950a..7327cd70b 100644 --- a/src/polyself.c +++ b/src/polyself.c @@ -737,11 +737,12 @@ int alone; otmp2 = u.twoweap ? uswapwep : 0; uwepgone(); if ((!wep->cursed || wep->otyp != LOADSTONE) && - (wep->otyp != LEASH && wep->leashmon != 0)) + (wep->otyp != LEASH || wep->leashmon == 0)) dropx(otmp); if (otmp2 != 0) { uswapwepgone(); - if (!otmp2->cursed || otmp2->otyp != LOADSTONE) + if ((!otmp2->cursed || otmp2->otyp != LOADSTONE) && + (otmp2->otyp != LEASH || otmp2->leashmon == 0)) dropx(otmp2); } untwoweapon();