]> granicus.if.org Git - nethack/commitdiff
fix "Scorpius egg"
authornethack.rankin <nethack.rankin>
Thu, 30 Jan 2003 11:35:03 +0000 (11:35 +0000)
committernethack.rankin <nethack.rankin>
Thu, 30 Jan 2003 11:35:03 +0000 (11:35 +0000)
     From the newsgroup:  wishing for a "Scorpius egg" succeeds;
fortunately the resulting egg will never hatch.  Turn such eggs into
normal scorpion eggs instead.

src/mon.c

index da600eb430ef1f9e8df010db633e72895384db9a..a2f34dcf7a4f9fbcc426c275cf14f813079289c4 100644 (file)
--- a/src/mon.c
+++ b/src/mon.c
@@ -1,4 +1,4 @@
-/*     SCCS Id: @(#)mon.c      3.4     2002/11/07      */
+/*     SCCS Id: @(#)mon.c      3.4     2003/01/29      */
 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
 /* NetHack may be freely redistributed.  See license for details. */
 
@@ -2514,6 +2514,11 @@ int
 can_be_hatched(mnum)
 int mnum;
 {
+    /* ranger quest nemesis has the oviparous bit set, making it
+       be possible to wish for eggs of that unique monster; turn
+       such into ordinary eggs rather than forbidding them outright */
+    if (mnum == PM_SCORPIUS) mnum = PM_SCORPION;
+
     mnum = little_to_big(mnum);
     /*
      * Queen bees lay killer bee eggs (usually), but killer bees don't