Commit Graph

358 Commits

Author SHA1 Message Date
nethack.allison
364a4fa882 win32 shknam updates 2002-03-06 19:02:49 +00:00
nethack.allison
35df97d41c Support iflags.menu_tab_sep in the #enhance menu. 2002-03-06 17:46:49 +00:00
nethack.allison
d1b7781509 Ensure that vision is not used during done()
(and panic() which calls done())

This uses the flag that <Someone> recently added.

At least one crash in the past was caused by

? -> panic() -> done(11) -> * vision_recalc(2) -> newsym() -> crash!
if  u.ux and u.uy are 0
2002-03-06 16:51:17 +00:00
cohrs
3ca42c2265 another "your corpse" case
- switch aobjnam() to use cxname, not xname
- update Tobjnam() comment, since it can still use xname w/o confusion

A specific case that's fixed: You begin bashing monsters with your corpse.
2002-03-06 04:14:30 +00:00
nethack.allison
233385401a more weapon shattering
The Kop Kaptain's rubber hose shatters from the force of your blow!
Rubber hoses are an individual exception that would need to be dealt
with explicitly, since the PLASTIC they're made of is floppy rather
than rigid as for other PLASTIC items.
2002-03-06 01:58:07 +00:00
nethack.allison
a618b5ed03 <Someone>'s potion of polymorph suggestion
> Should a potion of polymorph autoidentify if the item dipped into it
> polymorphs into (as far as you know) the same item? It just seemed
> odd, choosing "Z - a wand of light" to dip into a potion, to get
> "Z - a wand of light" returned, and the potion identified.
>
> (Ideally, I'd like to see it be "Nothing seems to happen.", as for
> a failed-this-time unicorn horn.)
2002-03-06 00:22:37 +00:00
cohrs
51fac7ac64 iron bars and wallification
- iron bars should be treated like doors with respect to wallification
2002-03-05 07:46:40 +00:00
cohrs
bf2190c55e allow locks to be forced again
- use uwep's oc_wldam value, not chest's oc_wldam value, for computing chance.
  oc_wldam has always been 0 for all containers
- the code was broken for a long time, but was masked by the off-by-1 error
  in checking the chance, allowing a 1% chance of forcing
- the result is that forcing locks is a lot easier
2002-03-05 06:21:05 +00:00
nethack.allison
3c0e37d9c9 add windowcolors option
Add option windowcolors to control foreground/background
color of menu, message, status, and text windows.
(foreground color is the text color).

The value of the colors is window port specific, the
core code handles the storing of the strings only.
2002-03-05 05:03:48 +00:00
nethack.allison
615568369e no message 2002-03-05 04:57:50 +00:00
nethack.allison
df7a5c3f96 Prevent fake amulet from being contained too
Most NetHack players have picked up on the fact that you can
easily distinguish between a fake amulet and the real thing
simply by trying to put it into a container. That's too easy.
The message was adjusted too, to make it seem less
like the objects have their own special will to resist, something
that a hunk of plastic is unlikely to have.

Devteam: message has been modified from what was previously
circulated.
2002-03-04 04:39:41 +00:00
cohrs
c8e3ea61f6 ambiguous option matching
Note: actual option setting code in parseoptions already does this correctly
- avoid testing the same options values vs multiple boolopts entries
- apply similar change for complex option testing
- remove some dead code
2002-03-03 20:29:36 +00:00
arromdee
8492e67ee5 obsolete comment tid 2002-03-03 05:29:30 +00:00
arromdee
a5b8144dd1 wizkit messages for gold
This prevents wizkit items that aren't objects from having their names
printed on the screen if they are gold pieces, traps, or similar.

(Note that the only one of those that actually works is gold.  For some reason
if you put "a hole" (for instance) in the wizkit, the hole will not get
created, even though it will, even on the stairs, if the wizard wishes for it
in-game.)
2002-03-03 05:01:09 +00:00
nethack.rankin
b1b5e13bfa #turn fix
Don't report that undead monsters are "turning to flee"
when they're about to be made peaceful or killed outright,
and add a missing alignment fixup for the case where they do
get made peaceful.

     Also, a trivial bit that only matters when using wizard
mode to wish for altars.  To #offer the Amulet you need to be
on the Astral level rather than just anywhere in the endgame.
2002-03-03 04:28:08 +00:00
nethack.rankin
359405abd3 fix B9003: prevent multiple touchstones in A's starting inventory 2002-03-03 04:14:54 +00:00
cohrs
c5c394023e WIZKIT gold items
- if !GOLDOBJ, putting gold in the WIZKIT would add zerobj to the inventory.
  This shows up when you "Da" and get a message like "you drop 0 glorkum 0 0 0"
