diff --git a/dat/.gitignore b/dat/.gitignore index 88e516283..1784229ab 100644 --- a/dat/.gitignore +++ b/dat/.gitignore @@ -5,6 +5,9 @@ rip.xpm pet_mark.xbm quest.dat rumors +bogusmon +engrave +epitaph x11tiles *.lev spec_levs diff --git a/dat/bogusmon.txt b/dat/bogusmon.txt new file mode 100644 index 000000000..2ec3e7fe7 --- /dev/null +++ b/dat/bogusmon.txt @@ -0,0 +1,481 @@ +# Hallucinatory monsters +# +# +# prefix codes: +# dash - female, personal name +# underscore _ female, general name +# plus + male, personal name +# vertical bar | male, general name +# equals = gender not specified, personal name + +# misc. +jumbo shrimp +giant pigmy +gnu +killer penguin +giant cockroach +giant slug +maggot +pterodactyl +tyrannosaurus rex +basilisk +beholder +nightmare +efreeti +marid +rot grub +bookworm +master lichen +shadow +hologram +jester +attorney +sleazoid +killer tomato +amazon +robot +battlemech +rhinovirus +harpy +lion-dog +rat-ant +Y2K bug +angry mariachi +arch-pedant +bluebird of happiness +cardboard golem +duct tape golem +diagonally moving grid bug +evil overlord +newsgroup troll +ninja pirate zombie robot +octarine dragon +gonzo journalist +lag monster +loan shark +possessed waffle iron +poultrygeist +stuffed raccoon puppet +viking +wee green blobbie +wereplatypus +hag of bolding +blancmange +raging nerd +spelling bee +land octopus +frog prince +pigasus +_Semigorgon +conventioneer +large microbat +small megabat +uberhulk +tofurkey ++Dudley + +# Quendor (Zork, &c.) +grue +Christmas-tree monster +luck sucker +paskald +brogmoid +dornbeast + +# Moria +Ancient Multi-Hued Dragon ++Evil Iggy + +# Rogue V5 http://rogue.rogueforge.net/vade-mecum/ +rattlesnake +ice monster +phantom +quagga +aquator +griffin +emu +kestrel +xeroc +venus flytrap + +# Wizardry +creeping coins + +# Greek legend +hydra +siren + +# Monty Python +killer bunny + +# The Princess Bride +rodent of unusual size + +# Wallace & Gromit +were-rabbit + +# "Only you can prevent forest fires! ++Smokey Bear + +# Discworld +Luggage + +# Lord of the Rings +Ent + +# Xanth +tangle tree +nickelpede +wiggle + +# Lewis Carroll +white rabbit +snark + +# Dr. Dolittle +pushmi-pullyu + +# The Smurfs +smurf + +# Star Trek +tribble +Klingon +Borg + +# Star Wars +Ewok + +# Tonari no Totoro +Totoro + +# Nausicaa +ohmu + +# Sailor Moon +youma + +# Pokemon (Meowth) +nyaasu + +# monster movies +-Godzilla ++King Kong + +# old L of SH +earthquake beast + +# Robotech +Invid + +# The Terminator +Terminator + +# Bubblegum Crisis +boomer + +# Dr. Who ("Exterminate!") +Dalek + +# HGttG +microscopic space fleet +Ravenous Bugblatter Beast of Traal + +# TMNT +teenage mutant ninja turtle + +# Usagi Yojimbo +samurai rabbit + +# Cerebus +aardvark + +# Little Shop of Horrors +=Audrey II + +# 50's rock 'n' roll +witch doctor +one-eyed one-horned flying purple people eater + +# saccharine kiddy TV ++Barney the dinosaur + +# Angband ++Morgoth + +# Babylon 5 +Vorlon + +# King Arthur +questing beast + +# Movie +Predator + +# common pest +mother-in-law + +# Actual creatures +praying mantis +beluga whale +chicken +coelacanth +star-nosed mole +lungfish +slow loris +sea cucumber +tapeworm +liger +velociraptor +corpulent porpoise + +# european cryptids +wolpertinger +elwedritsche +skvader ++Nessie +tatzelwurm +dahu + +# fictitious beasts +dropbear +wild haggis +jackalope +flying pig +hippocampus +hippogriff +kelpie + +# Unusually animate body parts +bouncing eye +floating nose +wandering eye + +# Computerese +buffer overflow +dangling pointer +walking disk drive +floating point +regex engine +netsplit +wiki +peer +COBOL + +# bugs +bohrbug +mandelbug +schroedinbug +heisenbug + +# DooM +cacodemon +scrag + +# MST3K ++Crow T. Robot + +# Items and stuff +chess pawn +chocolate pudding +ooblecks +terracotta warrior +hearse +roomba +miniature blimp +dust speck + +# DnD monster +gazebo + +# SciFi elements +gray goo +magnetic monopole +first category perpetual motion device + +# Ultima ++Lord British + +# They Might Be Giants +particle man + +# Robot Finds Kitten +kitten prospecting robot + +# Typography +guillemet +solidus +obelus + +# Their actual character +apostrophe golem +voluptuous ampersand + +# Web comics and animation ++Bob the angry flower ++Strong Bad ++Magical Trevor + +# KoL +one-winged dewinged stab-bat + +# deities +Invisible Pink Unicorn +Flying Spaghetti Monster + +# Monkey Island +three-headed monkey ++El Pollo Diablo + +# modern folklore +little green man + +# Portal +weighted Companion Cube + +# /b/ +/b/tard + +# South Park +manbearpig + +# internet memes +bonsai-kitten +tie-thulu ++Domo-kun +looooooooooooong cat +nyan cat + +# the Internet is made for cat pix +ceiling cat +basement cat +monorail cat + +# POWDER +tridude + +# Radomir Dopieralski +orcus cosmicus + +# Angband +yeek +quylthulg +Greater Hell Beast + +# Souljazz ++Vendor of Yizard + +# Dungeon Crawl Stone Soup ++Sigmund +lernaean hydra ++Ijyb ++Gloorx Vloq ++Blork the orc + +# Wil Wheaton, John Scalzi +unicorn pegasus kitten + +# Minecraft +enderman + +# Pun +wight supremacist + +# Starcraft 2 +zergling + +# Feelings +existential angst +figment of your imagination +flash of insight + +# Fish +ghoti + +# Roald Dahl +vermicious knid + +# Carcassonne +meeple + +# The Wombles +womble + +# Fraggle Rock +fraggle + +# soundex and typos of monsters +gloating eye +flush golem +martyr orc +mortar orc +acid blog +acute blob +aria elemental +aliasing priest +aligned parasite +aligned parquet +aligned proctor +baby balky dragon +baby blues dragon +baby caricature +baby crochet +baby grainy dragon +baby bong worm +baby long word +baby parable worm +barfed devil +beer wight +boor wight +brawny mold +rave spider +clue golem +bust vortex +errata elemental +elastic eel +electrocardiogram eel +fir elemental +tire elemental +flamingo sphere +fallacy golem +frizzed centaur +forest centerfold +fierceness sphere +frosted giant +geriatric snake +gnat ant +giant bath +grant beetle +grind bug +giant mango +glossy golem +gnome laureate +gnome dummy +gooier ooze +green slide +guardian nacho +hell hound pun +high purist +hairnet devil +ice trowel +killer beet +feather golem +lounge worm +mountain lymph +pager golem +pie fiend +prophylactic worm +sock mole +rogue piercer +seesawing sphere +simile mimic +moldier ant +stain vortex +scone giant +umbrella hulk +vampire mace +verbal jabberwock +water lemon +water melon +winged grizzly +yellow wight diff --git a/dat/engrave.txt b/dat/engrave.txt new file mode 100644 index 000000000..6390c3ee1 --- /dev/null +++ b/dat/engrave.txt @@ -0,0 +1,82 @@ +# Random engravings on the floor +# +Elbereth +# trap engravings +Vlad was here +ad aerarium + +# take-offs and other famous engravings +Owlbreath +Galadriel +Kilroy was here + +# Journey to the Center of the Earth +A.S. -> +<- A.S. +# Adventure +You won't get it up the steps +# Inferno +Lasciate ogni speranza o voi ch'entrate. +# Prisoner +Well Come +# So Long... +We apologize for the inconvenience. +# Thriller +See you next Wednesday +# Smokey Stover +notary sojak + +For a good time call 8?7-5309 +# Various zoos around the world +Please don't feed the animals. +# A palindrome +Madam, in Eden, I'm Adam. +# Siskel & Ebert +Two thumbs up! +# The First C Program +Hello, World! +^?MAIL +# AOL +You've got mail! +^. +# Clueless +As if! +# 200x incarnation of Dr.Who +BAD WOLF + +# Gang tag +Arooo! Werewolves of Yendor! + +# Strategy and pun +Dig for Victory here + +# Pompeii +Gaius Julius Primigenius was here. Why are you late? + +# Helpful guiding +Don't go this way +Go left ---> +<--- Go right +X marks the spot +X <--- You are here. +Here be dragons +Save now, and do your homework! +There was a hole here. It's gone now. +The Vibrating Square +This is a pit! +This is not the dungeon you are looking for. +Watch out, there's a gnome with a wand of death behind that door! + +# Misc fun +This square deliberately left blank. + +# Viking graffiti +Haermund Hardaxe carved these runes + +# Advertising +Need a light? Come visit the Minetown branch of Izchak's Lighting Store! +Snakes on the Astral Plane - Soon in a dungeon near you +You are the one millionth visitor to this place! Please wait 200 turns for your wand of wishing. + +# DnD +Warning, Exploding runes! diff --git a/dat/epitaph.txt b/dat/epitaph.txt new file mode 100644 index 000000000..58bb62228 --- /dev/null +++ b/dat/epitaph.txt @@ -0,0 +1,396 @@ +# Epitaphs for random headstones +# +# +Rest in peace +R.I.P. +Rest In Pieces +Note -- there are NO valuable items in this grave +1994-1995. The Longest-Lived Hacker Ever +The Grave of the Unknown Hacker +We weren't sure who this was, but we buried him here anyway +Sparky -- he was a very good dog +Beware of Electric Third Rail +Made in Taiwan +Og friend. Og good dude. Og died. Og now food +Beetlejuice Beetlejuice Beetlejuice +Look out below! +Please don't dig me up. I'm perfectly happy down here. -- Resident +Postman, please note forwarding address: Gehennom, Asmodeus's Fortress, fifth lemure on the left +Mary had a little lamb/Its fleece was white as snow/When Mary was in trouble/The lamb was first to go +Be careful, or this could happen to you! +Soon you'll join this fellow in hell! -- the Wizard of Yendor +Caution! This grave contains toxic waste +Sum quod eris +Here lies an Atheist, all dressed up and no place to go +Here lies Ezekiel, age 102. The good die young. +Here lies my wife: Here let her lie! Now she's at rest and so am I. +Here lies Johnny Yeast. Pardon me for not rising. +He always lied while on the earth and now he's lying in it +I made an ash of myself +Soon ripe. Soon rotten. Soon gone. But not forgotten. +Here lies the body of Jonathan Blake. Stepped on the gas instead of the brake. +Go away! +Alas fair Death, 'twas missed in life - some peace and quiet from my wife +Applaud, my friends, the comedy is finished. +At last... a nice long sleep. +Audi Partem Alteram +Basil, assaulted by bears +Burninated +Confusion will be my epitaph +Do not open until Christmas +Don't be daft, they couldn't hit an elephant at this dist- +Don't forget to stop and smell the roses +Don't let this happen to you! +Dulce et decorum est pro patria mori +Et in Arcadia ego +Fatty and skinny went to bed. Fatty rolled over and skinny was dead. Skinny Smith 1983-2000. +Finally I am becoming stupider no more +Follow me to hell +...for famous men have the whole earth as their memorial +Game over, man. Game over. +Go away! I'm trying to take a nap in here! Bloody adventurers... +Gone fishin' +Good night, sweet prince: And flights of angels sing thee to thy rest! +Go Team Ant! +He farmed his way here +Here lies a programmer. Killed by a fatal error. +Here lies Bob - decided to try an acid blob +Here lies Dudley, killed by another %&#@#& newt. +Here lies Gregg, choked on an egg +Here lies Lies. It's True +Here lies The Lady's maid, died of a Vorpal Blade +Here lies the left foot of Jack, killed by a land mine. Let us know if you find any more of him +He waited too long +I'd rather be sailing +If a man's deeds do not outlive him, of what value is a mark in stone? +I'm gonna make it! +I took both pills! +I will survive! +Killed by a black dragon -- This grave is empty +Let me out of here! +Lookin' good, Medusa. +Mrs. Smith, choked on an apple. She left behind grieving husband, daughter, and granddaughter. +Nobody believed her when she said her feet were killing her +No! I don't want to see my damn conduct! +One corpse, sans head +On the whole, I'd rather be in Minetown +On vacation +Oops. +Out to Lunch +SOLD +Someone set us up the bomb! +Take my stuff, I don't need it anymore +Taking a year dead for tax reasons +The reports of my demise are completely accurate +(This space for sale) +This was actually just a pit, but since there was a corpse, we filled it +This way to the crypt +Tu quoque, Brute? +VACANCY +Welcome! +Wish you were here! +Yea, it got me too +You should see the other guy +...and they made me engrave my own headstone too! +...but the blood has stopped pumping and I am left to decay... + +A masochist is never satisfied. +Ach, 'twas a wee monster in the loch +Adapt. Enjoy. Survive. +Adventure, hah! Excitement, hah! +After all, what are friends for... +After this, nothing will shock me +After three days, fish and guests stink +Age and treachery will always overcome youth and skill +Ageing is not so bad. The real killer is when you stop. +Ain't I a stinker? +Algernon +All else failed... +All hail RNG +All right, we'll call it a draw! +All's well that end well +Alone at last! +Always attack a floating eye from behind! +Am I having fun yet? +And I can still crawl, I'm not dead yet! +And all I wanted was a free lunch +And all of the signs were right there on your face +And don't give me that innocent look either! +And everyone died. Boo hoo hoo. +And here I go again... +And nobody cares until somebody famous dies... +And so it ends? +And so... it begins. +And sometimes the bear eats you. +And then 'e nailed me 'ead to the floor! +And they said it couldn't be done! +And what do I look like? The living? +And yes, it was ALL his fault! +And you said it was pretty here... +Another lost soul +Any day above ground is a good day! +Any more of this and I'll die of a stroke before I'm 30. +Anybody seen my head? +Anyone for deathmatch? +Anything for a change. +Anything that kills you makes you ... well, dead +Anything worth doing is worth overdoing. +Are unicorns supposedly peaceful if you're a virgin? Hah! +Are we all being disintegrated, or is it just me? +At least I'm good at something +Attempted suicide +Auri sacra fames +Auribus teneo lupum +Be prepared +Beauty survives +Been Here. Now Gone. Had a Good Time. +Been through Hell, eh? What did you bring me? +Beg your pardon, didn't recognize you, I've changed a lot. +Being dead builds character +Beloved daughter, a treasure, buried here. +Best friends come and go... Mine just die. +Better be dead than a fat slave +Better luck next time +Beware of Discordians bearing answers +Beware the ... +Bloody Hell... +Bloody barbarians! +Blown upward out of sight: He sought the leak by candlelight +Brains... Brains... Fresh human brains... +Buried the cat. Took an hour. Damn thing kept fighting. +But I disarmed the trap! +CONNECT 1964 - NO CARRIER 1994 +Call me if you need my phone number! +Can YOU fly? +Can you believe that thing is STILL moving? +Can you come up with some better ending for this? +Can you feel anything when I do this? +Can you give me mouth to mouth, you just took my breath away. +Can't I just have a LITTLE peril? +Can't eat, can't sleep, had to bury the husband here. +Can't you hit me?! +Chaos, panic and disorder. My work here is done. +Check enclosed. +Check this out! It's my brain! +Chivalry is only reasonably dead +Coffin for sale. Lifetime guarantee. +Come Monday, I'll be all right. +Come and see the violence inherent in the system +Come back here! I'll bite your bloody knees off! +Commodore Business Machines, Inc. Died for our sins. +Complain to one who can help you +Confess my sins to god? Which one? +Confusion will be my epitaph +Cooties? Ain't no cooties on me! +Could somebody get this noose off me? +Could you check again? My name MUST be there. +Could you please take a breath mint? +Couldn't I be sedated for this? +Courage is looking at your setbacks with serenity +Cover me, I'm going in! +Crash course in brain surgery +Cross my fingers for me. +Curse god and die +Cut to fit +De'Ath +Dead Again? Pardon me for not getting it right the first time! +Dead and loving every moment! +Dear wife of mine. Died of a broken heart, after I took it out of her. +Don't tread on me! +Dragon? What dragon? +Drawn and quartered +Either I'm dead or my watch has stopped. +Eliza -- Was I really alive, or did I just think I was? +Elvis +Enter not into the path of the wicked +Eris? I don't need Eris +Eternal Damnation, Come and stay a long while! +Even The Dead pay taxes (and they aren't Grateful). +Even a tomb stone will say good things when you're down! +Ever notice that live is evil backwards? +Every day is starting to look like Monday +Every day, in every way, I am getting better and better. +Every survival kit should include a sense of humor +Evil I did dwell; lewd did I live +Ex post fucto +Excellent day to have a rotten day. +Excuse me for not standing up. +Experience isn't everything. First, You've got to survive +First shalt thou pull out the Holy Pin +For a Breath, I Tarry... +For recreational use only. +For sale: One soul, slightly used. Asking for 3 wishes. +For some moments in life, there are no words. +Forget Disney World, I'm going to Hell! +Forget about the dog, Beware of my wife. +Funeral - Real fun. +Gawd, it's depressing in here, isn't it? +Genuine Exploding Gravestone. (c)Acme Gravestones Inc. +Get back here! I'm not finished yet... +Go ahead, I dare you to! +Go ahead, it's either you or him. +Goldilocks -- This casket is just right +Gone But Not Forgotten +Gone Underground For Good +Gone away owin' more than he could pay. +Gone, but not forgiven +Got a life. Didn't know what to do with it. +Grave? But I was cremated! +Greetings from Hell - Wish you were here. +HELP! It's dark in here... Oh, my eyes are closed - sorry +Ha! I NEVER pay income tax! +Have you come to raise the dead? +Having a good time can be deadly. +Having a great time. Where am I exactly?? +He died of the flux. +He died today... May we rest in peace! +He got the upside, I got the downside. +He lost his face when he was beheaded. +He missed me first. +He's not dead, he just smells that way. +Help! I've fallen and I can't get up! +Help, I can't wake up! +Here lies Pinocchio +Here lies the body of John Round. Lost at sea and never found. +Here there be dragons +Hey, I didn't write this stuff! +Hodie mihi, cras tibi +Hold my calls +Home Sweet Hell +Humpty Dumpty, a Bad Egg. He was pushed off the wall. +I KNEW this would happen if I lived long enough. +I TOLD you I was sick! +I ain't broke but I am badly bent. +I ain't old. I'm chronologically advantaged. +I am NOT a vampire. I just like to bite..nibble, really! +I am here. Wish you were fine. +I am not dead yet, but watch for further reports. +I believe them bones are me. +I broke his brain. +I can feel it. My mind. It's going. I can feel it. +I can't go to Hell. They're afraid I'm gonna take over! +I can't go to hell, they don't want me. +I didn't believe in reincarnation the last time, either. +I didn't mean it when I said 'Bite me' +I died laughing +I disbelieved in reincarnation in my last life, too. +I hacked myself to death +I have all the time in the world +I knew I'd find a use for this gravestone! +I know my mind. And it's around here someplace. +I lied! I'll never be alright! +I like it better in the dark. +I like to be here when I can. +I may rise but I refuse to shine. +I never get any either. +I said hit HIM with the fireball, not me! +I told you I would never say goodbye. +I used to be amusing. Now I'm just disgusting. +I used up all my sick days, so now I'm calling in dead. +I was killed by +I was somebody. Who, is no business of yours. +I will not go quietly. +I'd give you a piece of my mind... but I can't find it. +I'd rather be breathing +I'll be back! +I'll be mellow when I'm dead. For now, let's PARTY! +I'm doing this only for tax purposes. +I'm not afraid of Death! What's he gonna do? Kill me? +I'm not getting enough money, so I'm not going to engrave anything useful here. +I'm not saying anything. +I'm weeth stupeed ---> +If you thought you had problems... +Ignorance kills daily. +Ignore me... I'm just here for my looks! +Ilene Toofar -- Fell off a cliff +Is that all? +Is there life before Death? +Is this a joke, or a grave matter? +It happens sometimes. People just explode. +It must be Thursday. I never could get the hang of Thursdays. +It wasn't a fair fight +It wasn't so easy. +It's Loot, Pillage and THEN Burn... +Just doing my job here +Killed by diarrhea of mouth and constipation of brain. +Let her RIP +Let it be; I am dead. +Let's play Hide the Corpse +Life is NOT a dream +Madge Ination -- It wasn't all in my head +Meet me in Heaven +Move on, there's nothing to see here. +Mr. Flintstone -- Yabba-dabba-done +My heart is not in this +No one ever died from it +No, you want room 12A, next door. +Nope. No trap on that chest. I swear. +Not again! +Not every soil can bear all things +Now I have a life +Now I lay thee down to sleep... wanna join me? +OK, here is a question: Where ARE your tanlines? +Obesa Cantavit +Oh! An untimely death. +Oh, by the way, how was my funeral? +Oh, honey..I missed you! She said, and fired again. +Ok, so the light does go off. Now let me out of here. +One stone brain +Ooh! Somebody STOP me! +Oops! +Out for the night. Leave a message. +Ow! Do that again! +Pardon my dust. +Part of me still works. +Please, not in front of those orcs! +Prepare to meet me in Heaven +R2D2 -- Rest, Tin Piece +Relax. Nothing ever happens on the first level. +Res omnia mea culpa est +Rest In Pieces +Rest, rest, perturbed spirit. +Rip Torn +She always said her feet were killing her but nobody believed her. +She died of a chest cold. +So let it be written, so let it be done! +So then I says, How do I know you're the real angel of death? +Some patients insist on dying. +Some people have it dead easy, don't they? +Some things are better left buried. +Sure, trust me, I'm a lawyer... +Thank God I wore my corset, because I think my sides have split. +That is all +The Gods DO have a sense of humor: I'm living proof! +The frog's dead. He Kermitted suicide. +This dungeon is a pushover +This elevator doesn't go to Heaven +This gravestone is shareware. To register, please send me 10 zorkmids +This gravestone provided by The Yendorian Grave Services Inc. +This is not an important part of my life. +This one's on me. +This side up +Tim Burr -- Smashed by a tree +Tone it down a bit, I'm trying to get some rest here. +Virtually Alive +We Will Meet Again. +Weep not, he is at rest +Welcome to Dante's. What level please? +Well, at least they listened to my sermon... +Went to be an angel. +What are you doing over there? +What are you smiling at? +What can you say, Death's got appeal...! +What health care? +What pit? +When the gods want to punish you, they answer your prayers. +Where e'er you be let your wind go free. Keeping it in was the death of me! +Where's my refund? +Will let you know for sure in a day or two... +Wizards are wimps +Worms at work, do not disturb! +Would you mind moving a bit? I'm short of breath down here. +Would you quit being evil over my shoulder? +Ya really had me going baby, but now I'm gone. +Yes Dear, just a few more minutes... +You said it wasn't poisonous! +You set my heart aflame. You gave me heartburn. diff --git a/dat/history b/dat/history index b97c99039..0e15a079c 100644 --- a/dat/history +++ b/dat/history @@ -1,4 +1,4 @@ -NetHack History file for release 3.4 +NetHack History file for release 3.6 Behold, mortal, the origins of NetHack... @@ -120,7 +120,6 @@ publicly available web-site listing all the bugs that had been discovered. Despite that constantly growing bug list, 3.3 proved stable enough to last for more than a year and a half. - The 3.4 development team initially consisted of Michael Allison, Ken Arromdee, David Cohrs, Jessie Collet, Kevin Hugo, Ken Lorber, Dean Luick, Pat Rankin, Mike Stephenson, Janet Walz, and Paul Winner, with Warwick Allison joining @@ -150,7 +149,69 @@ Amiga port of 3.5 after Janne Salmijarvi resurrected it for 3.3.1. Christian `Marvin' Bressler maintained 3.5 for the Atari after he resurrected it for 3.3.1. -There is a NetHack web site maintained by Ken Lorber at http://www.nethack.org/. +The release of NetHack 3.4.3 in December 2003 marked the beginning of a +long release hiatus. 3.4.3 proved to be a remarkably stable version that +provided continued enjoyment by the community for more than a decade. The +devteam slowly and quietly continued to work on the game behind the scenes +during the tenure of 3.4.3. It was during that same period that several new +variants emerged within the NetHack community. Notably sporkhack by +Derek S. Ray, unnethack by Patric Mueller, nitrohack and its successors +originally by Daniel Thaler and then by Alex Smith, and +Dynahack by Tung Nguyen. Some of those variants continue to be developed, +maintained, and enjoyed by the community to this day. + +In September 2014, an interim snapshot of the code under development was +released publicly by other parties. Since that code was a work-in-progress +and had not gone through a period of debugging, it was decided that the +version numbers present on that code snapshot would be retired and never +used in an official NetHack release. An announcement was posted on the +devteam's official nethack.org website to that effect, stating that there +would never be a 3.4.4, 3.5, or 3.5.0 official release version. + +In January 2015, preparation began for the release of NetHack 3.6. + +At the beginning of development for what would eventually get released +as 3.6.0, the development team consisted of Michael Allison, +Warwick Allison, Ken Arromdee, David Cohrs, Jessie Collet, Ken Lorber, +Dean Luick, Pat Rankin, Mike Stephenson, Janet Walz, and Paul Winner. + +Leading up to the release of 3.6.0 in early 2015, new members Sean Hunt, +Pasi Kallinen, and Derek S. Ray joined the NetHack development team. + +3.6.0 - insert apprpriate description of 3.6.0 here + +The development team, as well as Steve VanDevender and Kevin Smolkowski +ensured that NetHack 3.6.0 continued to operate on various Unix flavors +as well as maintaining the X11 interface. + +Ken Lorber, Haoyang Wang, Pat Rankin, and Dean Luick maintained the port +of NetHack 3.6.0 for Mac. + +Michael Allison, Derek S. Ray, Yitzhak Sapir, Alex Kompel, and David Cohrs +maintained the port of NetHack 3.6.0 for Microsoft Windows. + +Jeff Bailey created and maintained a port of NetHack 3.6.0 for Chrome. + +Alex Kompel maintained a port of NetHack 3.6.0 to Windows Phone. ? + +This version of the game is special in a particular way. Near the end of +the development of 3.6, one of the significant inspirations for many of the +humorous and fun features found in the game, author Terry Pratchett, +passed away. This version of the game is dedicated to + + +An official NetHack web site continues to be maintained by Ken Lorber at +http://www.nethack.org/. + +-- +SHOUT-OUTS + +The devteam would like to give a special "shout-out" to thank the generous +people primarily responsible for the public NetHack servers available for +playing the game at nethack.alt.org and devnull.net. In addition to providing +a way for the public to play a game of NetHack from almost anywhere, they +have hosted annual NetHack tournaments for many, many years. + write up something for Robin, M. Drew Streib, Pasi Kallinen - - - - - - - - - - diff --git a/doc/fixes35.0 b/doc/fixes35.0 index 250b09d85..5d9f4707a 100644 --- a/doc/fixes35.0 +++ b/doc/fixes35.0 @@ -1089,6 +1089,7 @@ change command X to twoweapon toggle pressing @ when cursor positioning moves cursor on top of hero pressing # when cursor positioning toggles automatic description of features under the cursor +cursor positioning ignores uninteresting dungeon features Platform- and/or Interface-Specific New Features @@ -1125,6 +1126,7 @@ adopt/adapt/improve the Paranoid_Quit patch; default is paranoid_confirm:pray paranoid_confirm:pray y to confirm #pray; supersedes prayconfirm paranoid_confirm:Remove always pick from inventory for 'R' and 'T' adopt/adapt/improve Dungeon Overview +Aardvark Joe's Extended Logfile Code Cleanup and Reorganization diff --git a/doc/makedefs.6 b/doc/makedefs.6 index 7b850108c..61bd7c741 100644 --- a/doc/makedefs.6 +++ b/doc/makedefs.6 @@ -105,6 +105,15 @@ Generate the file. .br .TP +.B -s +Generate the +.I bogusmon +, +.I engrave +and +.IR epitaph files. +.br +.TP .B -h Generate the .B oracles diff --git a/include/config.h b/include/config.h index 930bd549c..d8c96af14 100644 --- a/include/config.h +++ b/include/config.h @@ -187,6 +187,7 @@ #endif #define LOGFILE "logfile" /* larger file for debugging purposes */ +#define XLOGFILE "xlogfile" /* even larger logfile */ #define NEWS "news" /* the file containing the latest hack news */ #define PANICLOG "paniclog" /* log of panic and impossible events */ diff --git a/include/decl.h b/include/decl.h index 4591226e4..bacff08d9 100644 --- a/include/decl.h +++ b/include/decl.h @@ -67,6 +67,8 @@ E struct dgn_topology { /* special dungeon levels for speed */ xchar d_mines_dnum, d_quest_dnum; d_level d_qstart_level, d_qlocate_level, d_nemesis_level; d_level d_knox_level; + d_level d_mineend_level; + d_level d_sokoend_level; } dungeon_topology; /* macros for accesing the dungeon levels by their old names */ #define oracle_level (dungeon_topology.d_oracle_level) @@ -97,6 +99,8 @@ E struct dgn_topology { /* special dungeon levels for speed */ #define qlocate_level (dungeon_topology.d_qlocate_level) #define nemesis_level (dungeon_topology.d_nemesis_level) #define knox_level (dungeon_topology.d_knox_level) +#define mineend_level (dungeon_topology.d_mineend_level) +#define sokoend_level (dungeon_topology.d_sokoend_level) E NEARDATA stairway dnstair, upstair; /* stairs up and down */ #define xdnstair (dnstair.sx) @@ -240,6 +244,7 @@ E NEARDATA anything zeroany; /* init'd and defined in decl.c */ #include "you.h" E NEARDATA struct you u; E NEARDATA time_t ubirthday; +E NEARDATA struct u_realtime urealtime; #include "onames.h" #ifndef PM_H /* (pm.h has already been included via youprop.h) */ diff --git a/include/dungeon.h b/include/dungeon.h index f2bf75ef6..3607649b0 100644 --- a/include/dungeon.h +++ b/include/dungeon.h @@ -122,6 +122,8 @@ typedef struct branch { #define Is_qlocate(x) (on_level(x, &qlocate_level)) #define Is_nemesis(x) (on_level(x, &nemesis_level)) #define Is_knox(x) (on_level(x, &knox_level)) +#define Is_mineend_level(x) (on_level(x, &mineend_level)) +#define Is_sokoend_level(x) (on_level(x, &sokoend_level)) #define In_sokoban(x) ((x)->dnum == sokoban_dnum) #define Inhell In_hell(&u.uz) /* now gehennom */ diff --git a/include/extern.h b/include/extern.h index d7d1a3d57..f190423bf 100644 --- a/include/extern.h +++ b/include/extern.h @@ -26,6 +26,7 @@ E void NDECL(stop_occupation); E void NDECL(display_gamewindows); E void NDECL(newgame); E void FDECL(welcome, (BOOLEAN_P)); +E time_t NDECL(get_realtime); /* ### apply.c ### */ @@ -386,7 +387,7 @@ E char *FDECL(Adjmonnam, (struct monst *,const char *)); E char *FDECL(Amonnam, (struct monst *)); E char *FDECL(a_monnam, (struct monst *)); E char *FDECL(distant_monnam, (struct monst *,int,char *)); -E const char *NDECL(rndmonnam); +E char *FDECL(rndmonnam, (char *)); E const char *FDECL(hcolor, (const char *)); E const char *NDECL(rndcolor); E const char *NDECL(roguename); @@ -812,6 +813,7 @@ E void FDECL(copynchars, (char *,const char *,int)); E char FDECL(chrcasecpy, (int,int)); E char *FDECL(strcasecpy, (char *,const char *)); E char *FDECL(s_suffix, (const char *)); +E char *FDECL(ing_suffix, (const char *)); E char *FDECL(xcrypt, (const char *,char *)); E boolean FDECL(onlyspace, (const char *)); E char *FDECL(tabexpand, (char *)); @@ -1174,7 +1176,7 @@ E struct obj *FDECL(mkobj_at, (CHAR_P,int,int,BOOLEAN_P)); E struct obj *FDECL(mksobj_at, (int,int,int,BOOLEAN_P,BOOLEAN_P)); E struct obj *FDECL(mkobj, (CHAR_P,BOOLEAN_P)); E int NDECL(rndmonnum); -E boolean FDECL(bogon_is_pname, (const char *)); +E boolean FDECL(bogon_is_pname, (CHAR_P)); E struct obj *FDECL(splitobj, (struct obj *,long)); E void FDECL(replace_object, (struct obj *,struct obj *)); E void FDECL(bill_dummy_object, (struct obj *)); @@ -1931,6 +1933,7 @@ E const char *NDECL(Goodbye); /* ### rumors.c ### */ E char *FDECL(getrumor, (int,char *, BOOLEAN_P)); +E char *FDECL(get_rnd_text, (const char *, char *)); E void FDECL(outrumor, (int,int)); E void FDECL(outoracle, (BOOLEAN_P, BOOLEAN_P)); E void FDECL(save_oracles, (int,int)); diff --git a/include/global.h b/include/global.h index 6179409bb..a67066d64 100644 --- a/include/global.h +++ b/include/global.h @@ -30,6 +30,9 @@ #define OPTIONFILE "opthelp" /* file explaining runtime options */ #define OPTIONS_USED "options" /* compile-time options, for #version */ #define SYMBOLS "symbols" /* replacement symbol sets */ +#define EPITAPHFILE "epitaph" /* random epitaphs on graves */ +#define ENGRAVEFILE "engrave" /* random engravings on the floor */ +#define BOGUSMONFILE "bogusmon" /* hallucinatory monsters */ #define LEV_EXT ".lev" /* extension for special level files */ diff --git a/include/obj.h b/include/obj.h index fe43d0878..7ee0c4f91 100644 --- a/include/obj.h +++ b/include/obj.h @@ -107,8 +107,10 @@ struct obj { int corpsenm; /* type of corpse is mons[corpsenm] */ #define leashmon corpsenm /* gets m_id of attached pet */ -#define spestudied corpsenm /* # of times a spellbook has been studied */ #define fromsink corpsenm /* a potion from a sink */ +#define record_achieve_special corpsenm + int usecount; /* overloaded for various things that tally */ +#define spestudied usecount /* # of times a spellbook has been studied */ unsigned oeaten; /* nutrition left in food, if partly eaten */ long age; /* creation date */ long owornmask; diff --git a/include/patchlevel.h b/include/patchlevel.h index 00411a2c2..57bc6412d 100644 --- a/include/patchlevel.h +++ b/include/patchlevel.h @@ -14,10 +14,10 @@ * Incrementing EDITLEVEL can be used to force invalidation of old bones * and save files. */ -#define EDITLEVEL 56 +#define EDITLEVEL 58 #define COPYRIGHT_BANNER_A \ -"NetHack, Copyright 1985-2012" +"NetHack, Copyright 1985-2015" #define COPYRIGHT_BANNER_B \ " By Stichting Mathematisch Centrum and M. Stephenson." /* COPYRIGHT_BANNER_C is generated by makedefs into date.h */ diff --git a/include/you.h b/include/you.h index 0c343b3c4..0fc5c6073 100644 --- a/include/you.h +++ b/include/you.h @@ -53,6 +53,26 @@ struct u_event { Bitfield(ascended,1); /* has offered the Amulet */ }; +struct u_achieve { + Bitfield(amulet,1); /* touched Amulet */ + Bitfield(bell,1); /* touched Bell */ + Bitfield(book,1); /* touched Book */ + Bitfield(menorah,1); /* touched Candelabrum */ + Bitfield(enter_gehennom,1); /* entered Gehennom (or Valley) by any means */ + Bitfield(ascended,1); /* not quite the same as u.uevent.ascended */ + Bitfield(mines_luckstone,1); /* got a luckstone at end of mines */ + Bitfield(finish_sokoban,1); /* obtained the sokoban prize */ + + Bitfield(killed_medusa,1); +}; + +struct u_realtime { + time_t realtime; /* actual playing time up until the last restore */ + time_t restored; /* time the game was started or restored */ + time_t endtime; +}; + + /* KMH, conduct -- * These are voluntary challenges. Each field denotes the number of * times a challenge has been violated. @@ -306,6 +326,7 @@ struct you { /* 1 free bit! */ unsigned udg_cnt; /* how long you have been demigod */ + struct u_achieve uachieve; /* achievements */ struct u_event uevent; /* certain events have happened */ struct u_have uhave; /* you're carrying special objects */ struct u_conduct uconduct; /* KMH, conduct */ diff --git a/src/allmain.c b/src/allmain.c index 2bb1c4240..45c319037 100644 --- a/src/allmain.c +++ b/src/allmain.c @@ -533,6 +533,13 @@ newgame() #endif program_state.something_worth_saving++; /* useful data now exists */ + urealtime.realtime = (time_t)0L; +#if defined(BSD) && !defined(POSIX_TYPES) + (void) time((long *)&urealtime.restored); +#else + (void) time(&urealtime.restored); +#endif + /* Success! */ welcome(TRUE); return; diff --git a/src/decl.c b/src/decl.c index 6c83f0f14..d0d29a35f 100644 --- a/src/decl.c +++ b/src/decl.c @@ -136,6 +136,7 @@ NEARDATA struct sysflag sysflags = DUMMY; NEARDATA struct instance_flags iflags = DUMMY; NEARDATA struct you u = DUMMY; NEARDATA time_t ubirthday = DUMMY; +NEARDATA struct u_realtime urealtime = DUMMY; schar lastseentyp[COLNO][ROWNO] = {DUMMY}; /* last seen/touched dungeon typ */ diff --git a/src/do.c b/src/do.c index 41e25a1b0..34635af72 100644 --- a/src/do.c +++ b/src/do.c @@ -1321,6 +1321,7 @@ boolean at_stairs, falling, portal; #endif You_hear("groans and moans everywhere."); } else pline("It is hot here. You smell smoke..."); + u.uachieve.enter_gehennom = 1; } /* in case we've managed to bypass the Valley's stairway down */ if (Inhell && !Is_valley(&u.uz)) u.uevent.gehennom_entered = 1; diff --git a/src/do_name.c b/src/do_name.c index 37daffbc4..0f837c9d4 100644 --- a/src/do_name.c +++ b/src/do_name.c @@ -204,9 +204,25 @@ const char *goal; lo_x = (pass == 0 && ty == lo_y) ? cx + 1 : 1; hi_x = (pass == 1 && ty == hi_y) ? cx : COLNO - 1; for (tx = lo_x; tx <= hi_x; tx++) { - k = levl[tx][ty].glyph; + /* look at dungeon feature, not at user-visible glyph */ + k = back_to_glyph(tx,ty); + /* uninteresting background glyph */ if (glyph_is_cmap(k) && - matching[glyph_to_cmap(k)]) { + (IS_DOOR(levl[tx][ty].typ) || + glyph_to_cmap(k) == S_room || + glyph_to_cmap(k) == S_corr || + glyph_to_cmap(k) == S_litcorr)) { + /* what the hero remembers to be at tx,ty */ + k = glyph_at(tx, ty); + } + if (glyph_is_cmap(k) && + matching[glyph_to_cmap(k)] && + levl[tx][ty].seenv && + (!IS_WALL(levl[tx][ty].typ)) && + (levl[tx][ty].typ != SDOOR) && + glyph_to_cmap(k) != S_room && + glyph_to_cmap(k) != S_corr && + glyph_to_cmap(k) != S_litcorr) { cx = tx, cy = ty; if (msg_given) { clear_nhwindow(WIN_MESSAGE); @@ -793,10 +809,10 @@ boolean called; /* Put the actual monster name or type into the buffer now */ /* Be sure to remember whether the buffer starts with a name */ if (do_hallu) { - const char *rname = rndmonnam(); - + char rnamecode; + char *rname = rndmonnam(&rnamecode); Strcat(buf, rname); - name_at_start = bogon_is_pname(rname); + name_at_start = bogon_is_pname(rnamecode); } else if (has_mname(mtmp)) { char *name = MNAME(mtmp); @@ -990,113 +1006,44 @@ char *outbuf; return outbuf; } -/* - * Name prefix codes (same as shknam.c): - * dash - female, personal name - * underscore _ female, general name - * plus + male, personal name - * vertical bar | male, general name - * equals = gender not specified, personal name - */ - -static const char * const bogusmons[] = { - "jumbo shrimp", "giant pigmy", "gnu", "killer penguin", - "giant cockroach", "giant slug", "maggot", "pterodactyl", - "tyrannosaurus rex", "basilisk", "beholder", "nightmare", - "efreeti", "marid", "rot grub", "bookworm", "master lichen", - "shadow", "hologram", "jester", "attorney", "sleazoid", - "killer tomato", "amazon", "robot", "battlemech", - "rhinovirus", "harpy", "lion-dog", "rat-ant", "Y2K bug", - /* misc. */ - "grue", "Christmas-tree monster", "luck sucker", "paskald", - "brogmoid", "dornbeast", /* Quendor (Zork, &c.) */ - "Ancient Multi-Hued Dragon", "+Evil Iggy", - /* Moria */ - "emu", "kestrel", "xeroc", "venus flytrap", - /* Rogue */ - "creeping coins", /* Wizardry */ - "hydra", "siren", /* Greek legend */ - "killer bunny", /* Monty Python */ - "rodent of unusual size", /* The Princess Bride */ - "were-rabbit", /* Wallace & Gromit */ - "+Smokey Bear", /* "Only you can prevent forest fires!" */ - "Luggage", /* Discworld */ - "Ent", /* Lord of the Rings */ - "tangle tree", "nickelpede", "wiggle", /* Xanth */ - "white rabbit", "snark", /* Lewis Carroll */ - "pushmi-pullyu", /* Dr. Dolittle */ - "smurf", /* The Smurfs */ - "tribble", "Klingon", "Borg", /* Star Trek */ - "Ewok", /* Star Wars */ - "Totoro", /* Tonari no Totoro */ - "ohmu", /* Nausicaa */ - "youma", /* Sailor Moon */ - "nyaasu", /* Pokemon (Meowth) */ - "-Godzilla", "+King Kong", /* monster movies */ - "earthquake beast", /* old L of SH */ - "Invid", /* Robotech */ - "Terminator", /* The Terminator */ - "boomer", /* Bubblegum Crisis */ - "Dalek", /* Dr. Who ("Exterminate!") */ - "microscopic space fleet", "Ravenous Bugblatter Beast of Traal", - /* HGttG */ - "teenage mutant ninja turtle", /* TMNT */ - "samurai rabbit", /* Usagi Yojimbo */ - "aardvark", /* Cerebus */ - "=Audrey II", /* Little Shop of Horrors */ - "witch doctor", "one-eyed one-horned flying purple people eater", - /* 50's rock 'n' roll */ - "+Barney the dinosaur", /* saccharine kiddy TV */ - "+Morgoth", /* Angband */ - "Vorlon", /* Babylon 5 */ - "questing beast", /* King Arthur */ - "Predator", /* Movie */ - "mother-in-law" /* common pest */ -}; - - +#define BOGUSMONSIZE 100 /* arbitrary */ /* return a random monster name, for hallucination */ -const char * -rndmonnam() +char * +rndmonnam(code) +char *code; { - const char *mname; + static char buf[BUFSZ]; + char *mname = buf; int name; + if (code) *code = '\0'; + do { - name = rn1(SPECIAL_PM + SIZE(bogusmons) - LOW_PM, LOW_PM); + name = rn1(SPECIAL_PM + BOGUSMONSIZE - LOW_PM, LOW_PM); } while (name < SPECIAL_PM && (type_is_pname(&mons[name]) || (mons[name].geno & G_NOGEN))); if (name >= SPECIAL_PM) { - mname = bogusmons[name - SPECIAL_PM]; + get_rnd_text(BOGUSMONFILE, buf); /* strip prefix if present */ - if (!letter(*mname)) ++mname; + if (!letter(*mname)) { + if (code) *code = *mname; + ++mname; + } } else { - mname = mons[name].mname; + Strcpy(buf, mons[name].mname); } return mname; } +#undef BOGUSMONSIZE /* scan bogusmons to check whether this name is in the list and has a prefix */ boolean -bogon_is_pname(mname) -const char *mname; +bogon_is_pname(code) +char code; { - const char *bname; - int name; - - if (!mname || !*mname) return FALSE; - if (!strncmpi(mname, "the ", 4)) mname += 4; - /* scan the bogusmons[] list; case sensitive here */ - for (name = 0; name < SIZE(bogusmons); name++) { - bname = bogusmons[name]; - /* we can skip all ordinary entries */ - if (letter(*bname)) continue; - /* starts with a classification code; does rest of name match? */ - if (!strcmp(mname, bname + 1)) - return index("-+=", *bname) ? TRUE : FALSE; - } - return FALSE; + if (!code) return FALSE; + return index("-+=", code) ? TRUE : FALSE; } const char * diff --git a/src/do_wear.c b/src/do_wear.c index 9925ceaf0..39d3b6c3f 100644 --- a/src/do_wear.c +++ b/src/do_wear.c @@ -391,7 +391,7 @@ Helmet_on(VOID_ARGS) properties, including levitation; uarmh could get dropped or destroyed here */ uchangealign((u.ualign.type != A_NEUTRAL) ? -u.ualign.type : - rn2(2) ? A_CHAOTIC : A_LAWFUL, 1); + (uarmh->o_id % 2) ? A_CHAOTIC : A_LAWFUL, 1); /* makeknown(uarmh->otyp); -- moved below, after xname() */ /*FALLTHRU*/ case DUNCE_CAP: diff --git a/src/dungeon.c b/src/dungeon.c index ed87652f1..d02f3aec6 100644 --- a/src/dungeon.c +++ b/src/dungeon.c @@ -672,6 +672,8 @@ struct level_map { { "wizard1", &wiz1_level }, { "wizard2", &wiz2_level }, { "wizard3", &wiz3_level }, + { "minend", &mineend_level }, + { "soko1", &sokoend_level }, { X_START, &qstart_level }, { X_LOCATE, &qlocate_level }, { X_GOAL, &nemesis_level }, diff --git a/src/eat.c b/src/eat.c index 983f6bcec..a5b413772 100644 --- a/src/eat.c +++ b/src/eat.c @@ -1252,7 +1252,7 @@ const char *mesg; what = "chicken"; which = 1; /* suppress pluralization */ } else if (Hallucination) { - what = rndmonnam(); + what = rndmonnam(NULL); } else { what = mons[mnum].mname; if (the_unique_pm(&mons[mnum])) which = 2; diff --git a/src/end.c b/src/end.c index 995ef8ec7..7ada39767 100644 --- a/src/end.c +++ b/src/end.c @@ -911,6 +911,7 @@ die: topten figure it out separately and possibly getting different time or even day if player is slow responding to --More-- */ endtime = getnow(); + urealtime.realtime += (endtime - urealtime.restored); /* Sometimes you die on the first move. Life's not fair. * On those rare occasions you get hosed immediately, go out diff --git a/src/engrave.c b/src/engrave.c index ebfcd0829..5a8aa38f3 100644 --- a/src/engrave.c +++ b/src/engrave.c @@ -9,33 +9,6 @@ STATIC_VAR NEARDATA struct engr *head_engr; -/* random engravings */ -static const char *random_mesg[] = { - "Elbereth", - /* trap engravings */ - "Vlad was here", "ad aerarium", - /* take-offs and other famous engravings */ - "Owlbreath", "Galadriel", - "Kilroy was here", - "A.S. ->", "<- A.S.", /* Journey to the Center of the Earth */ - "You won't get it up the steps", /* Adventure */ - "Lasciate ogni speranza o voi ch'entrate.", /* Inferno */ - "Well Come", /* Prisoner */ - "We apologize for the inconvenience.", /* So Long... */ - "See you next Wednesday", /* Thriller */ - "notary sojak", /* Smokey Stover */ - "For a good time call 8?7-5309", - "Please don't feed the animals.", /* Various zoos around the world */ - "Madam, in Eden, I'm Adam.", /* A palindrome */ - "Two thumbs up!", /* Siskel & Ebert */ - "Hello, World!", /* The First C Program */ -#ifdef MAIL - "You've got mail!", /* AOL */ -#endif - "As if!", /* Clueless */ - "BAD WOLF", /* 200x incarnation of Dr.Who */ -}; - char * random_engraving(outbuf) char *outbuf; @@ -44,8 +17,10 @@ char *outbuf; /* a random engraving may come from the "rumors" file, or from the list above */ - if (!rn2(4) || !(rumor = getrumor(0, outbuf, TRUE)) || !*rumor) - Strcpy(outbuf, random_mesg[rn2(SIZE(random_mesg))]); + if (!rn2(4) || !(rumor = getrumor(0, outbuf, TRUE)) || !*rumor) { + char buf[BUFSZ]; + Strcpy(outbuf, get_rnd_text(ENGRAVEFILE, buf)); + } wipeout_text(outbuf, (int)(strlen(outbuf) / 4), 0); return outbuf; @@ -1232,39 +1207,6 @@ struct engr *ep; } -/* Epitaphs for random headstones */ -static const char *epitaphs[] = { - "Rest in peace", - "R.I.P.", - "Rest In Pieces", - "Note -- there are NO valuable items in this grave", - "1994-1995. The Longest-Lived Hacker Ever", - "The Grave of the Unknown Hacker", - "We weren't sure who this was, but we buried him here anyway", - "Sparky -- he was a very good dog", - "Beware of Electric Third Rail", - "Made in Taiwan", - "Og friend. Og good dude. Og died. Og now food", - "Beetlejuice Beetlejuice Beetlejuice", - "Look out below!", - "Please don't dig me up. I'm perfectly happy down here. -- Resident", - "Postman, please note forwarding address: Gehennom, Asmodeus's Fortress, fifth lemure on the left", - "Mary had a little lamb/Its fleece was white as snow/When Mary was in trouble/The lamb was first to go", - "Be careful, or this could happen to you!", - "Soon you'll join this fellow in hell! -- the Wizard of Yendor", - "Caution! This grave contains toxic waste", - "Sum quod eris", - "Here lies an Atheist, all dressed up and no place to go", - "Here lies Ezekiel, age 102. The good die young.", - "Here lies my wife: Here let her lie! Now she's at rest and so am I.", - "Here lies Johnny Yeast. Pardon me for not rising.", - "He always lied while on the earth and now he's lying in it", - "I made an ash of myself", - "Soon ripe. Soon rotten. Soon gone. But not forgotten.", - "Here lies the body of Jonathan Blake. Stepped on the gas instead of the brake.", - "Go away!" -}; - /* Create a headstone at the given location. * The caller is responsible for newsym(x, y). */ @@ -1280,9 +1222,12 @@ const char *str; levl[x][y].typ = GRAVE; /* Engrave the headstone */ - if (!str) str = epitaphs[rn2(SIZE(epitaphs))]; del_engr_at(x, y); - make_engr_at(x, y, str, 0L, HEADSTONE); + if (str) make_engr_at(x, y, str, 0L, HEADSTONE); + else { + char buf[BUFSZ]; + make_engr_at(x, y, get_rnd_text(EPITAPHFILE, buf), 0L, HEADSTONE); + } return; } diff --git a/src/explode.c b/src/explode.c index 65dbe82a5..905b7b94b 100644 --- a/src/explode.c +++ b/src/explode.c @@ -283,7 +283,7 @@ int expltype; so avoid any which begins with a capital letter) */ do { Sprintf(hallu_buf, "%s explosion", - s_suffix(rndmonnam())); + s_suffix(rndmonnam(NULL))); } while (*hallu_buf != lowc(*hallu_buf)); str = hallu_buf; } @@ -365,7 +365,7 @@ int expltype; if (do_hallu) { /* (see explanation above) */ do { Sprintf(hallu_buf, "%s explosion", - s_suffix(rndmonnam())); + s_suffix(rndmonnam(NULL))); } while (*hallu_buf != lowc(*hallu_buf)); str = hallu_buf; } diff --git a/src/fountain.c b/src/fountain.c index e87748e0a..88fb6e2a4 100644 --- a/src/fountain.c +++ b/src/fountain.c @@ -39,7 +39,7 @@ dowatersnakes() /* Fountain of snakes! */ if (!(mvitals[PM_WATER_MOCCASIN].mvflags & G_GONE)) { if (!Blind) pline("An endless stream of %s pours forth!", - Hallucination ? makeplural(rndmonnam()) : "snakes"); + Hallucination ? makeplural(rndmonnam(NULL)) : "snakes"); else You_hear("%s hissing!", something); while(num-- > 0) diff --git a/src/hacklib.c b/src/hacklib.c index 78f12dea5..4fdbceb80 100644 --- a/src/hacklib.c +++ b/src/hacklib.c @@ -26,6 +26,7 @@ NetHack, except that rounddiv may call panic(). char chrcasecpy (int,int) char * strcasecpy (char *,const char *) char * s_suffix (const char *) + char * ing_suffix (const char *) char * xcrypt (const char *, char *) boolean onlyspace (const char *) char * tabexpand (char *) @@ -235,6 +236,39 @@ s_suffix(s) /* return a name converted to possessive */ return buf; } +char * +ing_suffix(s) + const char *s; +{ + const char *vowel = "aeiouy"; + static char buf[BUFSZ]; + char onoff[10]; + char *p; + Strcpy(buf, s); + p = eos(buf); + onoff[0] = *p = *(p+1) = '\0'; + if ((strlen(buf) > 4) && + (!strcmpi(p-3, " on") || + !strcmpi(p-4, " off") || + !strcmpi(p-5, " with"))) { + p = strrchr(buf, ' '); + Strcpy(onoff, p); + } + if (!index(vowel, *(p-1)) && index(vowel, *(p-2)) && !index(vowel, *(p-3))) { + /* tip -> tipp + ing */ + *p = *(p-1); + *(p+1) = '\0'; + } else if (!strcmpi(p-2, "ie")) { /* vie -> vy + ing */ + *(p-2) = 'y'; + *(p-1) = '\0'; + } else if (*(p-1) == 'e') /* grease -> greas + ing */ + *(p-1) = '\0'; + Strcat(buf, "ing"); + if (onoff[0]) Strcat(buf, onoff); + return buf; +} + + char * xcrypt(str, buf) /* trivial text encryption routine (see makedefs) */ const char *str; diff --git a/src/invent.c b/src/invent.c index 62295915c..12f0ef1b3 100644 --- a/src/invent.c +++ b/src/invent.c @@ -240,15 +240,19 @@ struct obj *obj; } else if (obj->otyp == AMULET_OF_YENDOR) { if (u.uhave.amulet) impossible("already have amulet?"); u.uhave.amulet = 1; + u.uachieve.amulet = 1; } else if (obj->otyp == CANDELABRUM_OF_INVOCATION) { if (u.uhave.menorah) impossible("already have candelabrum?"); u.uhave.menorah = 1; + u.uachieve.menorah = 1; } else if (obj->otyp == BELL_OF_OPENING) { if (u.uhave.bell) impossible("already have silver bell?"); u.uhave.bell = 1; + u.uachieve.bell = 1; } else if (obj->otyp == SPE_BOOK_OF_THE_DEAD) { if (u.uhave.book) impossible("already have the book?"); u.uhave.book = 1; + u.uachieve.book = 1; } else if (obj->oartifact) { if (is_quest_artifact(obj)) { if (u.uhave.questart) @@ -258,6 +262,15 @@ struct obj *obj; } set_artifact_intrinsic(obj, 1, W_ART); } + if(obj->otyp == LUCKSTONE && obj->record_achieve_special) { + u.uachieve.mines_luckstone = 1; + obj->record_achieve_special = 0; + } else if((obj->otyp == AMULET_OF_REFLECTION || + obj->otyp == BAG_OF_HOLDING) && + obj->record_achieve_special) { + u.uachieve.finish_sokoban = 1; + obj->record_achieve_special = 0; + } } /* @@ -959,7 +972,21 @@ register const char *let,*word; return((struct obj *)0); } if(ilet == '-') { - return(allownone ? &zeroobj : (struct obj *) 0); + if (!allownone) { + char *suf = NULL; + strcpy(buf, word); + if ((bp = strstr(buf, " on the ")) != NULL) { /* rub on the stone[s] */ + *bp = '\0'; + suf = (bp + 1); + } + if ((bp = strstr(buf, " or ")) != NULL) { + *bp = '\0'; + bp = (rn2(2) ? buf : (bp + 4)); + } else bp = buf; + You("mime %s something%s%s.", ing_suffix(bp), + suf ? " " : "", suf ? suf : ""); + } + return(allownone ? &zeroobj : (struct obj *) 0); } if(ilet == def_oc_syms[COIN_CLASS].sym) { if (!usegold) { diff --git a/src/mon.c b/src/mon.c index cfe5cddca..c65be0aa7 100644 --- a/src/mon.c +++ b/src/mon.c @@ -1605,6 +1605,8 @@ register struct monst *mtmp; } if(mtmp->iswiz) wizdead(); if(mtmp->data->msound == MS_NEMESIS) nemdead(); + if(mtmp->data == &mons[PM_MEDUSA]) + u.uachieve.killed_medusa = 1; if(glyph_is_invisible(levl[mtmp->mx][mtmp->my].glyph)) unmap_object(mtmp->mx, mtmp->my); m_detach(mtmp, mptr); diff --git a/src/muse.c b/src/muse.c index 855a91887..9ea9c1d14 100644 --- a/src/muse.c +++ b/src/muse.c @@ -88,7 +88,7 @@ struct obj *obj; if (vis) { pline("As %s opens the bottle, an enormous %s emerges!", mon_nam(mon), - Hallucination ? rndmonnam() : (const char *)"ghost"); + Hallucination ? rndmonnam(NULL) : (const char *)"ghost"); pline("%s is frightened to death, and unable to move.", Monnam(mon)); } diff --git a/src/pickup.c b/src/pickup.c index 3eba9874f..1d78dea76 100644 --- a/src/pickup.c +++ b/src/pickup.c @@ -2040,7 +2040,7 @@ struct obj *box; (void) add_to_container(box, deadcat); } pline_The("%s inside the box is dead!", - Hallucination ? rndmonnam() : "housecat"); + Hallucination ? rndmonnam(NULL) : "housecat"); } box->owt = weight(box); return; diff --git a/src/potion.c b/src/potion.c index d4bfcdad3..0af019181 100644 --- a/src/potion.c +++ b/src/potion.c @@ -371,7 +371,7 @@ ghost_from_bottle() return; } pline("As you open the bottle, an enormous %s emerges!", - Hallucination ? rndmonnam() : (const char *)"ghost"); + Hallucination ? rndmonnam(NULL) : (const char *)"ghost"); if(flags.verbose) You("are frightened to death, and unable to move."); nomul(-3); diff --git a/src/pray.c b/src/pray.c index d2b24c00a..ffdee9b49 100644 --- a/src/pray.c +++ b/src/pray.c @@ -1373,6 +1373,7 @@ dosacrifice() done(ESCAPED); } else { /* super big win */ adjalign(10); + u.uachieve.ascended = 1; pline("An invisible choir sings, and you are bathed in radiance..."); godvoice(altaralign, "Congratulations, mortal!"); display_nhwindow(WIN_MESSAGE, FALSE); diff --git a/src/priest.c b/src/priest.c index 1ef7ea286..a28f2b8d4 100644 --- a/src/priest.c +++ b/src/priest.c @@ -284,13 +284,14 @@ char *pname; /* caller-supplied output buffer */ boolean do_hallu = Hallucination, aligned_priest = mon->data == &mons[PM_ALIGNED_PRIEST], high_priest = mon->data == &mons[PM_HIGH_PRIEST]; - const char *what = do_hallu ? rndmonnam() : mon->data->mname; + char whatcode = '\0'; + const char *what = do_hallu ? rndmonnam(&whatcode) : mon->data->mname; if (!mon->ispriest && !mon->isminion) /* should never happen... */ return strcpy(pname, what); /* caller must be confused */ *pname = '\0'; - if (!do_hallu || !bogon_is_pname(what)) Strcat(pname, "the "); + if (!do_hallu || !bogon_is_pname(whatcode)) Strcat(pname, "the "); if (mon->minvis) Strcat(pname, "invisible "); if (mon->isminion && EMIN(mon)->renegade) Strcat(pname, "renegade "); diff --git a/src/restore.c b/src/restore.c index 24a0f777c..4e4502b53 100644 --- a/src/restore.c +++ b/src/restore.c @@ -551,9 +551,20 @@ unsigned int *stuckid, *steedid; amii_setpens(amii_numcolors); /* use colors from save file */ #endif mread(fd, (genericptr_t) &u, sizeof(struct you)); - mread(fd, (genericptr_t) timebuf, 14); - timebuf[14] = '\0'; - ubirthday = time_from_yyyymmddhhmmss(timebuf); + +#define ReadTimebuf(foo) mread(fd, (genericptr_t) timebuf, 14); \ + timebuf[14] = '\0'; \ + foo = time_from_yyyymmddhhmmss(timebuf); + + ReadTimebuf(ubirthday); + ReadTimebuf(urealtime.realtime); + ReadTimebuf(urealtime.restored); +#if defined(BSD) && !defined(POSIX_TYPES) + (void) time((long *)&urealtime.restored); +#else + (void) time(&urealtime.restored); +#endif + set_uasmon(); #ifdef CLIPPING diff --git a/src/rumors.c b/src/rumors.c index 081b81d8d..4bcb5c177 100644 --- a/src/rumors.c +++ b/src/rumors.c @@ -266,6 +266,46 @@ rumor_check() } } + +/* Gets a random line of text from file 'fname', and returns it. */ +char * +get_rnd_text(fname, buf) +const char *fname; +char *buf; +{ + dlb *fh; + + buf[0] = '\0'; + + fh = dlb_fopen(fname, "r"); + + if (fh) { + /* TODO: cache sizetxt, starttxt, endtxt. maybe cache file contents? */ + long sizetxt = 0, starttxt = 0, endtxt = 0, tidbit = 0; + char *endp, line[BUFSZ], xbuf[BUFSZ]; + (void) dlb_fgets(line, sizeof line, fh); /* skip "don't edit" comment */ + + (void) dlb_fseek(fh, 0L, SEEK_CUR); + starttxt = dlb_ftell(fh); + (void) dlb_fseek(fh, 0L, SEEK_END); + endtxt = dlb_ftell(fh); + sizetxt = endtxt - starttxt; + tidbit = Rand() % sizetxt; + + (void) dlb_fseek(fh, starttxt + tidbit, SEEK_SET); + (void) dlb_fgets(line, sizeof line, fh); + if (!dlb_fgets(line, sizeof line, fh)) { + (void) dlb_fseek(fh, starttxt, SEEK_SET); + (void) dlb_fgets(line, sizeof line, fh); + } + if ((endp = index(line, '\n')) != 0) *endp = 0; + Strcat(buf, xcrypt(line, xbuf)); + (void) dlb_fclose(fh); + } else impossible("Can't open file %s!", fname); + return buf; +} + + void outrumor(truth, mechanism) int truth; /* 1=true, -1=false, 0=either */ diff --git a/src/save.c b/src/save.c index 802d560a9..807ecd7dc 100644 --- a/src/save.c +++ b/src/save.c @@ -307,8 +307,11 @@ register int fd, mode; #ifdef SYSFLAGS bwrite(fd, (genericptr_t) &sysflags, sizeof(struct sysflag)); #endif + urealtime.realtime += (getnow() - urealtime.restored); bwrite(fd, (genericptr_t) &u, sizeof(struct you)); bwrite(fd, yyyymmddhhmmss(ubirthday), 14); + bwrite(fd, yyyymmddhhmmss(urealtime.realtime), 14); + bwrite(fd, yyyymmddhhmmss(urealtime.restored), 14); save_killers(fd, mode); /* must come before migrating_objs and migrating_mons are freed */ diff --git a/src/sounds.c b/src/sounds.c index 3b2ee2f56..6204847e8 100644 --- a/src/sounds.c +++ b/src/sounds.c @@ -1006,7 +1006,7 @@ dochat() if (!Blind) { if (Hallucination) { /* if you're hallucinating, you can't tell it's a statue */ - pline_The("%s seems not to notice you.", rndmonnam()); + pline_The("%s seems not to notice you.", rndmonnam(NULL)); } else { pline_The("statue seems not to notice you."); diff --git a/src/sp_lev.c b/src/sp_lev.c index c779d700e..6e42b2c31 100644 --- a/src/sp_lev.c +++ b/src/sp_lev.c @@ -1639,6 +1639,18 @@ struct mkroom *croom; } } + /* Nasty hack here: try to determine if this is the Mines or Sokoban + * "prize" and then set record_achieve_special (maps to corpsenm) + * for the object. That field will later be checked to find out if + * the player obtained the prize. */ + if(otmp->otyp == LUCKSTONE && Is_mineend_level(&u.uz)) { + otmp->record_achieve_special = 1; + } else if((otmp->otyp == AMULET_OF_REFLECTION || + otmp->otyp == BAG_OF_HOLDING) && + Is_sokoend_level(&u.uz)) { + otmp->record_achieve_special = 1; + } + stackobj(otmp); if (o->lit) { diff --git a/src/timeout.c b/src/timeout.c index 481b16ae7..e47d863fb 100644 --- a/src/timeout.c +++ b/src/timeout.c @@ -164,7 +164,7 @@ slime_dialogue() if (!Blind) /* [what if you're already green?] */ pline(buf, hcolor(NH_GREEN)); } else - pline(buf, an(Hallucination ? rndmonnam() : "green slime")); + pline(buf, an(Hallucination ? rndmonnam(NULL) : "green slime")); } else pline1(buf); } diff --git a/src/topten.c b/src/topten.c index db2e6fccb..83fe71737 100644 --- a/src/topten.c +++ b/src/topten.c @@ -65,6 +65,9 @@ STATIC_DCL void FDECL(outentry, (int,struct toptenentry *,BOOLEAN_P)); STATIC_DCL void FDECL(discardexcess, (FILE *)); STATIC_DCL void FDECL(readentry, (FILE *,struct toptenentry *)); STATIC_DCL void FDECL(writeentry, (FILE *,struct toptenentry *)); +STATIC_DCL void FDECL(writexlentry, (FILE*, struct toptenentry *)); +STATIC_DCL long NDECL(encodeconduct); +STATIC_DCL long NDECL(encodeachieve); STATIC_DCL void FDECL(free_ttlist, (struct toptenentry *)); STATIC_DCL int FDECL(classmon, (char *,BOOLEAN_P)); STATIC_DCL int FDECL(score_wanted, @@ -292,6 +295,100 @@ struct toptenentry *tt; #endif } +/* as tab is never used in eg. plname or death, no need to mangle those. */ +STATIC_OVL void +writexlentry(rfile,tt) +FILE *rfile; +struct toptenentry *tt; +{ +#define Fprintf (void)fprintf +#define XLOG_SEP '\t' /* xlogfile field separator. */ + char buf[BUFSZ]; + + Sprintf(buf, "version=%d.%d.%d", + tt->ver_major, tt->ver_minor, tt->patchlevel); + Sprintf(eos(buf), "%cpoints=%ld%cdeathdnum=%d%cdeathlev=%d", + XLOG_SEP, tt->points, + XLOG_SEP, tt->deathdnum, + XLOG_SEP, tt->deathlev); + Sprintf(eos(buf), "%cmaxlvl=%d%chp=%d%cmaxhp=%d", + XLOG_SEP, tt->maxlvl, + XLOG_SEP, tt->hp, + XLOG_SEP, tt->maxhp); + Sprintf(eos(buf), "%cdeaths=%d%cdeathdate=%ld%cbirthdate=%ld%cuid=%d", + XLOG_SEP, tt->deaths, + XLOG_SEP, tt->deathdate, + XLOG_SEP, tt->birthdate, + XLOG_SEP, tt->uid); + Fprintf(rfile, "%s", buf); + Sprintf(buf, "%crole=%s%crace=%s%cgender=%s%calign=%s", + XLOG_SEP, tt->plrole, + XLOG_SEP, tt->plrace, + XLOG_SEP, tt->plgend, + XLOG_SEP, tt->plalign); + Fprintf(rfile, "%s%cname=%s%cdeath=%s", + buf, /* (already includes separator) */ + XLOG_SEP, plname, + XLOG_SEP, tt->death); + Fprintf(rfile, "%cconduct=0x%lx%cturns=%ld%cachieve=0x%lx", + XLOG_SEP, encodeconduct(), + XLOG_SEP, moves, + XLOG_SEP, encodeachieve()); + Fprintf(rfile, "%crealtime=%ld%cstarttime=%ld%cendtime=%ld", + XLOG_SEP, (long)urealtime.realtime, + XLOG_SEP, (long)ubirthday, + XLOG_SEP, (long)urealtime.endtime); + Fprintf(rfile, "%cgender0=%s%calign0=%s", + XLOG_SEP, genders[flags.initgend].filecode, + XLOG_SEP, aligns[1 - u.ualignbase[A_ORIGINAL]].filecode); + Fprintf(rfile, "\n"); +#undef XLOG_SEP +} + +STATIC_OVL long +encodeconduct() +{ + long e = 0L; + + if(!u.uconduct.food) e |= 1L << 0; + if(!u.uconduct.unvegan) e |= 1L << 1; + if(!u.uconduct.unvegetarian) e |= 1L << 2; + if(!u.uconduct.gnostic) e |= 1L << 3; + if(!u.uconduct.weaphit) e |= 1L << 4; + if(!u.uconduct.killer) e |= 1L << 5; + if(!u.uconduct.literate) e |= 1L << 6; + if(!u.uconduct.polypiles) e |= 1L << 7; + if(!u.uconduct.polyselfs) e |= 1L << 8; + if(!u.uconduct.wishes) e |= 1L << 9; + if(!u.uconduct.wisharti) e |= 1L << 10; + if(!num_genocides()) e |= 1L << 11; + + return e; +} + +STATIC_OVL long +encodeachieve() +{ + long r = 0L; + + if(u.uachieve.bell) r |= 1L << 0; + if(u.uachieve.enter_gehennom) r |= 1L << 1; + if(u.uachieve.menorah) r |= 1L << 2; + if(u.uachieve.book) r |= 1L << 3; + if(u.uevent.invoked) r |= 1L << 4; + if(u.uachieve.amulet) r |= 1L << 5; + if(In_endgame(&u.uz)) r |= 1L << 6; + if(Is_astralevel(&u.uz)) r |= 1L << 7; + if(u.uachieve.ascended) r |= 1L << 8; + if(u.uachieve.mines_luckstone) r |= 1L << 9; + if(u.uachieve.finish_sokoban) r |= 1L << 10; + if(u.uachieve.killed_medusa) r |= 1L << 11; + + return r; +} + + + STATIC_OVL void free_ttlist(tt) struct toptenentry *tt; @@ -322,6 +419,9 @@ time_t when; #ifdef LOGFILE FILE *lfile; #endif /* LOGFILE */ +#ifdef XLOGFILE + FILE *xlfile; +#endif /* XLOGFILE */ /* Under DICE 3.0, this crashes the system consistently, apparently due to * corruption of *rfile somewhere. Until I figure this out, just cut out @@ -380,6 +480,7 @@ time_t when; t0->birthdate = yyyymmdd(ubirthday); t0->deathdate = yyyymmdd(when); t0->tt_next = 0; + urealtime.endtime = when; #ifdef UPDATE_RECORD_IN_PLACE t0->fpos = -1L; #endif @@ -395,6 +496,17 @@ time_t when; unlock_file(LOGFILE); } #endif /* LOGFILE */ +#ifdef XLOGFILE + if (lock_file(XLOGFILE, SCOREPREFIX, 10)) { + if(!(xlfile = fopen_datafile(XLOGFILE, "a", SCOREPREFIX))) { + HUP raw_print("Cannot open extended log file!"); + } else { + writexlentry(xlfile, t0); + (void) fclose(xlfile); + } + unlock_file(XLOGFILE); + } +#endif /* XLOGFILE */ if (wizard || discover) { if (how != PANICKED) HUP { diff --git a/src/trap.c b/src/trap.c index 8fa07cbe4..8ad6ddd83 100644 --- a/src/trap.c +++ b/src/trap.c @@ -621,7 +621,7 @@ int *fail_reason; "statue"); pline("%s %s!", upstart(statuename), comes_to_life); } else if (Hallucination) { /* They don't know it's a statue */ - pline_The("%s suddenly seems more animated.", rndmonnam()); + pline_The("%s suddenly seems more animated.", rndmonnam(NULL)); } else if (cause == ANIMATE_SHATTER) { if (cansee(x, y)) Sprintf(statuename, "%s%s", shk_your(tmpbuf, statue), @@ -3145,6 +3145,14 @@ struct obj *obj; erode_obj(obj, NULL, ERODE_CORRODE, EF_GREASE | EF_VERBOSE); } +/* context for water_damage(), managed by water_damage_chain(); + when more than one stack of potions of acid explode while processing + a chain of objects, use alternate phrasing after the first message */ +static struct h2o_ctx { + int dkn_boom, unk_boom; /* track dknown, !dknown separately */ + boolean ctx_valid; +} acid_ctx = { 0, 0, FALSE }; + /* Get an object wet and damage it appropriately. * "ostr", if present, is used instead of the object name in some * messages. @@ -3158,6 +3166,7 @@ const char *ostr; boolean force; { boolean exploded = FALSE; + if (!obj) return ER_NOTHING; if (snuff_lit(obj)) return ER_DAMAGED; @@ -3201,18 +3210,36 @@ boolean force; return ER_DAMAGED; } else if (obj->oclass == POTION_CLASS) { if (obj->otyp == POT_ACID) { - char *bufp, buf[BUFSZ]; - boolean one = (obj->quan == 1L); - boolean update = carried(obj); + char *bufp; + boolean one = (obj->quan == 1L), + update = carried(obj), + exploded = FALSE; - bufp = strcpy(buf, "potion"); - if (!one) bufp = makeplural(bufp); - /* [should we damage player/monster?] */ + if (Blind && !carried(obj)) obj->dknown = 0; + if (acid_ctx.ctx_valid) + exploded = ((obj->dknown ? acid_ctx.dkn_boom + : acid_ctx.unk_boom) > 0); + /* First message is + * "a [potion| potion|potion of acid] explodes" + * depending on obj->dknown (potion has been seen) and + * objects[POT_ACID].oc_name_known (fully discovered), + * or "some {plural version} explode" when relevant. + * Second and subsequent messages for same chain and + * matching dknown status are + * "another [potion| &c] explodes" or plural + * variant. + */ + bufp = simpleonames(obj); pline("%s %s %s!", /* "A potion explodes!" */ !exploded ? (one ? "A" : "Some") : - (one ? "Another" : "More"), + (one ? "Another" : "More"), bufp, vtense(bufp, "explode")); - exploded = TRUE; + if (acid_ctx.ctx_valid) { + if (obj->dknown) + acid_ctx.dkn_boom++; + else + acid_ctx.unk_boom++; + } setnotworn(obj); delobj(obj); if (update) @@ -3244,10 +3271,20 @@ struct obj *obj; boolean here; { struct obj *otmp; + + /* initialize acid context: so far, neither seen (dknown) potions of + acid nor unseen have exploded during this water damage sequence */ + acid_ctx.dkn_boom = acid_ctx.unk_boom = 0; + acid_ctx.ctx_valid = TRUE; + for (; obj; obj = otmp) { otmp = here ? obj->nexthere : obj->nobj; water_damage(obj, NULL, FALSE); } + + /* reset acid context */ + acid_ctx.dkn_boom = acid_ctx.unk_boom = 0; + acid_ctx.ctx_valid = FALSE; } /* diff --git a/src/u_init.c b/src/u_init.c index bfe54671c..79954841c 100644 --- a/src/u_init.c +++ b/src/u_init.c @@ -500,6 +500,7 @@ u_init() (void) memset((genericptr_t)&u, 0, sizeof(u)); u.ustuck = (struct monst *)0; (void) memset((genericptr_t)&ubirthday, 0, sizeof(ubirthday)); + (void) memset((genericptr_t)&urealtime, 0, sizeof(urealtime)); #if 0 /* documentation of more zero values as desirable */ u.usick_cause[0] = 0; diff --git a/src/zap.c b/src/zap.c index 5f39fc30e..3134c8b88 100644 --- a/src/zap.c +++ b/src/zap.c @@ -1799,7 +1799,7 @@ struct obj *obj, *otmp; if (break_statue(obj)) { if (cansee(obj->ox, obj->oy)) { if (Hallucination) - pline_The("%s shatters.", rndmonnam()); + pline_The("%s shatters.", rndmonnam(NULL)); else pline_The("statue shatters."); } else diff --git a/sys/unix/Makefile.dat b/sys/unix/Makefile.dat index ad9cb6e2d..17c543897 100644 --- a/sys/unix/Makefile.dat +++ b/sys/unix/Makefile.dat @@ -9,7 +9,7 @@ NHSROOT=.. # SHELL=E:/GEMINI2/MUPFEL.TTP # UUDECODE=uudecode -VARDAT = data rumors quest.dat oracles options +VARDAT = bogusmon data engrave epitaph rumors quest.dat oracles options all: $(VARDAT) spec_levs quest_levs dungeon @@ -98,6 +98,15 @@ quest.dat: quest.txt ../util/makedefs oracles: oracles.txt ../util/makedefs ../util/makedefs -h +engrave: engrave.txt ../util/makedefs + ../util/makedefs -s + +epitaph: epitaph.txt ../util/makedefs + ../util/makedefs -s + +bogusmon: bogusmon.txt ../util/makedefs + ../util/makedefs -s + # note: 'options' should have already been made when include/date.h was created options: ../util/makedefs ../util/makedefs -v diff --git a/sys/unix/Makefile.top b/sys/unix/Makefile.top index 6d94d6908..77cd28fa1 100644 --- a/sys/unix/Makefile.top +++ b/sys/unix/Makefile.top @@ -56,7 +56,7 @@ VARDIR = $(HACKDIR) # for Gnome # VARDATND = x11tiles pet_mark.xbm rip.xpm mapbg.xpm -VARDATD = data oracles options quest.dat rumors +VARDATD = bogusmon data engrave epitaph oracles options quest.dat rumors VARDAT = $(VARDATD) $(VARDATND) # Some versions of make use the SHELL environment variable as the shell @@ -109,6 +109,15 @@ manpages: data: $(GAME) ( cd dat ; $(MAKE) data ) +engrave: $(GAME) + ( cd dat ; $(MAKE) engrave ) + +bogusmon: $(GAME) + ( cd dat ; $(MAKE) bogusmon ) + +epitaph: $(GAME) + ( cd dat ; $(MAKE) epitaph ) + rumors: $(GAME) ( cd dat ; $(MAKE) rumors ) @@ -264,10 +273,10 @@ install: rootcheck $(GAME) recover $(VARDAT) dungeon spec_levs # set up the game files ( $(MAKE) dofiles ) # set up some additional files - touch $(VARDIR)/perm $(VARDIR)/record $(VARDIR)/logfile - -( cd $(VARDIR) ; $(CHOWN) $(GAMEUID) perm record logfile ; \ - $(CHGRP) $(GAMEGRP) perm record logfile ; \ - chmod $(VARFILEPERM) perm record logfile ) + touch $(VARDIR)/perm $(VARDIR)/record $(VARDIR)/logfile $(VARDIR)/xlogfile + -( cd $(VARDIR) ; $(CHOWN) $(GAMEUID) perm record logfile xlogfile ; \ + $(CHGRP) $(GAMEGRP) perm record logfile xlogfile ; \ + chmod $(VARFILEPERM) perm record logfile xlogfile ) true; $(POSTINSTALL) # and a reminder @echo You may also want to reinstall the man pages via the doc Makefile. diff --git a/sys/winnt/Makefile.msc b/sys/winnt/Makefile.msc index 847aa3797..af68dab73 100644 --- a/sys/winnt/Makefile.msc +++ b/sys/winnt/Makefile.msc @@ -13,8 +13,10 @@ # #============================================================================== # This is used for building two versions of NetHack: +# # A tty port utilizing the Win32 Console I/O subsystem, Console # NetHack; +# # A Win32 native port built on the Windows API, Graphical NetHack or # NetHackW. # @@ -181,43 +183,73 @@ guilibs = $(winlibs) # End of VS2013 and greater stuff #============================================= +# +#============================================= +# Visual Studio versions >= 2013 specific stuff +#============================================= + +!IF "$(TARGET_CPU)" == "" +TARGET_CPU=x86 +!ENDIF + +# Common compiler flags: +# -c - compile without linking +# -W3 - Set warning level to level 3 (-W4 for 64-bit compilations) +# -Zi - generate debugging information +# -Od - disable all optimizations +# -Ox - use maximum optimizations +# -Zd - generate only public symbols and line numbers for debugging +# -GS - enable security checks +# +ccommon=-c -DCRTAPI1=_cdecl -DCRTAPI2=_cdecl -nologo -GS -c +lflags=/INCREMENTAL:NO /NOLOGO + +!IF "$(TARGET_CPU)" == "x86" +cflags = $(ccommon) -D_X86_=1 -DWIN32 -D_WIN32 -W3 +scall = -Gz + +!ELSEIF "$(TARGET_CPU)" == "x64" +cflags = $(ccommon) -D_AMD64_=1 -DWIN64 -D_WIN64 -DWIN32 -D_WIN32 +cflags = $(cflags) -W4 +scall = +!ENDIF + +# declarations for use on Intel x86 systems +!IF "$(TARGET_CPU)" == "x86" +DLLENTRY = @12 +!ENDIF + +# declarations for use on AMD64 systems +!IF "$(TARGET_CPU)" == "x64" +DLLENTRY = +!ENDIF + +# for Windows applications +conlflags = $(lflags) -subsystem:console,$(EXEVER) +guilflags = $(lflags) -subsystem:windows,$(EXEVER) +dlllflags = $(lflags) -entry:_DllMainCRTStartup$(DLLENTRY) -dll + +# basic subsystem specific libraries, less the C Run-Time +baselibs = kernel32.lib $(optlibs) $(winsocklibs) advapi32.lib +winlibs = $(baselibs) user32.lib gdi32.lib comdlg32.lib winspool.lib + +# for Windows applications that use the C Run-Time libraries +conlibs = $(baselibs) +guilibs = $(winlibs) +# +# End of VS2013 and greater stuff +#============================================= + # #========================================== # Exe File Info. #========================================== -# Yacc/Lex ... if you got 'em. # -# If you have yacc and lex programs (or work-alike such as bison -# and flex), comment out the upper two macros and uncomment -# the lower two. -# - -DO_YACC = YACC_MSG -DO_LEX = LEX_MSG -#DO_YACC = YACC_ACT -#DO_LEX = LEX_ACT - -# - Specify your yacc and lex programs (or work-alikes) here. - -#YACC = bison -y -YACC = byacc -#YACC = yacc - -#LEX = lex -LEX = flex - -# -# - Specify your flex skeleton file (if needed). -# - -FLEXSKEL = -#FLEXSKEL = -S../tools/flex.ske - -YTABC = y_tab.c -YTABH = y_tab.h -LEXYYC = lexyy.c - +# For the level compiler bits, +# we just defer to win\win32\dgnstuff.mak +# and win\win32\levstuff.mak +# # # Optional high-quality BSD random number generation routines # (see pcconf.h). Set to nothing if not used. @@ -451,19 +483,20 @@ U = $(UTIL)^\ MAKESRC = $(U)makedefs.c -SPLEVSRC = $(U)lev_yacc.c $(U)lev_$(LEX).c $(U)lev_main.c $(U)panic.c - -DGNCOMPSRC = $(U)dgn_yacc.c $(U)dgn_$(LEX).c $(U)dgn_main.c - MAKEOBJS = $(O)makedefs.o $(O)monst.o $(O)objects.o -SPLEVOBJS = $(O)lev_yacc.o $(O)lev_$(LEX).o $(O)lev_main.o \ +#SPLEVOBJS = $(O)lev_yacc.o $(O)lev_lex.o $(O)lev_main.o \ +# $(O)alloc.o $(O)decl.o $(O)drawing.o \ +# $(O)monst.o $(O)objects.o $(O)panic.o + +SPLEVOBJS = $(O)lev_yacc.o $(O)lev_lex.o $(O)lev_main.o \ $(O)alloc.o $(O)decl.o $(O)drawing.o \ $(O)monst.o $(O)objects.o $(O)panic.o -DGNCOMPOBJS = $(O)dgn_yacc.o $(O)dgn_$(LEX).o $(O)dgn_main.o \ +DGNCOMPOBJS = $(O)dgn_yacc.o $(O)dgn_lex.o $(O)dgn_main.o \ $(O)alloc.o $(O)panic.o + RECOVOBJS = $(O)recover.o TILEFILES = $(WSHR)\monsters.txt $(WSHR)\objects.txt $(WSHR)\other.txt @@ -840,6 +873,14 @@ $(INCL)\vis_tab.h: $(U)makedefs.exe $(SRC)\vis_tab.c: $(U)makedefs.exe $(U)makedefs -z +$(DAT)\engrave: $(DAT)\engrave.txt $(U)makedefs.exe + ..\util\makedefs -s +$(DAT)\epitaph: $(DAT)\epitaph.txt $(U)makedefs.exe + ..\util\makedefs -s +$(DAT)\bogusmon: $(DAT)\bogusmon.txt $(U)makedefs.exe + ..\util\makedefs -s + + #========================================== # uudecode utility and uuencoded targets #========================================== @@ -890,71 +931,55 @@ $(WIN32)\splash.bmp: $(U)uudecode.exe $(WIN32)\splash.uu ..\..\util\uudecode.exe splash.uu chdir ..\..\src -#========================================== +#================================================= # Level Compiler Stuff -#========================================== +#================================================= +# +# defer to the steps in ..\win\win32\levstuff.mak +# -LEVCFLAGS=-c -nologo -DWINVER=0x0400 -DWIN32 -D_WIN32 \ - -D_MT -MT -I..\include -nologo -Z7 -Od -DDLB +$(U)lev_yacc.c $(INCL)\lev_comp.h: $(U)lev_comp.y + nmake -nologo -f ..\win\win32\levstuff.mak default + +LEVCFLAGS=-c -nologo -DWIN32 -D_WIN32 -I$(INCL) -nologo -Z7 -Od -DDLB + +$(O)lev_yacc.o: $(HACK_H) $(SP_LEV_H) $(INCL)\lev_comp.h $(U)lev_yacc.c + $(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)lev_yacc.c + +$(O)lev_lex.o: $(HACK_H) $(INCL)\lev_comp.h $(SP_LEV_H) \ + $(U)lev_lex.c + $(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)lev_lex.c + +$(O)lev_main.o: $(U)lev_main.c $(HACK_H) $(SP_LEV_H) + $(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)lev_main.c $(U)levcomp.exe: $(SPLEVOBJS) @echo Linking $@... - @$(link) $(lflagsUtil) /PDB:"$(O)$(@B).PDB" /MAP:"$(O)$(@B).MAP" -out:$@ @<<$(@B).lnk + echo $(link) + echo $(lflagsUtil) + $(link) $(lflagsUtil) /PDB:"$(O)$(@B).PDB" /MAP:"$(O)$(@B).MAP" -out:$@ @<<$(@B).lnk $(SPLEVOBJS:^ =^ ) << -$(O)lev_yacc.o: $(HACK_H) $(SP_LEV_H) $(INCL)\lev_comp.h $(U)lev_yacc.c - @$(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)lev_yacc.c - -$(O)lev_$(LEX).o: $(HACK_H) $(INCL)\lev_comp.h $(SP_LEV_H) \ - $(U)lev_$(LEX).c - @$(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)lev_$(LEX).c - -$(O)lev_main.o: $(U)lev_main.c $(HACK_H) $(SP_LEV_H) - @$(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)lev_main.c - - -$(U)lev_yacc.c $(INCL)\lev_comp.h : $(U)lev_comp.y -! IF "$(DO_YACC)"=="YACC_ACT" - chdir $(UTIL) - $(YACC) -d lev_comp.y - copy $(YTABC) lev_yacc.c - copy $(YTABH) $(INCL)\lev_comp.h - @del $(YTABC) - @del $(YTABH) - chdir $(SRC) -! ELSE - @echo $(U)lev_comp.y has changed. - @echo To update $(U)lev_yacc.c and $(INCL)\lev_comp.h run $(YACC). - @echo --- - @echo For now, we will copy the prebuilt lev_yacc.c and - @echo lev_comp.h from $(SSYS) into $(UTIL) and use them. - @copy $(SSYS)\lev_yacc.c $(U)lev_yacc.c >nul - @copy $(SSYS)\lev_comp.h $(INCL)\lev_comp.h >nul - @echo /**/ >>$(U)lev_yacc.c - @echo /**/ >>$(INCL)\lev_comp.h -! ENDIF - -$(U)lev_$(LEX).c: $(U)lev_comp.l -! IF "$(DO_LEX)"=="LEX_ACT" - chdir $(UTIL) - $(LEX) $(FLEXSKEL) lev_comp.l - copy $(LEXYYC) $@ - @del $(LEXYYC) - chdir $(SRC) -! ELSE - @echo $(U)lev_comp.l has changed. To update $@ run $(LEX). - @echo --- - @echo For now, we will copy the prebuilt lev_lex.c - @echo from $(SSYS) into $(UTIL) and use it. - @copy $(SSYS)\lev_lex.c $@ >nul - @echo /**/ >>$@ -! ENDIF - -#========================================== +#================================================= # Dungeon Compiler Stuff -#========================================== +#================================================= +# +# defer to the steps in ..\win\win32\dgnstuff.mak +# +$(U)dgn_yacc.c $(INCL)\dgn_comp.h : $(U)dgn_comp.y + nmake -nologo -f ..\win\win32\dgnstuff.mak default + +$(O)dgn_yacc.o: $(HACK_H) $(DGN_FILE_H) $(INCL)\dgn_comp.h $(U)dgn_yacc.c + @$(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)dgn_yacc.c + +$(O)dgn_lex.o: $(HACK_H) $(DGN_FILE_H) $(INCL)\dgn_comp.h \ + $(U)dgn_lex.c + @$(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)dgn_lex.c + +$(O)dgn_main.o: $(HACK_H) $(U)dgn_main.c + @$(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)dgn_main.c $(U)dgncomp.exe: $(DGNCOMPOBJS) @echo Linking $@... @@ -963,56 +988,9 @@ $(U)dgncomp.exe: $(DGNCOMPOBJS) ) << -$(O)dgn_yacc.o: $(HACK_H) $(DGN_FILE_H) $(INCL)\dgn_comp.h $(U)dgn_yacc.c - @$(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)dgn_yacc.c - -$(O)dgn_$(LEX).o: $(HACK_H) $(DGN_FILE_H) $(INCL)\dgn_comp.h \ - $(U)dgn_$(LEX).c - @$(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)dgn_$(LEX).c - -$(O)dgn_main.o: $(HACK_H) $(U)dgn_main.c - @$(CC) $(LEVCFLAGS) -W0 -Fo$@ $(U)dgn_main.c - -$(U)dgn_yacc.c $(INCL)\dgn_comp.h : $(U)dgn_comp.y -! IF "$(DO_YACC)"=="YACC_ACT" - chdir $(UTIL) - $(YACC) -d dgn_comp.y - copy $(YTABC) dgn_yacc.c - copy $(YTABH) $(INCL)\dgn_comp.h - @del $(YTABC) - @del $(YTABH) - chdir $(SRC) -! ELSE - @echo $(U)dgn_comp.y has changed. To update dgn_yacc.c and - @echo $(INCL)\dgn_comp.h run $(YACC). - @echo --- - @echo For now, we will copy the prebuilt $(U)dgn_yacc.c and - @echo dgn_comp.h from $(SSYS) into $(UTIL) and use them. - @copy $(SSYS)\dgn_yacc.c $(U)dgn_yacc.c >nul - @copy $(SSYS)\dgn_comp.h $(INCL)\dgn_comp.h >nul - @echo /**/ >>$(U)dgn_yacc.c - @echo /**/ >>$(INCL)\dgn_comp.h -! ENDIF - -$(U)dgn_$(LEX).c: $(U)dgn_comp.l -! IF "$(DO_LEX)"=="LEX_ACT" - chdir $(UTIL) - $(LEX) $(FLEXSKEL) dgn_comp.l - copy $(LEXYYC) $@ - @del $(LEXYYC) - chdir $(SRC) -! ELSE - @echo $(U)dgn_comp.l has changed. To update $@ run $(LEX). - @echo --- - @echo For now, we will copy the prebuilt dgn_lex.c - @echo from $(SSYS) into $(UTIL) and use it. - @copy $(SSYS)\dgn_lex.c $@ >nul - @echo /**/ >>$@ -! ENDIF - -#========================================== +#================================================= # Create directory for holding object files -#========================================== +#================================================= $(O)obj.tag: @if not exist $(OBJ)\*.* echo creating directory $(OBJ) @@ -1050,7 +1028,7 @@ envchk: #========================================== #=========================================== -# Header files NOT distributed in ..\include +# Header files NOT distributed in $(INCL) #=========================================== $(INCL)\win32api.h: $(NTSYS)\win32api.h @@ -1081,7 +1059,7 @@ $(DAT)\porthelp: $(NTSYS)\porthelp nhdat: $(U)dlb_main.exe $(DAT)\data $(DAT)\oracles $(OPTIONS_FILE) \ $(DAT)\quest.dat $(DAT)\rumors $(DAT)\help $(DAT)\hh $(DAT)\cmdhelp \ $(DAT)\history $(DAT)\opthelp $(DAT)\wizhelp $(DAT)\dungeon $(DAT)\porthelp \ - $(DAT)\license $(O)sp_lev.tag + $(DAT)\license $(DAT)\engrave $(DAT)\epitaph $(DAT)\bogusmon $(O)sp_lev.tag cd $(DAT) echo data >dlb.lst echo oracles >>dlb.lst @@ -1091,6 +1069,9 @@ nhdat: $(U)dlb_main.exe $(DAT)\data $(DAT)\oracles $(OPTIONS_FILE) \ if exist porthelp echo porthelp >>dlb.lst echo quest.dat >>dlb.lst echo rumors >>dlb.lst + echo engrave >>dlb.lst + echo epitaph >>dlb.lst + echo bogusmon >>dlb.lst echo help >>dlb.lst echo hh >>dlb.lst echo cmdhelp >>dlb.lst @@ -1238,6 +1219,9 @@ spotless: clean if exist $(U)*.map del $(U)*.map if exist $(DAT)\data del $(DAT)\data if exist $(DAT)\rumors del $(DAT)\rumors + if exist $(DAT)\engrave del $(DAT)\engrave + if exist $(DAT)\epitaph del $(DAT)\epitaph + if exist $(DAT)\bogusmon del $(DAT)\bogusmon if exist $(DAT)\???-fil?.lev del $(DAT)\???-fil?.lev if exist $(DAT)\???-goal.lev del $(DAT)\???-goal.lev if exist $(DAT)\???-loca.lev del $(DAT)\???-loca.lev @@ -1321,6 +1305,14 @@ clean: if exist $(O)sp_lev.tag del $(O)sp_lev.tag if exist $(O)uudecode.MAP del $(O)uudecode.MAP if exist $(O)uudecode.PDB del $(O)uudecode.PDB + rem + rem defer to the steps in ..\win\win32\levstuff.mak + rem + nmake -nologo -f ..\win\win32\levstuff.mak clean + rem + rem defer to the steps in ..\win\win32\dgnstuff.mak + rem + nmake -nologo -f ..\win\win32\dgnstuff.mak clean ! IF ("$(WINPFLAG)"!="") if exist $(TILEBMP16) del $(TILEBMP16) diff --git a/util/makedefs.c b/util/makedefs.c index f4ca9febb..8555178e1 100644 --- a/util/makedefs.c +++ b/util/makedefs.c @@ -169,6 +169,7 @@ static char *FDECL(bannerc_string, (char *,const char *)); static char *FDECL(xcrypt, (const char *)); static unsigned long FDECL(read_rumors_file, (const char *,int *,long *,unsigned long)); +static void FDECL(do_rnd_access_file, (const char *)); static boolean FDECL(d_filter, (char *)); static boolean FDECL(h_filter, (char *)); static boolean FDECL(ranged_attk,(struct permonst*)); @@ -213,7 +214,7 @@ extern unsigned _stklen = STKSIZ; int main(void) { - const char *def_options = "odemvpqrhz"; + const char *def_options = "odemvpqrshz"; char buf[100]; int len; @@ -329,6 +330,11 @@ char *options; case 'r': case 'R': do_rumors(); break; + case 's': + case 'S': do_rnd_access_file(EPITAPHFILE); + do_rnd_access_file(ENGRAVEFILE); + do_rnd_access_file(BOGUSMONFILE); + break; case 'h': case 'H': do_oracles(); break; @@ -870,6 +876,44 @@ unsigned long old_rumor_offset; return rumor_offset; } + +void +do_rnd_access_file(fname) +const char *fname; +{ + Sprintf(filename, DATA_IN_TEMPLATE, fname); + Strcat(filename, ".txt"); + if (!(ifp = fopen(filename, RDTMODE))) { + perror(filename); + exit(EXIT_FAILURE); + } + filename[0]='\0'; +#ifdef FILE_PREFIX + Strcat(filename, file_prefix); +#endif + Sprintf(eos(filename), DATA_TEMPLATE, fname); + if (!(ofp = fopen(filename, WRTMODE))) { + perror(filename); + exit(EXIT_FAILURE); + } + Fprintf(ofp,"%s",Dont_Edit_Data); + + tfp = getfp(DATA_TEMPLATE, "grep.tmp", WRTMODE); + grep0(ifp, tfp); + ifp = getfp(DATA_TEMPLATE, "grep.tmp", RDTMODE); + + while (fgets(in_line, sizeof in_line, ifp) != 0) { + if (in_line[0] == '#') continue; /* discard comments */ + if (in_line[0] == '\n') continue; /* and empty lines */ + (void) fputs(xcrypt(in_line), ofp); + } + Fclose(ifp); + Fclose(ofp); + + delete_file(DATA_TEMPLATE, "grep.tmp"); + return; +} + void do_rumors() { diff --git a/win/win32/levstuff.mak b/win/win32/levstuff.mak index 2a01e3f1e..2597e5eb7 100644 --- a/win/win32/levstuff.mak +++ b/win/win32/levstuff.mak @@ -1,11 +1,21 @@ -# Uncomment as appropriate for your form of YACC/LEX. -# -#YACC = yacc.exe -#YACC = byacc.exe -YACC = bison.exe -y -# -#LEX = lex.exe -LEX = flex.exe +# $NHDT-Date$ $NHDT-Branch$:$NHDT-Revision$ +# $Date:2002/01/22 22:54:54 $ $Revision: 1.2 $ +#YACC = byacc.exe +#LEX = flex.exe +#YTABC = y_tab.c +#YTABH = y_tab.h +#LEXYYC = lexyy.c + +!IF "$(YACC)"!="" +@echo Yacc-alike set to $(YACC) +@echo YTABC set to $(YTABC) +@echo YTABH set to $(YTABH) +!ENDIF + +!IF "$(LEX)"!="" +@echo Lex-alike set to $(LEX) +@echo LEXYYC set to $(LEXYYC) +!ENDIF # these won't have an impact unless YACC/LEX are defined YTABC = y.tab.c