]> granicus.if.org Git - nethack/commitdiff
hostile djinni from potion
authornethack.rankin <nethack.rankin>
Tue, 29 Jun 2004 02:06:36 +0000 (02:06 +0000)
committernethack.rankin <nethack.rankin>
Tue, 29 Jun 2004 02:06:36 +0000 (02:06 +0000)
     Fix the situation <Someone> reported where the "You disturbed me, fool!"
result when releasing a djinni from a cloudy potion sometimes produced a
peaceful djinni for neutrals due to the usual randomness in how monsters
react to characters of the same alignment.  Explicitly force it to be
hostile for that outcome.

     Also, for the "it's about time" result, suppress the "It vanishes"
message when the character doesn't see the djinni depart.

doc/fixes34.4
src/potion.c

index 16a0a10cf43401e2fa5b9c429e675fd14cf2797a..4163736adabefda0018a8b18f3707fc483124a45 100644 (file)
@@ -41,6 +41,7 @@ if you were Poison_resistant, only a *blessed* potion of sickness caused
        loss of hitpoints
 shopkeeper removal of trap from shop doorway yields an open door instead of
        a closed one if an intact open door is present
+guarantee that hostile djinn released from bottles really are hostile
 
 
 Platform- and/or Interface-Specific Fixes
index e08605f2cc29149d8194106217b7e570f3231b8c..a25f1950111680e44e6e33411017b4a48ca8b6bd 100644 (file)
@@ -1,4 +1,4 @@
-/*     SCCS Id: @(#)potion.c   3.4     2004/06/12      */
+/*     SCCS Id: @(#)potion.c   3.4     2004/06/28      */
 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
 /* NetHack may be freely redistributed.  See license for details. */
 
@@ -2081,10 +2081,12 @@ register struct obj *obj;
                set_malign(mtmp);
                break;
        case 3 : verbalize("It is about time!");
-               pline("%s vanishes.", Monnam(mtmp));
+               if (canspotmon(mtmp)) pline("%s vanishes.", Monnam(mtmp));
                mongone(mtmp);
                break;
        default: verbalize("You disturbed me, fool!");
+               mtmp->mpeaceful = FALSE;
+               set_malign(mtmp);
                break;
        }
 }