home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 October / usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso / games / volume7 / nethack3 / patch7m / patch7.09
Text File  |  1990-02-26  |  55KB  |  2,070 lines

  1. *** src/Old/u_init.c    Mon Feb 19 19:05:03 1990
  2. --- src/u_init.c    Fri Feb 16 18:59:15 1990
  3. ***************
  4. *** 14,25 ****
  5.   };
  6.   
  7.   static void FDECL(ini_inv, (struct trobj *));
  8.   
  9.   #define    UNDEF_TYP    0
  10.   #define    UNDEF_SPE    '\177'
  11.   #define    UNDEF_BLESS    2
  12.   
  13. ! char *(roles[]) = {    /* must all have distinct first letter */
  14.               /* roles[2] and [6] are changed for females */
  15.               /* in all cases, the corresponding male and female */
  16.               /* roles must start with the same letter */
  17. --- 14,27 ----
  18.   };
  19.   
  20.   static void FDECL(ini_inv, (struct trobj *));
  21. + static void FDECL(knows_class,(CHAR_P));
  22. + static int FDECL(role_index,(CHAR_P));
  23.   
  24.   #define    UNDEF_TYP    0
  25.   #define    UNDEF_SPE    '\177'
  26.   #define    UNDEF_BLESS    2
  27.   
  28. ! const char *(roles[]) = {    /* must all have distinct first letter */
  29.               /* roles[2] and [6] are changed for females */
  30.               /* in all cases, the corresponding male and female */
  31.               /* roles must start with the same letter */
  32. ***************
  33. *** 235,241 ****
  34.   role_index(pc)
  35.   char pc;
  36.   {
  37. !     register char *cp;
  38.   
  39.       if(cp = index(pl_classes, pc))
  40.           return(cp - pl_classes);
  41. --- 237,243 ----
  42.   role_index(pc)
  43.   char pc;
  44.   {
  45. !     register const char *cp;
  46.   
  47.       if(cp = index(pl_classes, pc))
  48.           return(cp - pl_classes);
  49. ***************
  50. *** 247,254 ****
  51.   {
  52.       register int i;
  53.       char pick, pc;
  54. !     Printf("\nNetHack, Copyright 1985, 1986, 1987, 1988, 1989.");
  55.       Printf("\n         By Stichting Mathematisch Centrum and M. Stephenson.");
  56.       Printf("\n         See license for details.\n\n");
  57.   
  58. --- 249,258 ----
  59.   {
  60.       register int i;
  61.       char pick, pc;
  62. ! #ifdef __GNULINT__
  63. !     pick = i = 0;    /* prevent "used before set" warnings */
  64. ! #endif
  65. !     Printf("\nNetHack, Copyright 1985, 1986, 1987, 1988, 1989, 1990.");
  66.       Printf("\n         By Stichting Mathematisch Centrum and M. Stephenson.");
  67.       Printf("\n         See license for details.\n\n");
  68.   
  69. ***************
  70. *** 265,270 ****
  71. --- 269,276 ----
  72.           pl_character[0] = pc = 0;
  73.       }
  74.   
  75. + #ifndef MACOS
  76.       Printf("\nShall I pick a character for you? [Y,N, or Q(quit)] ");
  77.   
  78.       while(!index("yYnNqQ", (pick = readchar())) && !index(quitchars, pick))
  79. ***************
  80. *** 314,319 ****
  81. --- 320,329 ----
  82.       }
  83.       if(pc == '\n')    pc = 0;
  84.   
  85. + #else
  86. +     flags.wantspace = FALSE;
  87. + #endif /* MACOS */
  88.   beginner:
  89.       if(!pc) {
  90.           i = rn2(SIZE(roles));
  91. ***************
  92. *** 337,343 ****
  93.   
  94.       u.ulevel = 0;    /* set up some of the initial attributes */
  95.       u.uhp = u.uhpmax = newhp();
  96. !     adjabil(1);
  97.       u.ulevel = 1;
  98.   
  99.       u.uluck  = u.moreluck = 0;
  100. --- 347,353 ----
  101.   
  102.       u.ulevel = 0;    /* set up some of the initial attributes */
  103.       u.uhp = u.uhpmax = newhp();
  104. !     adjabil(0,1);
  105.       u.ulevel = 1;
  106.   
  107.       u.uluck  = u.moreluck = 0;
  108. ***************
  109. *** 469,479 ****
  110.       case 'S':
  111.           ini_inv(Samurai);
  112.           if(!rn2(5)) ini_inv(Blindfold);
  113. -         objects[SHORT_SWORD].oc_name = "wakizashi";
  114. -         objects[BROADSWORD].oc_name = "ninja-to";
  115. -         objects[GLAIVE].oc_name = "naginata";
  116. -         /* objects[BOW].oc_name = "yumi"; */
  117. -         objects[LOCK_PICK].oc_name = "osaku";
  118.           knows_class(WEAPON_SYM);
  119.           break;
  120.       case 'P':
  121. --- 479,484 ----
  122. *** src/Old/uhitm.c    Mon Feb 19 19:05:35 1990
  123. --- src/uhitm.c    Sun Feb  4 09:46:50 1990
  124. ***************
  125. *** 1,4 ****
  126. ! /*    SCCS Id: @(#)uhitm.c    3.0    89/11/19
  127.   /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
  128.   /* NetHack may be freely redistributed.  See license for details. */
  129.   
  130. --- 1,4 ----
  131. ! /*    SCCS Id: @(#)uhitm.c    3.0    89/11/27
  132.   /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
  133.   /* NetHack may be freely redistributed.  See license for details. */
  134.   
  135. ***************
  136. *** 11,16 ****
  137. --- 11,17 ----
  138.   #ifdef POLYSELF
  139.   static boolean hmonas();
  140.   #endif
  141. + static void nohandglow();
  142.   
  143.   #ifdef WORM
  144.   extern boolean notonhead;
  145. ***************
  146. *** 77,85 ****
  147. --- 78,93 ----
  148.           && !Hallucination && (!mtmp->mhide || !mtmp->mundetected)
  149.           && (!mtmp->mimic || Protection_from_shape_changers)) {
  150.           if (Blind ? Telepat : (!mtmp->minvis || See_invisible)) {
  151. + #ifdef MACOS
  152. +             char mac_tbuf[80];
  153. +             if(!flags.silent) SysBeep(1);
  154. +             sprintf(mac_tbuf, "Really attack %s?", mon_nam(mtmp));
  155. +             if(UseMacAlertText(128, mac_tbuf) != 1) {
  156. + #else
  157.               pline("Really attack %s? ", mon_nam(mtmp));
  158.               (void) fflush(stdout);
  159.               if (yn() != 'y') {
  160. + #endif
  161.                   flags.move = 0;
  162.                   return(TRUE);
  163.               }
  164. ***************
  165. *** 126,132 ****
  166.   #endif
  167.   /*    it is unchivalrous to attack the defenseless or from behind */
  168.       if (pl_character[0] == 'K' && u.ualigntyp == U_LAWFUL &&
  169. !         (mtmp->mfroz || mtmp->msleep || mtmp->mflee) &&
  170.           u.ualign > -10) adjalign(-1);
  171.   
  172.   /*    Adjust vs. (and possibly modify) monster state.        */
  173. --- 134,140 ----
  174.   #endif
  175.   /*    it is unchivalrous to attack the defenseless or from behind */
  176.       if (pl_character[0] == 'K' && u.ualigntyp == U_LAWFUL &&
  177. !         (!mtmp->mcanmove || mtmp->msleep || mtmp->mflee) &&
  178.           u.ualign > -10) adjalign(-1);
  179.   
  180.   /*    Adjust vs. (and possibly modify) monster state.        */
  181. ***************
  182. *** 138,146 ****
  183.           mtmp->msleep = 0;
  184.           tmp += 2;
  185.       }
  186. !     if(mtmp->mfroz) {
  187.           tmp += 4;
  188. !         if(!rn2(10)) mtmp->mfroz = 0;
  189.       }
  190.       if (is_orc(mtmp->data) && pl_character[0]=='E') tmp++;
  191.   
  192. --- 146,157 ----
  193.           mtmp->msleep = 0;
  194.           tmp += 2;
  195.       }
  196. !     if(!mtmp->mcanmove) {
  197.           tmp += 4;
  198. !         if(!rn2(10)) {
  199. !             mtmp->mcanmove = 1;
  200. !             mtmp->mfrozen = 0;
  201. !         }
  202.       }
  203.       if (is_orc(mtmp->data) && pl_character[0]=='E') tmp++;
  204.   
  205. ***************
  206. *** 184,190 ****
  207.       /* andrew@orca: prevent unlimited pick-axe attacks */
  208.       u_wipe_engr(3);
  209.   
  210. !     if(mdat->mlet == S_LEPRECHAUN && !mtmp->mfroz && !mtmp->msleep &&
  211.          !mtmp->mconf && mtmp->mcansee && !rn2(7) &&
  212.          (m_move(mtmp, 0) == 2 ||                /* he died */
  213.          mtmp->mx != u.ux+u.dx || mtmp->my != u.uy+u.dy)) /* he moved */
  214. --- 195,201 ----
  215.       /* andrew@orca: prevent unlimited pick-axe attacks */
  216.       u_wipe_engr(3);
  217.   
  218. !     if(mdat->mlet == S_LEPRECHAUN && mtmp->mfrozen && !mtmp->msleep &&
  219.          !mtmp->mconf && mtmp->mcansee && !rn2(7) &&
  220.          (m_move(mtmp, 0) == 2 ||                /* he died */
  221.          mtmp->mx != u.ux+u.dx || mtmp->my != u.uy+u.dy)) /* he moved */
  222. ***************
  223. *** 196,203 ****
  224.        * cinating.
  225.        */
  226.       /*  changes by wwp 5/16/85 */
  227. !     if (!Blind && !Confusion && !Hallucination && flags.safe_dog &&
  228. !         (mdat->mlet == S_DOG || mdat->mlet == S_FELINE) && mtmp->mtame) {
  229.           mtmp->mflee = 1;
  230.           mtmp->mfleetim = rnd(6);
  231.           if (mtmp->mnamelth)
  232. --- 207,215 ----
  233.        * cinating.
  234.        */
  235.       /*  changes by wwp 5/16/85 */
  236. !     if (!Confusion && !Hallucination && flags.safe_dog &&
  237. !         (Blind ? Telepat : (!mtmp->minvis || See_invisible)) &&
  238. !                                 mtmp->mtame) {
  239.           mtmp->mflee = 1;
  240.           mtmp->mfleetim = rnd(6);
  241.           if (mtmp->mnamelth)
  242. ***************
  243. *** 245,251 ****
  244.       if(!mhit) {
  245.           if(!Blind && flags.verbose) You("miss %s.", mon_nam(mon));
  246.           else            You("miss it.");
  247. !         if(!mon->msleep && !mon->mfroz)
  248.           wakeup(mon);
  249.       } else {
  250.           /* we hit the monster; be careful: it might die! */
  251. --- 257,263 ----
  252.       if(!mhit) {
  253.           if(!Blind && flags.verbose) You("miss %s.", mon_nam(mon));
  254.           else            You("miss it.");
  255. !         if(!mon->msleep && mon->mcanmove)
  256.           wakeup(mon);
  257.       } else {
  258.           /* we hit the monster; be careful: it might die! */
  259. ***************
  260. *** 299,304 ****
  261. --- 311,317 ----
  262.   register int thrown;
  263.   {
  264.       register int tmp;
  265. +     struct permonst *mdat = mon->data;
  266.       /* Why all these booleans?  This stuff has to be done in the
  267.        *      following order:
  268.        * 1) Know what we're attacking with, and print special hittxt for
  269. ***************
  270. *** 313,319 ****
  271. --- 326,334 ----
  272.        *    kill poison
  273.        * 5) Print hit message (depends on 1 and 4)
  274.        * 6a) Print poison message (must be done after 5)
  275. + #if 0
  276.        * 6b) Rust weapon (must be done after 5)
  277. + #endif
  278.        * 7) Possibly kill monster (must be done after 6a, 6b)
  279.        * 8) Instant-kill from poison (can happen anywhere between 5 and 9)
  280.        * 9) Hands not glowing (must be done after 7 and 8)
  281. ***************
  282. *** 330,336 ****
  283.       wakeup(mon);
  284.       if(!obj) {
  285.           tmp = rnd(2);    /* attack with bare hands */
  286. !         if(mon->data == &mons[PM_COCKATRICE] && !uarmg
  287.   #ifdef POLYSELF
  288.           && !resists_ston(uasmon)
  289.   #endif
  290. --- 345,352 ----
  291.       wakeup(mon);
  292.       if(!obj) {
  293.           tmp = rnd(2);    /* attack with bare hands */
  294. ! #if 0
  295. !         if(mdat == &mons[PM_COCKATRICE] && !uarmg
  296.   #ifdef POLYSELF
  297.           && !resists_ston(uasmon)
  298.   #endif
  299. ***************
  300. *** 342,359 ****
  301.           done_in_by(mon);
  302.           hittxt = TRUE; /* maybe lifesaved */
  303.           }
  304.       } else {
  305.           if(obj->olet == WEAPON_SYM || obj->otyp == PICK_AXE ||
  306.              obj->otyp == UNICORN_HORN || obj->olet == ROCK_SYM) {
  307.   
  308. !         if(obj == uwep && (obj->otyp > VOULGE || obj->otyp < BOOMERANG)
  309.               && obj->otyp != PICK_AXE && obj->otyp != UNICORN_HORN)
  310.               tmp = rnd(2);
  311.           else {
  312. !             tmp = dmgval(obj, mon->data);
  313.   #ifdef NAMED_ITEMS
  314. !             if(spec_ability(obj, SPFX_DRLI) &&
  315. !                         !resists_drli(mon->data)) {
  316.               if (!Blind) {
  317.                   pline("The %s blade draws the life from %s!",
  318.                   Hallucination ? hcolor() : black,
  319. --- 358,375 ----
  320.           done_in_by(mon);
  321.           hittxt = TRUE; /* maybe lifesaved */
  322.           }
  323. + #endif
  324.       } else {
  325.           if(obj->olet == WEAPON_SYM || obj->otyp == PICK_AXE ||
  326.              obj->otyp == UNICORN_HORN || obj->olet == ROCK_SYM) {
  327.   
  328. !         if(obj == uwep && (obj->otyp >= BOW || obj->otyp < BOOMERANG)
  329.               && obj->otyp != PICK_AXE && obj->otyp != UNICORN_HORN)
  330.               tmp = rnd(2);
  331.           else {
  332. !             tmp = dmgval(obj, mdat);
  333.   #ifdef NAMED_ITEMS
  334. !             if(spec_ability(obj, SPFX_DRLI) && !resists_drli(mdat)) {
  335.               if (!Blind) {
  336.                   pline("The %s blade draws the life from %s!",
  337.                   Hallucination ? hcolor() : black,
  338. ***************
  339. *** 385,393 ****
  340.                   ispoisoned = TRUE;
  341.               }
  342.               if(thrown && obj->otyp == SILVER_ARROW) {
  343. !             if (is_were(mon->data) || mon->data->mlet==S_VAMPIRE
  344. !                 || (mon->data->mlet==S_IMP && mon->data != &mons[PM_TENGU])
  345. !                 || is_demon(mon->data)) {
  346.                   silvermsg = TRUE;
  347.                   tmp += rnd(20);
  348.               }
  349. --- 401,409 ----
  350.                   ispoisoned = TRUE;
  351.               }
  352.               if(thrown && obj->otyp == SILVER_ARROW) {
  353. !             if (is_were(mdat) || mdat->mlet==S_VAMPIRE
  354. !                 || (mdat->mlet==S_IMP && mdat != &mons[PM_TENGU])
  355. !                 || is_demon(mdat)) {
  356.                   silvermsg = TRUE;
  357.                   tmp += rnd(20);
  358.               }
  359. ***************
  360. *** 410,416 ****
  361.               You("break your mirror.  That's bad luck!");
  362.               change_luck(-2);
  363.               useup(obj);
  364. !             return(TRUE);
  365.   #endif
  366.           case EXPENSIVE_CAMERA:
  367.       You("succeed in destroying your camera.  Congratulations!");
  368. --- 426,433 ----
  369.               You("break your mirror.  That's bad luck!");
  370.               change_luck(-2);
  371.               useup(obj);
  372. !             hittxt = TRUE;
  373. !             tmp = 1;
  374.   #endif
  375.           case EXPENSIVE_CAMERA:
  376.       You("succeed in destroying your camera.  Congratulations!");
  377. ***************
  378. *** 420,426 ****
  379.               if(obj->corpsenm == PM_COCKATRICE) {
  380.                   kludge("You hit %s with the cockatrice corpse.",
  381.                     mon_nam(mon));
  382. !                 if(resists_ston(mon->data)) {
  383.                   tmp = 1;
  384.                   hittxt = TRUE;
  385.                   break;
  386. --- 437,443 ----
  387.               if(obj->corpsenm == PM_COCKATRICE) {
  388.                   kludge("You hit %s with the cockatrice corpse.",
  389.                     mon_nam(mon));
  390. !                 if(resists_ston(mdat)) {
  391.                   tmp = 1;
  392.                   hittxt = TRUE;
  393.                   break;
  394. ***************
  395. *** 428,433 ****
  396. --- 445,451 ----
  397.                   kludge("%s turns to stone.", Monnam(mon));
  398.                   stoned = TRUE;
  399.                   xkilled(mon,0);
  400. +                 nohandglow();
  401.                   return(FALSE);
  402.               }
  403.               tmp = mons[obj->corpsenm].msize + 1;
  404. ***************
  405. *** 435,441 ****
  406.           case EGG: /* only possible if hand-to-hand */
  407.               if(obj->corpsenm > -1
  408.                       && obj->corpsenm != PM_COCKATRICE
  409. !                     && mon->data==&mons[PM_COCKATRICE]) {
  410.                   kludge("You hit %s with the %s egg%s.",
  411.                       mon_nam(mon),
  412.                       mons[obj->corpsenm].mname,
  413. --- 453,459 ----
  414.           case EGG: /* only possible if hand-to-hand */
  415.               if(obj->corpsenm > -1
  416.                       && obj->corpsenm != PM_COCKATRICE
  417. !                     && mdat == &mons[PM_COCKATRICE]) {
  418.                   kludge("You hit %s with the %s egg%s.",
  419.                       mon_nam(mon),
  420.                       mons[obj->corpsenm].mname,
  421. ***************
  422. *** 451,457 ****
  423.               tmp = 1;
  424.               break;
  425.           case CLOVE_OF_GARLIC:        /* no effect against demons */
  426. !             if(is_undead(mon->data)) mon->mflee = 1;
  427.               tmp = 1;
  428.               break;
  429.           case CREAM_PIE:
  430. --- 469,475 ----
  431.               tmp = 1;
  432.               break;
  433.           case CLOVE_OF_GARLIC:        /* no effect against demons */
  434. !             if(is_undead(mdat)) mon->mflee = 1;
  435.               tmp = 1;
  436.               break;
  437.           case CREAM_PIE:
  438. ***************
  439. *** 468,475 ****
  440.               else
  441.                   pline("The cream pie splashes over %s%s!",
  442.                   mon_nam(mon),
  443. !                 (haseyes(mon->data) &&
  444. !                     mon->data != &mons[PM_FLOATING_EYE])
  445.                   ? "'s face" : "");
  446.               if(mon->msleep) mon->msleep = 0;
  447.               setmangry(mon);
  448. --- 486,493 ----
  449.               else
  450.                   pline("The cream pie splashes over %s%s!",
  451.                   mon_nam(mon),
  452. !                 (haseyes(mdat) &&
  453. !                     mdat != &mons[PM_FLOATING_EYE])
  454.                   ? "'s face" : "");
  455.               if(mon->msleep) mon->msleep = 0;
  456.               setmangry(mon);
  457. ***************
  458. *** 483,495 ****
  459.               break;
  460.   #ifdef POLYSELF
  461.           case ACID_VENOM: /* only possible if thrown */
  462. !             if(resists_acid(mon->data)) {
  463.                   kludge("Your venom hits %s harmlessly.",
  464.                       mon_nam(mon));
  465.                   tmp = 0;
  466.               } else {
  467.                   kludge("Your venom burns %s!", mon_nam(mon));
  468. !                 tmp = dmgval(obj, mon->data);
  469.               }
  470.               hittxt = TRUE;
  471.               get_dmg_bonus = FALSE;
  472. --- 501,513 ----
  473.               break;
  474.   #ifdef POLYSELF
  475.           case ACID_VENOM: /* only possible if thrown */
  476. !             if(resists_acid(mdat)) {
  477.                   kludge("Your venom hits %s harmlessly.",
  478.                       mon_nam(mon));
  479.                   tmp = 0;
  480.               } else {
  481.                   kludge("Your venom burns %s!", mon_nam(mon));
  482. !                 tmp = dmgval(obj, mdat);
  483.               }
  484.               hittxt = TRUE;
  485.               get_dmg_bonus = FALSE;
  486. ***************
  487. *** 513,522 ****
  488.           /* If you throw using a propellor, you don't get a strength
  489.            * bonus but you do get an increase-damage bonus.
  490.            */
  491. !         if(!obj || !uwep ||
  492.               (obj->olet != GEM_SYM && obj->olet != WEAPON_SYM) ||
  493. !             objects[obj->otyp].w_propellor !=
  494. !                 -objects[uwep->otyp].w_propellor)
  495.               tmp += dbon();
  496.       }
  497.   
  498. --- 531,541 ----
  499.           /* If you throw using a propellor, you don't get a strength
  500.            * bonus but you do get an increase-damage bonus.
  501.            */
  502. !         if(!thrown || !obj || !uwep ||
  503.               (obj->olet != GEM_SYM && obj->olet != WEAPON_SYM) ||
  504. !             !objects[obj->otyp].w_propellor ||
  505. !             (objects[obj->otyp].w_propellor !=
  506. !                 -objects[uwep->otyp].w_propellor))
  507.               tmp += dbon();
  508.       }
  509.   
  510. ***************
  511. *** 530,536 ****
  512.       }
  513.    */
  514.       if (ispoisoned) {
  515. !         if(resists_poison(mon->data))
  516.           needpoismsg = TRUE;
  517.           else if (rn2(10))
  518.           tmp += rnd(6);
  519. --- 549,555 ----
  520.       }
  521.    */
  522.       if (ispoisoned) {
  523. !         if(resists_poison(mdat))
  524.           needpoismsg = TRUE;
  525.           else if (rn2(10))
  526.           tmp += rnd(6);
  527. ***************
  528. *** 550,558 ****
  529.           mon->mflee = 1;            /* Rick Richardson */
  530.           mon->mfleetim += 10*rnd(tmp);
  531.       }
  532. !     if((mon->data == &mons[PM_BLACK_PUDDING] ||
  533. !            mon->data == &mons[PM_BROWN_PUDDING]) && obj &&
  534. !            obj == uwep && objects[obj->otyp].oc_material == METAL
  535.              && mon->mhp > 1 && !thrown && !mon->mcan
  536.              /* && !destroyed  -- guaranteed by mhp > 1 */ ) {
  537.   
  538. --- 569,577 ----
  539.           mon->mflee = 1;            /* Rick Richardson */
  540.           mon->mfleetim += 10*rnd(tmp);
  541.       }
  542. !     if((mdat == &mons[PM_BLACK_PUDDING] || mdat == &mons[PM_BROWN_PUDDING])
  543. !            && obj && obj == uwep
  544. !            && objects[obj->otyp].oc_material == METAL
  545.              && mon->mhp > 1 && !thrown && !mon->mcan
  546.              /* && !destroyed  -- guaranteed by mhp > 1 */ ) {
  547.   
  548. ***************
  549. *** 583,611 ****
  550.       if (poiskilled) {
  551.           pline("The poison was deadly...");
  552.           xkilled(mon, 0);
  553.           return FALSE;
  554. !     } else if (destroyed)
  555. !         killed(mon);    /* takes care of messages */
  556. !     else if(u.umconf && !thrown) {
  557. !         if(!Blind) {
  558. !             Your("%s stop glowing %s.",
  559. !             makeplural(body_part(HAND)),
  560. !             Hallucination ? hcolor() : red);
  561. !         }
  562.           if(!resist(mon, '+', 0, NOTELL)) mon->mconf = 1;
  563. !         if(!mon->mstun && !mon->mfroz && !mon->msleep &&
  564.              !Blind && mon->mconf)
  565.               pline("%s appears confused.", Monnam(mon));
  566. -         u.umconf = 0;
  567.       }
  568.   
  569. !     if(mon->data == &mons[PM_RUST_MONSTER] && obj && obj == uwep &&
  570.           objects[obj->otyp].oc_material == METAL &&
  571.           obj->olet == WEAPON_SYM && obj->spe > -2) {
  572.           if(obj->rustfree) {
  573.           pline("The rust on your %s vanishes instantly!",
  574.                 is_sword(obj) ? "sword" : "weapon");
  575. !         } else if(obj->blessed && rnl(4))
  576.           pline("Somehow your %s is not affected!",
  577.                 is_sword(obj) ? "sword" : "weapon");
  578.           else {
  579. --- 602,628 ----
  580.       if (poiskilled) {
  581.           pline("The poison was deadly...");
  582.           xkilled(mon, 0);
  583. +         nohandglow();
  584.           return FALSE;
  585. !     } else if (destroyed) {
  586. !         killed(mon);    /* takes care of most messages */
  587. !         nohandglow();
  588. !     } else if(u.umconf && !thrown) {
  589. !         nohandglow();
  590.           if(!resist(mon, '+', 0, NOTELL)) mon->mconf = 1;
  591. !         if(!mon->mstun && mon->mcanmove && !mon->msleep &&
  592.              !Blind && mon->mconf)
  593.               pline("%s appears confused.", Monnam(mon));
  594.       }
  595.   
  596. ! #if 0
  597. !     if(mdat == &mons[PM_RUST_MONSTER] && obj && obj == uwep &&
  598.           objects[obj->otyp].oc_material == METAL &&
  599.           obj->olet == WEAPON_SYM && obj->spe > -2) {
  600.           if(obj->rustfree) {
  601.           pline("The rust on your %s vanishes instantly!",
  602.                 is_sword(obj) ? "sword" : "weapon");
  603. !         } else if(obj->blessed && !rnl(4))
  604.           pline("Somehow your %s is not affected!",
  605.                 is_sword(obj) ? "sword" : "weapon");
  606.           else {
  607. ***************
  608. *** 613,618 ****
  609. --- 630,636 ----
  610.           obj->spe--;
  611.           }
  612.       }
  613. + #endif
  614.   
  615.       return(destroyed ? FALSE : TRUE);
  616.   }
  617. ***************
  618. *** 636,643 ****
  619.           ) {
  620.           struct monst *dtmp;
  621.           pline("Some hell-p has arrived!");
  622. ! /*        if((dtmp = makemon(uasmon, u.ux, u.uy)))*/
  623. !         if((dtmp = makemon(&mons[ndemon()], u.ux, u.uy)))
  624.           (void)tamedog(dtmp, (struct obj *)0);
  625.           return(0);
  626.       }
  627. --- 654,660 ----
  628.           ) {
  629.           struct monst *dtmp;
  630.           pline("Some hell-p has arrived!");
  631. !         if((dtmp = makemon(!rn2(6) ? &mons[ndemon()] : uasmon, u.ux, u.uy)))
  632.           (void)tamedog(dtmp, (struct obj *)0);
  633.           return(0);
  634.       }
  635. ***************
  636. *** 716,722 ****
  637.               int isize = inv_cnt();
  638.   
  639.               stealoid = (struct obj *)0;
  640. !             if (is_mercenary(pd)) {
  641.               for(otmp = mdef->minvent; otmp; otmp=otmp->nobj)
  642.                   if (otmp->otyp >= PLATE_MAIL && otmp->otyp
  643.                   <= ELVEN_CLOAK) stealoid = otmp;
  644. --- 733,739 ----
  645.               int isize = inv_cnt();
  646.   
  647.               stealoid = (struct obj *)0;
  648. !             if(is_mercenary(pd) && could_seduce(&youmonst,mdef,mattk)){
  649.               for(otmp = mdef->minvent; otmp; otmp=otmp->nobj)
  650.                   if (otmp->otyp >= PLATE_MAIL && otmp->otyp
  651.                   <= ELVEN_CLOAK) stealoid = otmp;
  652. ***************
  653. *** 869,884 ****
  654.               u.ustuck = mdef; /* it's now stuck to you */
  655.           break;
  656.           case AD_PLYS:
  657. !         if (!mdef->mfroz && !rn2(3) && tmp < mdef->mhp) {
  658.               if (!Blind) pline("%s is frozen by you!", Monnam(mdef));
  659. !             mdef->mfroz = 1;
  660.           }
  661.           case AD_SLEE:
  662.           if (!resists_sleep(mdef->data) && !mdef->msleep &&
  663. !                                 !mdef->mfroz) {
  664.               if (!Blind)
  665.               pline("%s suddenly falls asleep!", Monnam(mdef));
  666. !             mdef->msleep = 1;
  667.           }
  668.           break;
  669.           default:    tmp = 0;
  670. --- 886,904 ----
  671.               u.ustuck = mdef; /* it's now stuck to you */
  672.           break;
  673.           case AD_PLYS:
  674. !         if (mdef->mcanmove && !rn2(3) && tmp < mdef->mhp) {
  675.               if (!Blind) pline("%s is frozen by you!", Monnam(mdef));
  676. !             mdef->mcanmove = 0;
  677. !             mdef->mfrozen = rnd(10);
  678.           }
  679. +         break;
  680.           case AD_SLEE:
  681.           if (!resists_sleep(mdef->data) && !mdef->msleep &&
  682. !                             mdef->mcanmove) {
  683.               if (!Blind)
  684.               pline("%s suddenly falls asleep!", Monnam(mdef));
  685. !             mdef->mcanmove = 0;
  686. !             mdef->mfrozen = rnd(10);
  687.           }
  688.           break;
  689.           default:    tmp = 0;
  690. ***************
  691. *** 910,916 ****
  692.           case AD_BLND:
  693.           if(mdef->data->mlet != S_YLIGHT) {
  694.               kludge("%s is blinded by your flash of light!", Monnam(mdef));
  695. !             if (!mdef->mblinded) {
  696.               mdef->mblinded += rn2(25);
  697.               mdef->mcansee = 0;
  698.               }
  699. --- 930,936 ----
  700.           case AD_BLND:
  701.           if(mdef->data->mlet != S_YLIGHT) {
  702.               kludge("%s is blinded by your flash of light!", Monnam(mdef));
  703. !             if (mdef->mcansee) {
  704.               mdef->mblinded += rn2(25);
  705.               mdef->mcansee = 0;
  706.               }
  707. ***************
  708. *** 956,964 ****
  709.        * after exactly 1 round of attack otherwise.  -KAA
  710.        */
  711.   
  712. ! # ifdef WORM
  713. !     if(mdef->wormno) return 0;
  714. ! # endif
  715.       if(u.uhunger < 1500 && !u.uswallow) {
  716.   
  717.           if(mdef->data->mlet != S_COCKATRICE) {
  718. --- 976,983 ----
  719.        * after exactly 1 round of attack otherwise.  -KAA
  720.        */
  721.   
  722. !     if(mdef->data->msize >= MZ_HUGE) return 0;
  723.       if(u.uhunger < 1500 && !u.uswallow) {
  724.   
  725.           if(mdef->data->mlet != S_COCKATRICE) {
  726. ***************
  727. *** 1046,1061 ****
  728.               xkilled(mdef,0);
  729.               return(2);
  730.           }
  731. !         kludge("You regurgitate %s!", mon_nam(mdef));
  732. !         if (Blind)
  733. !             pline("Obviously, you didn't like its taste.");
  734. !         else
  735. !             pline("Obviously, you didn't like %s's taste.",
  736.                                   mon_nam(mdef));
  737.           } else {
  738.           kludge("You bite into %s", mon_nam(mdef));
  739.           You("turn to stone...");
  740. !         killer = "poor choice of food";
  741.           done(STONING);
  742.           }
  743.       }
  744. --- 1065,1084 ----
  745.               xkilled(mdef,0);
  746.               return(2);
  747.           }
  748. !         kludge("You %s %s!", is_animal(uasmon) ? "regurgitate"
  749. !             : "expel", mon_nam(mdef));
  750. !         if (is_animal(uasmon)) {
  751. !             if (Blind)
  752. !             pline("Obviously, you didn't like its taste.");
  753. !             else
  754. !             pline("Obviously, you didn't like %s's taste.",
  755.                                   mon_nam(mdef));
  756. +         }
  757.           } else {
  758.           kludge("You bite into %s", mon_nam(mdef));
  759.           You("turn to stone...");
  760. !         killer_format = KILLED_BY;
  761. !         killer = "swallowing a cockatrice whole";
  762.           done(STONING);
  763.           }
  764.       }
  765. ***************
  766. *** 1134,1141 ****
  767.                   if (!u.uswallow &&
  768.                       (compat = could_seduce(&youmonst,
  769.                                   mon, mattk)))
  770. !                 pline("You %s %s %s.",
  771. !                     mon->mblinded ? "talk to" : "smile at",
  772.                       Blind ? "it" : mon_nam(mon),
  773.                       compat == 2 ? "engagingly" : "seductively");
  774.                   else if (mattk->aatyp == AT_KICK)
  775. --- 1157,1164 ----
  776.                   if (!u.uswallow &&
  777.                       (compat = could_seduce(&youmonst,
  778.                                   mon, mattk)))
  779. !                 You("%s %s %s.",
  780. !                     mon->mcansee ? "smile at" : "talk to",
  781.                       Blind ? "it" : mon_nam(mon),
  782.                       compat == 2 ? "engagingly" : "seductively");
  783.                   else if (mattk->aatyp == AT_KICK)
  784. ***************
  785. *** 1262,1271 ****
  786.           if(mhit && !rn2(6)) {
  787.           if (kicked) {
  788.               if (uarmf)
  789. !             (void) rust_dmg(uarmf, xname(uarmf), 1, TRUE);
  790.           } else corrode_weapon();
  791.           }
  792.           break;
  793.         case AD_MAGM:
  794.           /* wrath of gods for attacking Oracle */
  795.           if(Antimagic) {
  796. --- 1285,1315 ----
  797.           if(mhit && !rn2(6)) {
  798.           if (kicked) {
  799.               if (uarmf)
  800. !             (void) rust_dmg(uarmf, xname(uarmf), 3, TRUE);
  801.           } else corrode_weapon();
  802.           }
  803.           break;
  804. +       case AD_STON:
  805. +         if(mhit)
  806. +           if (!kicked)
  807. +         if (!uwep && !uarmg
  808. + #ifdef POLYSELF
  809. +             && !resists_ston(uasmon)
  810. + #endif
  811. +            ) {
  812. +             You("turn to stone...");
  813. +             done_in_by(mon);
  814. +             return 2;
  815. +         }
  816. +         break;
  817. +       case AD_RUST:
  818. +         if(mhit)
  819. +           if (kicked) {
  820. +         if (uarmf)
  821. +             (void) rust_dmg(uarmf, xname(uarmf), 1, TRUE);
  822. +           } else
  823. +         corrode_weapon();
  824. +         break;
  825.         case AD_MAGM:
  826.           /* wrath of gods for attacking Oracle */
  827.           if(Antimagic) {
  828. ***************
  829. *** 1287,1296 ****
  830.   
  831.           switch(ptr->mattk[i].adtyp) {
  832.   
  833. !           case AD_PLYS:        /* specifically floating eye */
  834. !         if(canseemon(mon)) {
  835. !             tmp = -d((int)mon->m_lev+1, (int)ptr->mattk[i].damd);
  836.               if(mon->mcansee) {
  837.               if(Reflecting & W_AMUL) {
  838.                   makeknown(AMULET_OF_REFLECTION);
  839. --- 1331,1343 ----
  840.   
  841.           switch(ptr->mattk[i].adtyp) {
  842.   
  843. !           case AD_PLYS:
  844. !         tmp = -d((int)mon->m_lev+1, (int)ptr->mattk[i].damd);
  845. !         if(ptr == &mons[PM_FLOATING_EYE]) {
  846. !             if (!canseemon(mon)) {
  847. !             tmp = 0;
  848. !             break;
  849. !             }
  850.               if(mon->mcansee) {
  851.               if(Reflecting & W_AMUL) {
  852.                   makeknown(AMULET_OF_REFLECTION);
  853. ***************
  854. *** 1308,1313 ****
  855. --- 1355,1364 ----
  856.               pline("%s cannot defend itself.", Amonnam(mon,"blind"));
  857.               if(!rn2(500)) change_luck(-1);
  858.               }
  859. +         } else { /* gelatinous cube */
  860. +             You("are frozen by %s!", mon_nam(mon));
  861. +             nomul(tmp);
  862. +             tmp = 0;
  863.           }
  864.           break;
  865.             case AD_COLD:        /* brown mold or blue jelly */
  866. ***************
  867. *** 1350,1361 ****
  868.           if(monnear(mon, u.ux, u.uy)) {
  869.               tmp = d((int)mon->m_lev+1, (int)ptr->mattk[i].damd);
  870.               if(Fire_resistance) {
  871. !               shieldeff(u.ux, u.uy);
  872.               You("feel mildly warm.");
  873. ! #ifdef POLYSELF
  874. ! #ifdef GOLEMS
  875.               ugolemeffects(AD_FIRE, tmp);
  876. - #endif /* GOLEMS */
  877.   #endif
  878.               tmp = 0;
  879.               break;
  880. --- 1401,1410 ----
  881.           if(monnear(mon, u.ux, u.uy)) {
  882.               tmp = d((int)mon->m_lev+1, (int)ptr->mattk[i].damd);
  883.               if(Fire_resistance) {
  884. !             shieldeff(u.ux, u.uy);
  885.               You("feel mildly warm.");
  886. ! #if defined(POLYSELF) && defined(GOLEMS)
  887.               ugolemeffects(AD_FIRE, tmp);
  888.   #endif
  889.               tmp = 0;
  890.               break;
  891. ***************
  892. *** 1364,1369 ****
  893. --- 1413,1432 ----
  894.               mdamageu(mon, tmp);
  895.           }
  896.           break;
  897. +           case AD_ELEC:
  898. +         tmp = d((int)mon->m_lev+1, (int)ptr->mattk[i].damd);
  899. +         if(Shock_resistance) {
  900. +             shieldeff(u.ux, u.uy);
  901. +             You("feel a mild tingle.");
  902. + #if defined(POLYSELF) && defined(GOLEMS)
  903. +             ugolemeffects(AD_ELEC, tmp);
  904. + #endif
  905. +             tmp = 0;
  906. +             break;
  907. +         }
  908. +         You("are jolted with electricity!");
  909. +         mdamageu(mon, tmp);
  910. +         break;
  911.             default:
  912.           break;
  913.           }
  914. ***************
  915. *** 1398,1401 ****
  916. --- 1461,1487 ----
  917.           pline("Wait!  That's %s!", defmonnam(mtmp));
  918.       }
  919.       wakeup(mtmp);    /* clears mtmp->mimic */
  920. + }
  921. + static void
  922. + nohandglow()
  923. + {
  924. +     if (!u.umconf) return; /* for safety */
  925. +     if (u.umconf == 1) {
  926. +         if (Blind)
  927. +             Your("%s stop tingling.", makeplural(body_part(HAND)));
  928. +         else
  929. +             Your("%s stop glowing %s.",
  930. +                 makeplural(body_part(HAND)),
  931. +                 Hallucination ? hcolor() : red);
  932. +     } else {
  933. +         if (Blind)
  934. +             pline("The tingling in your %s lessens.",
  935. +                 makeplural(body_part(HAND)));
  936. +         else
  937. +             Your("%s no longer glow so brightly %s.",
  938. +                 makeplural(body_part(HAND)),
  939. +                 Hallucination ? hcolor() : red);
  940. +     }
  941. +     u.umconf--;
  942.   }
  943. *** src/Old/unixmain.c    Mon Feb 19 19:06:32 1990
  944. --- src/unixmain.c    Sun Feb 11 11:29:09 1990
  945. ***************
  946. *** 7,16 ****
  947.   
  948.   #include <signal.h>
  949.   #include <pwd.h>
  950.   
  951.   char SAVEF[PL_NSIZ + 11] = "save/";    /* save/99999player */
  952.   
  953. ! char *hname = 0;        /* name of the game (argv[0] of call) */
  954.   char obuf[BUFSIZ];    /* BUFSIZ is defined in stdio.h */
  955.   int hackpid = 0;                /* current pid */
  956.   int locknum = 0;                /* max num of players */
  957. --- 7,19 ----
  958.   
  959.   #include <signal.h>
  960.   #include <pwd.h>
  961. + #ifndef O_RDONLY
  962. + #include <fcntl.h>
  963. + #endif
  964.   
  965.   char SAVEF[PL_NSIZ + 11] = "save/";    /* save/99999player */
  966.   
  967. ! const char *hname = 0;        /* name of the game (argv[0] of call) */
  968.   char obuf[BUFSIZ];    /* BUFSIZ is defined in stdio.h */
  969.   int hackpid = 0;                /* current pid */
  970.   int locknum = 0;                /* max num of players */
  971. ***************
  972. *** 233,239 ****
  973.   #ifdef COMPRESS
  974.       Strcpy(old,SAVEF);
  975.       Strcat(SAVEF,".Z");
  976. !     if((fd = open(SAVEF,0)) >= 0) {
  977.            (void) close(fd);
  978.           Strcpy(cmd, COMPRESS);
  979.           Strcat(cmd, " -d ");    /* uncompress */
  980. --- 236,242 ----
  981.   #ifdef COMPRESS
  982.       Strcpy(old,SAVEF);
  983.       Strcat(SAVEF,".Z");
  984. !     if((fd = open(SAVEF,O_RDONLY)) >= 0) {
  985.            (void) close(fd);
  986.           Strcpy(cmd, COMPRESS);
  987.           Strcat(cmd, " -d ");    /* uncompress */
  988. ***************
  989. *** 246,252 ****
  990.       }
  991.       Strcpy(SAVEF,old);
  992.   #endif
  993. !     if((fd = open(SAVEF,0)) >= 0 &&
  994.          (uptodate(fd) || unlink(SAVEF) == 666)) {
  995.   #ifdef WIZARD
  996.           /* Since wizard is actually flags.debug, restoring might
  997. --- 249,256 ----
  998.       }
  999.       Strcpy(SAVEF,old);
  1000.   #endif
  1001. !     if((fd = open(SAVEF,O_RDONLY)) >= 0 &&
  1002. !        /* if not up-to-date, quietly unlink file via false condition */
  1003.          (uptodate(fd) || unlink(SAVEF) == 666)) {
  1004.   #ifdef WIZARD
  1005.           /* Since wizard is actually flags.debug, restoring might
  1006. ***************
  1007. *** 254,261 ****
  1008.            */
  1009.           boolean remember_wiz_mode = wizard;
  1010.   #endif
  1011.           (void) signal(SIGINT, (SIG_RET_TYPE) done1);
  1012. !         pline("Restoring old save file...");
  1013.           (void) fflush(stdout);
  1014.           if(!dorecover(fd))
  1015.               goto not_recovered;
  1016. --- 258,266 ----
  1017.            */
  1018.           boolean remember_wiz_mode = wizard;
  1019.   #endif
  1020. +         (void) chmod(SAVEF,0);    /* disallow parallel restores */
  1021.           (void) signal(SIGINT, (SIG_RET_TYPE) done1);
  1022. !         pline("Restoring save file...");
  1023.           (void) fflush(stdout);
  1024.           if(!dorecover(fd))
  1025.               goto not_recovered;
  1026. ***************
  1027. *** 274,279 ****
  1028. --- 279,297 ----
  1029.               pline("Do you want to keep the save file? ");
  1030.               if(yn() == 'n')
  1031.                   (void) unlink(SAVEF);
  1032. +             else {
  1033. +                 (void) chmod(SAVEF,FCMASK); /* back to readable */
  1034. + # ifdef COMPRESS
  1035. +                 Strcpy(cmd, COMPRESS);
  1036. +                 Strcat(cmd, " ");
  1037. + #  ifdef COMPRESS_OPTIONS
  1038. +                 Strcat(cmd, COMPRESS_OPTIONS);
  1039. +                 Strcat(cmd, " ");
  1040. + #  endif
  1041. +                 Strcat(cmd,SAVEF);
  1042. +                 (void) system(cmd);
  1043. + # endif
  1044. +             }
  1045.           }
  1046.   #endif
  1047.           flags.move = 0;
  1048. ***************
  1049. *** 382,390 ****
  1050.   
  1051.           if(dir == NULL)
  1052.           dir = ".";
  1053. !         if((fd = open(RECORD, 2)) < 0) {
  1054. !         Printf("Warning: cannot write %s/%s", dir, RECORD);
  1055. !         getret();
  1056.           } else
  1057.           (void) close(fd);
  1058.       }
  1059. --- 400,411 ----
  1060.   
  1061.           if(dir == NULL)
  1062.           dir = ".";
  1063. !         if((fd = open(RECORD, O_RDWR)) < 0) {
  1064. !         if((fd = open(RECORD, O_CREAT|O_RDWR, FCMASK)) < 0) {
  1065. !             Printf("Warning: cannot write %s/%s", dir, RECORD);
  1066. !             getret();
  1067. !         } else
  1068. !             (void) close(fd);
  1069.           } else
  1070.           (void) close(fd);
  1071.       }
  1072. *** src/Old/unixtty.c    Mon Feb 19 19:06:57 1990
  1073. --- src/unixtty.c    Sun Jan 21 13:58:48 1990
  1074. ***************
  1075. *** 115,121 ****
  1076.   /* reset terminal to original state */
  1077.   void
  1078.   settty(s)
  1079. ! char *s;
  1080.   {
  1081.       clear_screen();
  1082.       end_screen();
  1083. --- 115,121 ----
  1084.   /* reset terminal to original state */
  1085.   void
  1086.   settty(s)
  1087. ! const char *s;
  1088.   {
  1089.       clear_screen();
  1090.       end_screen();
  1091. ***************
  1092. *** 192,200 ****
  1093.   /*VARARGS1*/
  1094.   
  1095.   void
  1096. ! error VA_DECL(char *,s)
  1097.       VA_START(s);
  1098. !     VA_INIT(s, char *);
  1099.       if(settty_needed)
  1100.           settty(NULL);
  1101.       Vprintf(s,VA_ARGS);
  1102. --- 192,200 ----
  1103.   /*VARARGS1*/
  1104.   
  1105.   void
  1106. ! error VA_DECL(const char *,s)
  1107.       VA_START(s);
  1108. !     VA_INIT(s, const char *);
  1109.       if(settty_needed)
  1110.           settty(NULL);
  1111.       Vprintf(s,VA_ARGS);
  1112. *** src/Old/version.c    Mon Feb 19 19:07:51 1990
  1113. --- src/version.c    Mon Feb 12 18:47:37 1990
  1114. ***************
  1115. *** 5,11 ****
  1116.   #include    "hack.h"
  1117.   #include    "date.h"
  1118.   #ifndef BETA
  1119. ! #ifdef MSDOS
  1120.   # include    "patchlev.h"
  1121.   #else
  1122.   # include    "patchlevel.h"
  1123. --- 5,11 ----
  1124.   #include    "hack.h"
  1125.   #include    "date.h"
  1126.   #ifndef BETA
  1127. ! #if defined(MSDOS) && !defined(AMIGA)
  1128.   # include    "patchlev.h"
  1129.   #else
  1130.   # include    "patchlevel.h"
  1131. ***************
  1132. *** 51,53 ****
  1133. --- 51,222 ----
  1134.           datestring);
  1135.       return 0;
  1136.   }
  1137. + #define Next_opt(x) if (next_opt(x)) goto quit;
  1138. + #define Page_line(x) if (page_line(x)) goto quit;
  1139. + int
  1140. + doextversion()
  1141. + {
  1142. +     set_pager(0);
  1143. +     (void)page_line("");
  1144. +     Page_line("Options compiled into this version of NetHack");
  1145. +     Page_line("(in no particular order):");
  1146. +     Page_line("");
  1147. + #ifdef POLYSELF
  1148. +     Next_opt("self-polymorphing, ");
  1149. + #endif
  1150. + #ifdef THEOLOGY
  1151. +     Next_opt("theology, ");
  1152. + #endif
  1153. + #ifdef SOUNDS
  1154. +     Next_opt("sounds, ");
  1155. + #endif
  1156. + #ifdef KICK
  1157. +     Next_opt("kicking, ");
  1158. + #endif
  1159. + #ifdef THRONES
  1160. +     Next_opt("thrones, ");
  1161. + #endif
  1162. + #ifdef FOUNTAINS
  1163. +     Next_opt("fountains, ");
  1164. + #endif
  1165. + #ifdef SINKS
  1166. +     Next_opt("sinks, ");
  1167. + #endif
  1168. + #ifdef ALTARS
  1169. +     Next_opt("altars, ");
  1170. + #endif
  1171. + #ifdef WALLIFIED_MAZE
  1172. +     Next_opt("fancy mazes, ");
  1173. + #endif
  1174. + #ifdef REINCARNATION
  1175. +     Next_opt("Rogue level, ");
  1176. + #endif
  1177. + #ifdef STRONGHOLD
  1178. +     Next_opt("special levels, ");
  1179. + #endif
  1180. + #ifdef ORACLE
  1181. +     Next_opt("oracle, ");
  1182. + #endif
  1183. + #ifdef MEDUSA
  1184. +     Next_opt("Medusa, ");
  1185. + #endif
  1186. + #ifdef KOPS
  1187. +     Next_opt("Kops, ");
  1188. + #endif
  1189. + #ifdef ARMY
  1190. +     Next_opt("armies, ");
  1191. + #endif
  1192. + #ifdef WORM
  1193. +     Next_opt("long worms, ");
  1194. + #endif
  1195. + #ifdef GOLEMS
  1196. +     Next_opt("golems, ");
  1197. + #endif
  1198. + #ifdef INFERNO
  1199. +     Next_opt("inferno, ");
  1200. + #endif
  1201. + #ifdef SEDUCE
  1202. +     Next_opt("seduction, ");
  1203. + #endif
  1204. + #ifdef TOLKIEN
  1205. +     Next_opt("Tolkien extras, ");
  1206. + #endif
  1207. + #ifdef PROBING
  1208. +     Next_opt("wand of probing, ");
  1209. + #endif
  1210. + #ifdef WALKIES
  1211. +     Next_opt("leashes, ");
  1212. + #endif
  1213. + #ifdef SHIRT
  1214. +     Next_opt("Hawaiian shirt, ");
  1215. + #endif
  1216. + #ifdef MUSIC
  1217. +     Next_opt("music, ");
  1218. + #endif
  1219. + #ifdef TUTTI_FRUTTI
  1220. +     Next_opt("fruits, ");
  1221. + #endif
  1222. + #ifdef SPELLS
  1223. +     Next_opt("spells, ");
  1224. + #endif
  1225. + #ifdef NAMED_ITEMS
  1226. +     Next_opt("named items, ");
  1227. + #endif
  1228. + #ifdef ELBERETH
  1229. +     Next_opt("Elbereth, ");
  1230. + #endif
  1231. + #ifdef EXPLORE_MODE
  1232. +     Next_opt("explore mode, ");
  1233. + #endif
  1234. + #ifdef HARD
  1235. +     Next_opt("HARD, ");
  1236. + #endif
  1237. + #ifdef REDO
  1238. +     Next_opt("redo-commands, ");
  1239. + #endif
  1240. + #ifdef CLIPPING
  1241. +     Next_opt("screen clipping, ");
  1242. + #endif
  1243. + #ifdef TEXTCOLOR
  1244. +     Next_opt("color, ");
  1245. + #endif
  1246. + #ifdef DGK
  1247. +     Next_opt("Don Kneller's enhancements, ");
  1248. + #endif
  1249. + #ifdef OVERLAY
  1250. +     Next_opt("overlays, ");
  1251. + #endif
  1252. + #ifdef SHELL
  1253. +     Next_opt("shell command, ");
  1254. + #endif
  1255. + #ifdef MAIL
  1256. +     Next_opt("mail, ");
  1257. + #endif
  1258. + #ifdef NEWS
  1259. +     Next_opt("news file, ");
  1260. + #endif
  1261. + #ifdef COM_COMPL
  1262. +     Next_opt("command line completion, ");
  1263. + #endif
  1264. + #ifdef AMIGA_WBENCH
  1265. +     Next_opt("Amiga WorkBench support, ");
  1266. + #endif
  1267. + #ifdef WIZARD
  1268. +     Next_opt("wizard mode, ");
  1269. + #endif
  1270. + #ifdef LOGFILE
  1271. +     Next_opt("logfile, ");
  1272. + #endif
  1273. + #ifdef TERMLIB
  1274. +     Next_opt("termcap file, ");
  1275. + #endif
  1276. + #ifdef TERMINFO
  1277. +     Next_opt("terminfo, ");
  1278. + #endif
  1279. + #ifdef ANSI_DEFAULT
  1280. +     Next_opt("ANSI default terminal, ");
  1281. + #endif
  1282. + #ifdef COMPRESS
  1283. +     Next_opt("compress bones/level/save files, ");
  1284. + #endif
  1285. +     Next_opt("basic NetHack features");
  1286. +     Next_opt("");
  1287. +     set_pager(1);
  1288. +     return 0;
  1289. + quit:
  1290. +     (void) next_opt("\033");
  1291. +     set_pager(2);
  1292. +     return 0;
  1293. + }
  1294. + #ifdef MSDOS
  1295. + int
  1296. + comp_times(filetime)
  1297. + long filetime;
  1298. + {
  1299. +     if(filetime < compiletime) return (1);
  1300. +     else return (0);
  1301. + }
  1302. + #endif
  1303. *** src/Old/weapon.c    Mon Feb 19 19:08:10 1990
  1304. --- src/weapon.c    Thu Jan 25 22:14:52 1990
  1305. ***************
  1306. *** 9,14 ****
  1307. --- 9,16 ----
  1308.    */
  1309.   #include    "hack.h"
  1310.   
  1311. + #ifdef OVLB
  1312.   static const char kebabable[] = { S_XORN, S_DRAGON, S_NAGA, S_GIANT, 0 };
  1313.   
  1314.   /*
  1315. ***************
  1316. *** 168,173 ****
  1317. --- 170,178 ----
  1318.       return;
  1319.   }
  1320.   
  1321. + #endif /* OVLB */
  1322. + #ifdef OVL0
  1323.   #define    Oselect(x)    if((otmp = m_carrying(mtmp, x))) return(otmp);
  1324.   
  1325.   #ifdef TOLKIEN
  1326. ***************
  1327. *** 352,357 ****
  1328. --- 357,365 ----
  1329.       else return(sbon+ACURR(A_DEX)-14);
  1330.   }
  1331.   
  1332. + #endif /* OVL0 */
  1333. + #ifdef OVL1
  1334.   int
  1335.   dbon() {    /* damage bonus for strength */
  1336.   #ifdef POLYSELF
  1337. ***************
  1338. *** 367,369 ****
  1339. --- 375,379 ----
  1340.       else if(ACURR(A_STR) < 118) return(5);    /* up to 18/99 */
  1341.       else return(6);
  1342.   }
  1343. + #endif /* OVL1 */
  1344. *** src/Old/were.c    Mon Feb 19 19:08:33 1990
  1345. --- src/were.c    Thu Jan 25 22:14:54 1990
  1346. ***************
  1347. *** 4,9 ****
  1348. --- 4,13 ----
  1349.   
  1350.   #include    "hack.h"
  1351.   
  1352. + static int FDECL(counter_were,(int));
  1353. + #ifdef OVL0
  1354.   void
  1355.   were_change(mon)
  1356.   register struct monst *mon;
  1357. ***************
  1358. *** 22,27 ****
  1359. --- 26,34 ----
  1360.           } else if(!rn2(30) || Protection_from_shape_changers) new_were(mon);
  1361.   }
  1362.   
  1363. + #endif /* OVL0 */
  1364. + #ifdef OVLB
  1365.   static int
  1366.   counter_were(pm)
  1367.   int pm;
  1368. ***************
  1369. *** 108,110 ****
  1370. --- 115,119 ----
  1371.       (void) polymon(u.ulycn);
  1372.   }
  1373.   #endif
  1374. + #endif /* OVLB */
  1375. *** src/Old/wield.c    Mon Feb 19 19:08:53 1990
  1376. --- src/wield.c    Sun Jan 21 13:58:49 1990
  1377. ***************
  1378. *** 65,71 ****
  1379.           You("wield the cockatrice corpse in your bare %s.",
  1380.               makeplural(body_part(HAND)));
  1381.           You("turn to stone...");
  1382. !         killer="cockatrice corpse";
  1383.           done(STONING);
  1384.       } else if(uarms && bimanual(wep))
  1385.           You("cannot wield a two-handed %s and hold a shield.",
  1386. --- 65,72 ----
  1387.           You("wield the cockatrice corpse in your bare %s.",
  1388.               makeplural(body_part(HAND)));
  1389.           You("turn to stone...");
  1390. !         killer_format = KILLED_BY;
  1391. !         killer="touching a cockatrice corpse";
  1392.           done(STONING);
  1393.       } else if(uarms && bimanual(wep))
  1394.           You("cannot wield a two-handed %s and hold a shield.",
  1395. ***************
  1396. *** 114,120 ****
  1397.       else if (uwep->spe > -6) {
  1398.           Your("%s!", aobjnam(uwep, "corrode"));
  1399.           uwep->spe--;
  1400. !     } else    Your("%s quite rusted now.", aobjnam(uwep, "look"));
  1401.   }
  1402.   
  1403.   int
  1404. --- 115,121 ----
  1405.       else if (uwep->spe > -6) {
  1406.           Your("%s!", aobjnam(uwep, "corrode"));
  1407.           uwep->spe--;
  1408. !     } else    Your("%s quite rusted now.", aobjnam(uwep, Blind ? "feel" : "look"));
  1409.   }
  1410.   
  1411.   int
  1412. ***************
  1413. *** 124,132 ****
  1414.   {
  1415.       register const char *color = Hallucination ? hcolor() :
  1416.                        (amount < 0) ? black : blue;
  1417. !     register char *xtime;
  1418.   
  1419. !     if(!uwep || (uwep->olet != WEAPON_SYM && uwep->otyp != PICK_AXE)) {
  1420.           char buf[36];
  1421.   
  1422.           Sprintf(buf, "Your %s %s.", makeplural(body_part(HAND)),
  1423. --- 125,134 ----
  1424.   {
  1425.       register const char *color = Hallucination ? hcolor() :
  1426.                        (amount < 0) ? black : blue;
  1427. !     register const char *xtime;
  1428.   
  1429. !     if(!uwep || (uwep->olet != WEAPON_SYM && uwep->otyp != PICK_AXE
  1430. !             && uwep->otyp != UNICORN_HORN)) {
  1431.           char buf[36];
  1432.   
  1433.           Sprintf(buf, "Your %s %s.", makeplural(body_part(HAND)),
  1434. ***************
  1435. *** 145,151 ****
  1436.   
  1437.       if(uwep->otyp == CRYSKNIFE && amount < 0) {
  1438.           uwep->otyp = WORM_TOOTH;
  1439. !         Your("weapon looks duller now.");
  1440.           return(1);
  1441.       }
  1442.   #endif
  1443. --- 147,153 ----
  1444.   
  1445.       if(uwep->otyp == CRYSKNIFE && amount < 0) {
  1446.           uwep->otyp = WORM_TOOTH;
  1447. !         Your("weapon seems duller now.");
  1448.           return(1);
  1449.       }
  1450.   #endif
  1451. *** src/Old/wizard.c    Mon Feb 19 19:09:10 1990
  1452. --- src/wizard.c    Tue Feb 13 18:41:41 1990
  1453. ***************
  1454. *** 1,4 ****
  1455. ! /*    SCCS Id: @(#)wizard.c    3.0    88/04/11
  1456.   /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
  1457.   /* NetHack may be freely redistributed.  See license for details. */
  1458.   
  1459. --- 1,4 ----
  1460. ! /*    SCCS Id: @(#)wizard.c    3.0    90/01/09
  1461.   /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
  1462.   /* NetHack may be freely redistributed.  See license for details. */
  1463.   
  1464. ***************
  1465. *** 8,13 ****
  1466. --- 8,15 ----
  1467.   
  1468.   #include "hack.h"
  1469.   
  1470. + #ifdef OVLB
  1471.   #ifdef HARD
  1472.   /*    TODO:    Expand this list.    */
  1473.   static const int nasties[] = {
  1474. ***************
  1475. *** 20,30 ****
  1476.       };
  1477.   #endif /* HARD */
  1478.   
  1479. ! /*    TODO:    investigate this. */
  1480. ! static const char wizapp[] = {
  1481. !     S_HUMAN, S_DEMON, S_VAMPIRE, S_DRAGON, S_TROLL, S_UMBER,
  1482. !     S_XORN, S_XAN, S_COCKATRICE, S_EYE, S_NAGA, S_TRAPPER,
  1483. !     /* '1' /* Historical reference */ };
  1484.   
  1485.   /* If he has found the Amulet, make the wizard appear after some time */
  1486.   void
  1487. --- 22,38 ----
  1488.       };
  1489.   #endif /* HARD */
  1490.   
  1491. ! static const unsigned wizapp[] = {
  1492. !     PM_HUMAN, PM_WATER_DEMON, PM_VAMPIRE,
  1493. !     PM_RED_DRAGON, PM_TROLL, PM_UMBER_HULK,
  1494. !     PM_XORN, PM_XAN, PM_COCKATRICE,
  1495. !     PM_FLOATING_EYE,
  1496. !     PM_GUARDIAN_NAGA,
  1497. !     PM_TRAPPER
  1498. ! };
  1499. ! #endif /* OVLB */
  1500. ! #ifdef OVL0
  1501.   
  1502.   /* If he has found the Amulet, make the wizard appear after some time */
  1503.   void
  1504. ***************
  1505. *** 39,51 ****
  1506.               if(u.uhave_amulet) {
  1507.               mtmp->msleep = 0;
  1508.               if(dist(mtmp->mx,mtmp->my) > 2)
  1509. !                 pline(
  1510. !     "You get the creepy feeling that somebody noticed your taking the Amulet."
  1511.                   );
  1512.               return;
  1513.               }
  1514.   }
  1515.   
  1516.   int
  1517.   mon_has_amulet(mtmp)
  1518.   register struct monst *mtmp;
  1519. --- 47,62 ----
  1520.               if(u.uhave_amulet) {
  1521.               mtmp->msleep = 0;
  1522.               if(dist(mtmp->mx,mtmp->my) > 2)
  1523. !                 You(
  1524. !     "get the creepy feeling that somebody noticed your taking the Amulet."
  1525.                   );
  1526.               return;
  1527.               }
  1528.   }
  1529.   
  1530. + #endif /* OVL0 */
  1531. + #ifdef OVLB
  1532.   int
  1533.   mon_has_amulet(mtmp)
  1534.   register struct monst *mtmp;
  1535. ***************
  1536. *** 86,91 ****
  1537. --- 97,105 ----
  1538.                   /* teleport to it and pick it up */
  1539.                   remove_monster(mtmp->mx, mtmp->my);
  1540.                   place_monster(mtmp, otmp->ox, otmp->oy);
  1541. +                 if (cansee(mtmp->mx, mtmp->my))
  1542. +                 pline("%s picks up %s.", Monnam(mtmp),
  1543. +                                 xname(otmp));
  1544.                   freeobj(otmp);
  1545.                   mpickobj(mtmp, otmp);
  1546.                   pmon(mtmp);
  1547. ***************
  1548. *** 100,106 ****
  1549.       /* secondary goal - stayin' alive */
  1550.   
  1551.       /* if wounded, hole up on or near the stairs (to block them) */
  1552. !     if(mtmp->mhp < 20 + rnd(10))
  1553.           if (mtmp->mx != xupstair && mtmp->my != yupstair)
  1554.           mnearto(mtmp,xupstair,yupstair,TRUE);
  1555.   
  1556. --- 114,121 ----
  1557.       /* secondary goal - stayin' alive */
  1558.   
  1559.       /* if wounded, hole up on or near the stairs (to block them) */
  1560. !     /* unless, of course, there are no stairs (e.g. endlevel */
  1561. !     if(mtmp->mhp < 20 + rnd(10) && (xupstair || yupstair))
  1562.           if (mtmp->mx != xupstair && mtmp->my != yupstair)
  1563.           mnearto(mtmp,xupstair,yupstair,TRUE);
  1564.   
  1565. ***************
  1566. *** 131,138 ****
  1567.   
  1568.       for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) {
  1569.           mtmp->msleep = 0;
  1570. !         if(mtmp->mfroz && !rn2(5))
  1571. !             mtmp->mfroz = 0;
  1572.       }
  1573.   }
  1574.   
  1575. --- 146,155 ----
  1576.   
  1577.       for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) {
  1578.           mtmp->msleep = 0;
  1579. !         if(!mtmp->mcanmove && !rn2(5)) {
  1580. !             mtmp->mfrozen = 0;
  1581. !             mtmp->mcanmove = 1;
  1582. !         }
  1583.       }
  1584.   }
  1585.   
  1586. ***************
  1587. *** 148,153 ****
  1588. --- 165,171 ----
  1589.               mtmp2->minvent->spe = -1;
  1590.           }
  1591.           unpmon(mtmp2);
  1592. +         mtmp2->m_ap_type = M_AP_MONSTER;
  1593.           mtmp2->mappearance = wizapp[rn2(SIZE(wizapp))];
  1594.           pmon(mtmp2);
  1595.       }
  1596. ***************
  1597. *** 262,308 ****
  1598.   
  1599.   const char *random_malediction[] = {
  1600.       "Hell shall soon claim thy remains,",
  1601. !     "I chortle at thee, pathetic",
  1602. !     "Prepare to die,",
  1603.       "Resistance is useless,",
  1604.       "Surrender or die, thou",
  1605. !     "There shall be no mercy, yon",
  1606.       "Thou shalt repent of thy cunning,",
  1607.       "Thou art as a flea to me,",
  1608.       "Thou art doomed,",
  1609.       "Thy fate is sealed,",
  1610.       "Verily, thou shalt be one dead"
  1611. ! /*    "Go play leapfrog with a unicorn,", */
  1612.   };
  1613.   
  1614. ! /* Insult the player */
  1615.   void
  1616.   cuss(mtmp)
  1617.   register struct monst    *mtmp;
  1618.   {
  1619. !     switch (rn2(5)) {
  1620. !         case 0: pline("%s casts aspersions on your ancestry.",
  1621. !               Monnam(mtmp));
  1622. !             break;
  1623. !         case 1: pline("%s laughs fiendishly.", /* typical bad guy action */
  1624. !               Monnam(mtmp));
  1625. !             break;
  1626. !         default:
  1627. !             if (u.uhave_amulet && !rn2(SIZE(random_insult)))
  1628. !             pline("\"Relinquish the amulet, %s!\"",
  1629. !                   random_insult[rn2(SIZE(random_insult))]);
  1630. !             else if (u.uhp < 5 && !rn2(2))    /* Panic */
  1631. !             pline(rn2(2) ?
  1632. !                 "\"Even now thy life force ebbs, %s!\"" :
  1633. !                 "\"Savor thy breath, %s, it be thine last!\"",
  1634. !                   random_insult[rn2(SIZE(random_insult))]);
  1635. !             else if (mtmp->mhp < 5 && !rn2(2))    /* Parthian shot */
  1636. !             pline(rn2(2) ?
  1637. !                 "\"I shall return.\"" :
  1638. !                 "\"I'll be back.\"");
  1639. !             else
  1640. !             pline("\"%s %s!\"",
  1641. !                   random_malediction[rn2(SIZE(random_malediction))],
  1642. !                   random_insult[rn2(SIZE(random_insult))]);
  1643.       }
  1644.   }
  1645. --- 280,357 ----
  1646.   
  1647.   const char *random_malediction[] = {
  1648.       "Hell shall soon claim thy remains,",
  1649. !     "I chortle at thee, thou pathetic",
  1650. !     "Prepare to die, thou ",
  1651.       "Resistance is useless,",
  1652.       "Surrender or die, thou",
  1653. !     "There shall be no mercy, thou",
  1654.       "Thou shalt repent of thy cunning,",
  1655.       "Thou art as a flea to me,",
  1656.       "Thou art doomed,",
  1657.       "Thy fate is sealed,",
  1658.       "Verily, thou shalt be one dead"
  1659. ! };
  1660. ! #ifdef SOUNDS
  1661. ! const char *demonic_malediction[] = {
  1662. !     "I first mistook thee for a statue, when I regarded thy head of stone.",
  1663. !     "Come here often?",
  1664. !     "Dost pain excite thee?  Wouldst thou prefer the whip?",
  1665. !     "Thinkest thou it shall tickle as I rip out thy lungs?",
  1666. !     "Eat slime and die!",
  1667. !     "Go ahead, fetch thy mama!  I shall wait.",
  1668. !     "Go play leapfrog with a herd of unicorns!",
  1669. !     "Hast thou been drinking, or art thou always so clumsy?",
  1670. !     "This time I shall let thee off with a spanking, but let it not happen again.",
  1671. !     "I've met smarter (and prettier) acid blobs.",
  1672. !     "Look!  Thy bootlace is undone!",
  1673. !     "Mercy!  Dost thou wish me to die of laughter?",
  1674. !     "Run away!  Live to flee another day!",    
  1675. !     "Thou hadst best fight better than thou canst dress!",
  1676. !     "Twixt thy cousin and thee, Medusa is the prettier.",
  1677. !     "Methinks thou wert unnaturally interested in yon corpse back there, eh, varlet?",
  1678. !     "Up thy nose with a rubber hose!",
  1679. !     "Verily, thy corpse could not smell worse!",
  1680. !     "Wait!  I shall polymorph into a grid bug to give thee a fighting chance!",
  1681. !     "Why search for the Amulet?  Thou wouldst but lose it, cretin.",
  1682.   };
  1683. + #endif
  1684.   
  1685. ! /* Insult or intimidate the player */
  1686.   void
  1687.   cuss(mtmp)
  1688.   register struct monst    *mtmp;
  1689.   {
  1690. ! #ifdef SOUNDS
  1691. !     if (mtmp->iswiz) {
  1692. ! #endif
  1693. !         if (!rn2(5))  /* typical bad guy action */
  1694. !         pline("%s laughs fiendishly.", Monnam(mtmp));
  1695. !         else 
  1696. !         if (u.uhave_amulet && !rn2(SIZE(random_insult)))
  1697. !             pline("\"Relinquish the amulet, %s!\"",
  1698. !               random_insult[rn2(SIZE(random_insult))]);
  1699. !         else if (u.uhp < 5 && !rn2(2))    /* Panic */
  1700. !             pline(rn2(2) ?
  1701. !               "\"Even now thy life force ebbs, %s!\"" :
  1702. !               "\"Savor thy breath, %s, it be thine last!\"",
  1703. !               random_insult[rn2(SIZE(random_insult))]);
  1704. !         else if (mtmp->mhp < 5 && !rn2(2))    /* Parthian shot */
  1705. !             verbalize(rn2(2) ?
  1706. !                   "I shall return." :
  1707. !                   "I'll be back.");
  1708. !         else
  1709. !             pline("\"%s %s!\"",
  1710. !               random_malediction[rn2(SIZE(random_malediction))],
  1711. !               random_insult[rn2(SIZE(random_insult))]);
  1712. ! #ifdef SOUNDS
  1713. !     } else {
  1714. !         if (!rn2(5))
  1715. !         kludge("%s casts aspersions on your ancestry.", Monnam(mtmp));
  1716. !         else
  1717. !         verbalize(demonic_malediction[rn2(SIZE(demonic_malediction))]);
  1718.       }
  1719. + #endif
  1720.   }
  1721. + #endif /* OVLB */
  1722. *** src/Old/worm.c    Mon Feb 19 19:09:31 1990
  1723. --- src/worm.c    Sun Jan 28 19:32:59 1990
  1724. ***************
  1725. *** 7,12 ****
  1726. --- 7,36 ----
  1727.   #ifdef WORM
  1728.   #include "wseg.h"
  1729.   
  1730. + static void FDECL(remseg,(struct monst *,struct wseg *));
  1731. + /* Each tailed worm has a wormno.  This is used as an index for the following
  1732. +  * arrays:
  1733. +  * wsegs: the start of a a linked list of segments, located at the tail.
  1734. +  * wheads: the end of a linked list of segments, located at the head.  Putting
  1735. +  *    the tail of the list at the head of the worm and vice versa is an
  1736. +  *    endless source of confusion, but necessary.  From now on, we will use
  1737. +  *    "start" and "end" to refer to the list, and "head" and "tail" to refer
  1738. +  *    to the worm.
  1739. +  * wgrowtime: obvious.
  1740. +  *
  1741. +  * When a worm is moved, we add a new segment at the head (end of the list)
  1742. +  * and (unless we want it to grow) delete the segment at the tail (beginning
  1743. +  * of the list).  This new head segment is located in the same square as
  1744. +  * the actual head of the worm (thus requiring a special case when setting
  1745. +  * level.monsters upon worm movement).  If we do want to grow the worm, we
  1746. +  * don't delete the tail segment, and we give the worm extra hit points,
  1747. +  * which possibly go into its maximum.
  1748. +  *
  1749. +  * Non-moving worms (worm_nomove) shrink instead of grow as their tails keep
  1750. +  * going while their heads are stopped short.  Delete the tail segment,
  1751. +  * and remove hit points from the worm.
  1752. +  */
  1753.   struct wseg *wsegs[32] = DUMMY, *wheads[32] = DUMMY, *m_atseg = 0;
  1754.   long wgrowtime[32] = DUMMY;
  1755.   
  1756. ***************
  1757. *** 193,199 ****
  1758. --- 217,231 ----
  1759.           wsegs[tmp2] = wsegs[tmp];
  1760.           wgrowtime[tmp2] = 0;
  1761.       }
  1762. +     /* do-loop: go from the tail to the head.  Segments close to the tail
  1763. +      * either die or become part of worm 2.  We stop at the hit segment
  1764. +      * and this loop never goes down the entire length of the worm.
  1765. +      */
  1766.       do {
  1767. +         /* The segment immediately next to (tailwards) the one hit, */
  1768. +         /* becoes the head of the new second worm.  Note: at this point, */
  1769. +         /* wtmp->nseg is the one you hit, wtmp is immediately tailwards, */
  1770. +         /* and wtmp->nseg->nseg is immediately headwards. */
  1771.           if(wtmp->nseg->wx == x && wtmp->nseg->wy == y){
  1772.           if(tmp2) wheads[tmp2] = wtmp;
  1773.           wsegs[tmp] = wtmp->nseg->nseg;
  1774. ***************
  1775. *** 202,208 ****
  1776.           if(tmp2) {
  1777.               kludge("You cut %s in half.", mon_nam(mtmp));
  1778.           /* devalue the monster level of both halves of the worm */
  1779. !             mtmp->m_lev = (mtmp->m_lev <= 2) ? 2 : mtmp->m_lev - 2;
  1780.               mtmp2->m_lev = mtmp->m_lev;
  1781.           /* calculate the mhp on the new (lower) monster level */
  1782.               mtmp2->mhpmax = mtmp2->mhp = d((int)mtmp2->m_lev, 8);
  1783. --- 234,240 ----
  1784.           if(tmp2) {
  1785.               kludge("You cut %s in half.", mon_nam(mtmp));
  1786.           /* devalue the monster level of both halves of the worm */
  1787. !             mtmp->m_lev = (mtmp->m_lev <= 3) ? 2 : mtmp->m_lev - 2;
  1788.               mtmp2->m_lev = mtmp->m_lev;
  1789.           /* calculate the mhp on the new (lower) monster level */
  1790.               mtmp2->mhpmax = mtmp2->mhp = d((int)mtmp2->m_lev, 8);
  1791. ***************
  1792. *** 219,226 ****
  1793. --- 251,261 ----
  1794.           mtmp->mhp /= 2;
  1795.           return;
  1796.           }
  1797. +     /* Worm segments which are closer to the tail than the one you hit, */
  1798. +     /* get either deleted or transferred from the old to new worms */
  1799.           wtmp2 = wtmp->nseg;
  1800.           if(!tmp2) remseg(mtmp, wtmp);
  1801. +         else place_worm_seg(mtmp2, wtmp->wx, wtmp->wy);
  1802.           wtmp = wtmp2;
  1803.       } while(wtmp->nseg);
  1804.       panic("Cannot find worm segment");
  1805. *** src/Old/worn.c    Mon Feb 19 19:09:52 1990
  1806. --- src/worn.c    Mon Jan 22 21:02:41 1990
  1807. ***************
  1808. *** 35,42 ****
  1809.   register struct obj *obj;
  1810.   long mask;
  1811.   {
  1812. !     register struct worn *wp;
  1813. !     register struct obj *oobj;
  1814.   
  1815.       for(wp = worn; wp->w_mask; wp++) if(wp->w_mask & mask) {
  1816.           oobj = *(wp->w_obj);
  1817. --- 35,42 ----
  1818.   register struct obj *obj;
  1819.   long mask;
  1820.   {
  1821. !     register const struct worn *wp;
  1822. !     register struct obj *oobj = 0;
  1823.   
  1824.       for(wp = worn; wp->w_mask; wp++) if(wp->w_mask & mask) {
  1825.           oobj = *(wp->w_obj);
  1826. ***************
  1827. *** 71,87 ****
  1828.        */
  1829.       if (Inhell && !Fire_resistance) {
  1830.           pline(crispy);
  1831. !         killer = "loss of fire protection";
  1832.           done(BURNING);
  1833.           /* If we're here they survived with life saving, so put the
  1834.            * weapon they just unwielded back in their hands...
  1835.            */
  1836. !         if (oobj->otyp != DRAGON_SCALE_MAIL
  1837.                   && oobj->otyp != RIN_FIRE_RESISTANCE
  1838.   #ifdef NAMED_ITEMS
  1839.                   && !defends(AD_FIRE, oobj)
  1840.   #endif
  1841. !                 && oobj->corpsenm != PM_RED_DRAGON)
  1842.               impossible("lost FR from a non-FR item?");
  1843.           setworn(oobj, mask);
  1844.       }
  1845. --- 71,88 ----
  1846.        */
  1847.       if (Inhell && !Fire_resistance) {
  1848.           pline(crispy);
  1849. !         killer_format = NO_KILLER_PREFIX;
  1850. !         killer = self_pronoun("lost %s fire protection in hell","his");
  1851.           done(BURNING);
  1852.           /* If we're here they survived with life saving, so put the
  1853.            * weapon they just unwielded back in their hands...
  1854.            */
  1855. !         if (!oobj || (oobj->otyp != DRAGON_SCALE_MAIL
  1856.                   && oobj->otyp != RIN_FIRE_RESISTANCE
  1857.   #ifdef NAMED_ITEMS
  1858.                   && !defends(AD_FIRE, oobj)
  1859.   #endif
  1860. !                 && oobj->corpsenm != PM_RED_DRAGON))
  1861.               impossible("lost FR from a non-FR item?");
  1862.           setworn(oobj, mask);
  1863.       }
  1864. ***************
  1865. *** 92,98 ****
  1866.   setnotworn(obj)
  1867.   register struct obj *obj;
  1868.   {
  1869. !     register struct worn *wp;
  1870.   
  1871.       if (!obj) return;
  1872.       for(wp = worn; wp->w_mask; wp++)
  1873. --- 93,99 ----
  1874.   setnotworn(obj)
  1875.   register struct obj *obj;
  1876.   {
  1877. !     register const struct worn *wp;
  1878.   
  1879.       if (!obj) return;
  1880.       for(wp = worn; wp->w_mask; wp++)
  1881. ***************
  1882. *** 111,117 ****
  1883.        */
  1884.       if (Inhell && !Fire_resistance && obj->olet != AMULET_SYM) {
  1885.           pline(crispy);
  1886. !         killer = "loss of fire protection";
  1887.           done(BURNING);
  1888.           /* Survived with lifesaving, etc...; there's no general way
  1889.            * to undo the setnotworn()--we can't re-wear/wield the
  1890. --- 112,119 ----
  1891.        */
  1892.       if (Inhell && !Fire_resistance && obj->olet != AMULET_SYM) {
  1893.           pline(crispy);
  1894. !         killer_format = NO_KILLER_PREFIX;
  1895. !         killer = self_pronoun("lost %s fire protection in hell","his");
  1896.           done(BURNING);
  1897.           /* Survived with lifesaving, etc...; there's no general way
  1898.            * to undo the setnotworn()--we can't re-wear/wield the
  1899. *** src/Old/search.c    Mon Feb 19 18:58:10 1990
  1900. --- src/search.c    Sat Feb  3 21:37:33 1990
  1901. ***************
  1902. *** 7,12 ****
  1903. --- 7,16 ----
  1904.   #  include "artifact.h"
  1905.   #endif
  1906.   
  1907. + static void FDECL(findone,(XCHAR_P,XCHAR_P,int *));
  1908. + #ifdef OVLB
  1909.   static void
  1910.   findone(zx,zy,num)
  1911.   xchar zx,zy;
  1912. ***************
  1913. *** 66,78 ****
  1914.       num = 0;
  1915.       for(zy = ly; zy <= hy; zy++)
  1916.           for(zx = lx; zx <= hx; zx++)
  1917. !             findone(zx,zy,&num);
  1918.       for(zy = ly2; zy <= hy2; zy++)
  1919.           for(zx = lx2; zx <= hx2; zx++)
  1920. !             findone(zx,zy,&num);
  1921.       return(num);
  1922.   }
  1923.   
  1924.   int
  1925.   dosearch()
  1926.   {
  1927. --- 70,87 ----
  1928.       num = 0;
  1929.       for(zy = ly; zy <= hy; zy++)
  1930.           for(zx = lx; zx <= hx; zx++)
  1931. !             if(isok(zx,zy))
  1932. !                 findone(zx,zy,&num);
  1933.       for(zy = ly2; zy <= hy2; zy++)
  1934.           for(zx = lx2; zx <= hx2; zx++)
  1935. !             if(isok(zx,zy))
  1936. !                 findone(zx,zy,&num);
  1937.       return(num);
  1938.   }
  1939.   
  1940. + #endif /* OVLB */
  1941. + #ifdef OVL1
  1942.   int
  1943.   dosearch()
  1944.   {
  1945. ***************
  1946. *** 98,104 ****
  1947.               pline("What are you looking for?  The exit?");
  1948.       } else
  1949.           for(x = u.ux-1; x < u.ux+2; x++)
  1950. !           for(y = u.uy-1; y < u.uy+2; y++)
  1951.           if(x != u.ux || y != u.uy) {
  1952.               if(levl[x][y].typ == SDOOR) {
  1953.   #ifdef NAMED_ITEMS
  1954. --- 107,114 ----
  1955.               pline("What are you looking for?  The exit?");
  1956.       } else
  1957.           for(x = u.ux-1; x < u.ux+2; x++)
  1958. !           for(y = u.uy-1; y < u.uy+2; y++) {
  1959. !         if(!isok(x,y)) continue;
  1960.           if(x != u.ux || y != u.uy) {
  1961.               if(levl[x][y].typ == SDOOR) {
  1962.   #ifdef NAMED_ITEMS
  1963. ***************
  1964. *** 153,158 ****
  1965. --- 163,169 ----
  1966.                           You("find %s posing as a statue.",
  1967.                             defmonnam(mtmp));
  1968.                       delobj(otmp);
  1969. +                     newsym(x, y);
  1970.                         }
  1971.                       deltrap(trap);
  1972.                       return(1);
  1973. ***************
  1974. *** 164,172 ****
  1975. --- 175,187 ----
  1976.                   }
  1977.               }
  1978.           }
  1979. +           }
  1980.       return(1);
  1981.   }
  1982.   
  1983. + #endif /* OVL1 */
  1984. + #ifdef OVLB
  1985.   int
  1986.   doidtrap() {
  1987.       register struct trap *trap;
  1988. ***************
  1989. *** 180,186 ****
  1990.               if(u.dz)
  1991.               if((u.dz < 0) != (is_maze_lev && trap->ttyp == TRAPDOOR))
  1992.                   continue;
  1993. !             pline("That is a%s.",traps[ Hallucination ? rn2(TRAPNUM-3)+2 :
  1994.               trap->ttyp]);
  1995.               return 0;
  1996.           }
  1997. --- 195,201 ----
  1998.               if(u.dz)
  1999.               if((u.dz < 0) != (is_maze_lev && trap->ttyp == TRAPDOOR))
  2000.                   continue;
  2001. !             pline("That is a%s.",traps[ Hallucination ? rn2(TRAPNUM-3)+3 :
  2002.               trap->ttyp]);
  2003.               return 0;
  2004.           }
  2005. ***************
  2006. *** 188,193 ****
  2007. --- 203,211 ----
  2008.       return 0;
  2009.   }
  2010.   
  2011. + #endif /* OVLB */
  2012. + #ifdef OVL0
  2013.   void
  2014.   wakeup(mtmp)
  2015.   register struct monst *mtmp;
  2016. ***************
  2017. *** 198,203 ****
  2018. --- 216,224 ----
  2019.       if(mtmp->mimic) seemimic(mtmp);
  2020.   }
  2021.   
  2022. + #endif /* OVL0 */
  2023. + #ifdef OVLB
  2024.   /* NOTE: we must check if(mtmp->mimic) before calling this routine */
  2025.   void
  2026.   seemimic(mtmp)
  2027. ***************
  2028. *** 204,210 ****
  2029. --- 225,234 ----
  2030.   register struct monst *mtmp;
  2031.   {
  2032.       mtmp->mimic = 0;
  2033. +     mtmp->m_ap_type = M_AP_NOTHING;
  2034.       mtmp->mappearance = 0;
  2035.       unpmon(mtmp);
  2036.       pmon(mtmp);
  2037.   }
  2038. + #endif /* OVLB */
  2039.  
  2040.