(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
- 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.
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.
> 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.)
- 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
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.
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.
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
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.)
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.
- 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"
- 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
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.
- 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
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.
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.
- 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
> 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?
- 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.
-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. :-)
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' :
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.
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.
<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.
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.
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.
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.