2002-03-03 03:36:33 +00:00
arromdee
38e60fa8d1 jeweler shopkeeper touchstone (B3015)
This implements the suggestion in beta bug 3015.
2002-03-02 16:46:56 +00:00
arromdee
e4f694986c french fried food (B7010)
This implements the suggestion in beta bug 7010.
2002-03-02 16:18:39 +00:00
arromdee
8651a77b43 bug 8009 (dropping gold on altar)
This fixes beta bug 8009 (dropping gold on altar)
2002-03-02 16:06:12 +00:00
nethack.rankin
dad14c21a7 build fix
Some old compilers don't like to use the name of a function-like
macro for anything other than invoking that macro.
2002-03-02 06:16:37 +00:00
arromdee
d6d445d514 This fixes beta bug 8003 (half physical damage from gas spores) as well as a
minor bit of cleanup in mon.c.
2002-03-02 01:07:11 +00:00
nethack.rankin
e15c0d801f code sync nitpick
The cvs sources had a single space difference from nh-patches sources.
2002-03-02 00:57:52 +00:00
cohrs
8fb7664869 fix more your corpse cases
- new cxname() to simplify doing the right thing in increasingly common cases
- use for bullwhip snagging
- in shopkeeper offer code
- in a couple other existing places rather than duplicating CORPSE checks
- use singular(...) in "swings" cases, since only one can hit.  Singular uses
  corpse_xname automatically when appropriate
2002-02-27 05:15:48 +00:00
arromdee
c9f7360301 stopping occupation when missed
This fixes beta bug 3020.  It was hard to notice because the presence of a
monster in the room stops your occupation anyway, so it wasn't triggered unless
you were blind.
2002-02-27 02:29:33 +00:00
arromdee
7827e17848 cloning minions
Janet pointed this one out to me...
2002-02-27 02:17:01 +00:00
cohrs
f33ab026b8 shattering corpses
- generalize which weapons can be shattered to be >= WOOD
2002-02-26 22:07:24 +00:00
cohrs
0f1615c7ad simplify touchstone object choosing
- remove special case code from getobj for touchstone
- remove other hacks from getobj that resulted from earlier hack, solves
  the "rub on the gold stone" problem completely
- pass correct letter list to getobj from use_stone, like other callers
2002-02-26 07:36:30 +00:00
arromdee
af51f4b0a2 cloning
Fix a minor cloning problem; clones didn't retain the monster's name or
tameness.  (The name *was* retained if you were cloned.)  I also added a
minor change in wizard mode to display a few tameness fields of a dog.
2002-02-26 06:55:17 +00:00
nethack.allison
2272e70d39 message follow-up 2002-02-25 20:24:04 +00:00
nethack.allison
24956e3b53 The unpaid cost displayed in your inventory now
includes container contents, not just the cost of the
container itself (a prices in inventory phenomenon).

Along the way I discovered a peculiarity -
contained_cost() was adding up the cost of everything in
a container, even if you had stashed items in it that were your
own and not marked unpaid it seems.

I added a flag to force the code to only add objects
that were marked "unpaid" so I could use it in this new
instance, but I didn't change any of
the existing usages (I left the flag at FALSE which leaves
the consideration of the unpaid status alone just as
before).

Some of this is correction of some messages that were
wrong prior to this when dealing with selling of objects
inside a container when only part of the contents was unpaid.
2002-02-25 19:14:42 +00:00
cohrs
63908bbed4 'D'ropping gold messes up inventory
- new splitobj() behavior requires special casing when !GOLDOBJ and
  dropping some of your gold, to ensure that the remainder remains the first
  item in the inventory
2002-02-25 05:51:44 +00:00
cohrs
6db3117830 sling, like whip, shouldn't shatter from a blow 2002-02-25 02:57:57 +00:00
cohrs
7f5285b1ee converting SCORR to CORR unblocks vision
- fix several cases where a point was unblocked by unblock_point wasn't
 called, directly or indirectly
2002-02-25 02:43:50 +00:00
cohrs
f9aaeda9b9 monsters jumping into hidden traps
- if a monster jumps into a trap in an SCORR, and you see it, convert to CORR
2002-02-25 01:02:55 +00:00
cohrs
df31185e9c mounting steed while levitating at will
- avoid causing damage if you slip and levitating at will
- change message slightly in this case as well
2002-02-24 21:36:32 +00:00
nethack.allison
8d08badfbb Darkness msg despite sunsword
> Is the "You are surrounded by darkness!" message from reading a cursed
> scroll of light (or non-cursed if confused) appropriate if you're
> wielding Sunsword, which _doesn't_ get turned off by it?
2002-02-24 19:13:32 +00:00
cohrs
0a9beba75e a flag to track if vision is ready
- new iflags.vision_inited to determine if vision is ready to go.
- the flag is set the first time vision_reset() completes, actually every time
- vision_recalc() checks the flag before doing anything.
2002-02-24 18:04:02 +00:00
nethack.allison
490ceaee6c change is_greystone() to is_graystone()
-Rename is_greystone() to is_graystone() since I've
had one complaint about my choice of spelling for
the macro already.

-Change the recent "#rub touchstone" code to use
the macro which pre-existed under the other spelling
and was already used in the very same "if" statement
with that spelling in invent.c. :-)
2002-02-24 17:23:02 +00:00
nethack.allison
f9244b56ad wizkit follow-up
The recent wizkit change caused the build to
fail on all environments other than unix and vms.

>..\src\files.c(1607) : error C2065: 'envp' : undeclared identifier
>..\src\files.c(1607) : warning C4047: '=' :
>'int ' differs in levels of indirect ion from 'char *'
>..\src\files.c(1608) : error C2100: illegal indirection
>..\src\files.c(1608) : warning C4047: 'function' :
>'const char *' differs in levels of indirection from 'int '
>..\src\files.c(1608) : warning C4024: 'strncpy' :
2002-02-24 17:17:25 +00:00
nethack.rankin
6b4429d942 more wizkit: bulletproofing previous change 2002-02-24 06:56:46 +00:00
cohrs
fcf8af733b vault guard message on the wrong level
if vault guard leaves his original level and is killed, clear_fcorr
was still attempted on the wrong level.
2002-02-24 06:56:02 +00:00
nethack.rankin
34f682205c wizkit enhancement
Allow a WIZKIT file name to be specified via the environment.
If none is specified there, get it from the run-time config file.
2002-02-24 06:51:36 +00:00
nethack.rankin
163f394fbe monster use of artifacts
From the newsgroup:  some of the fake player monsters on the
astral level were unable to use artifacts that they were created
with due to alignment mismatch.  Rather than try to adjust the
artifact creation of only select matching items, this patch lets
them handle artifacts when alignments differ (more or less like
the player; monsters don't occasionally get blasted though).

     This also restores chaotic monsters with the ability to use
Stormbringer; I'm not sure how long that has been broken.  It also
gives lawful ones the ability to use Excalibur.
2002-02-24 06:12:57 +00:00
cohrs
cae2ef47c3 random shrines on special levels
- "random" shrines generate the value -1, not -11
- rn2(1) always == 0, should be rn2(2), sanctums aren't random
2002-02-24 05:38:57 +00:00
nethack.rankin
753cc7089f fix B3024: remove vs take off
Change the prompts for P and R commands to use "put on" instead
of "wear" and "remove" instead of "take off", respectively; W and T
commands aren't affected.  There is no change in game play.
2002-02-24 05:05:11 +00:00
nethack.rankin
4bc3561a96 from <Someone>: #rub touchstone
<Someone>'s message said this was committed, but the cvs repository
didn't reflect his changes.

> Subject: patch: #rub touchstone
> Date: Wed, 20 Feb 2002 23:33:27 -0800
> <email deleted>
>
> Implement <Someone>'s suggestion.
>
> - allow the #rub command to apply to gray stones
> - update various doc & help files to reflect the change
>
> Committed to CVS.
2002-02-24 03:19:20 +00:00
nethack.rankin
3ae126c83f "fix" B6004
The comment about Book of the Dead's taming effect working
on nearby monsters when read while swallowed was wrong.  It was
only put there in the first place to avoid adding extra code to
suppress taming while swallowed when that was done for the other
methods of taming.  Any need for extra code here turns out to be
unnecessary due to the cansee() check.
2002-02-24 00:51:20 +00:00
nethack.rankin
a9b2f4f1ee double undead turning
From the newsgroup:  when an undead monster got killed by a wand
or spell of undead turning, if it left a corpse that corpse would be
hit by the same zap and was immediately revived.  This fix uses the
flag bits that were added to prevent objects that are dropped by a
polymorphed monster from being hit by the same polymorph zap.

     This also fixes a post-3.3.1 bug that produced "the <undead>
turns to flee" even when that monster had been killed by the turning
attack.  3.3.1 had the same bogus fleeing effect but didn't give any
message so it was unnoticeable.
2002-02-23 11:13:41 +00:00
nethack.rankin
6f90e5bc8c Another artifact damage update
Make being hit by an artifact which does fire, cold, or
lightning (or magic missiles, since the code is there) affect
inventory even when the target resists the damage him-/her-/itself.
This removes the need for the redundant fire vs slime handling that
I put in yesterday.  Unfortunately it also means that Valkyries who
throw Mjollnir will inevitably end up destroying all their mettalic
wands and rings, so I reduced the chance of it hitting upon its
return.
2002-02-23 10:55:43 +00:00