cohrs [Wed, 27 Feb 2002 05:15:48 +0000 (05:15 +0000)]
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
arromdee [Wed, 27 Feb 2002 02:29:33 +0000 (02:29 +0000)]
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.
cohrs [Tue, 26 Feb 2002 07:36:30 +0000 (07:36 +0000)]
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
arromdee [Tue, 26 Feb 2002 06:55:17 +0000 (06:55 +0000)]
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.
nethack.allison [Mon, 25 Feb 2002 19:14:42 +0000 (19:14 +0000)]
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.
cohrs [Mon, 25 Feb 2002 05:51:44 +0000 (05:51 +0000)]
'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
nethack.allison [Sun, 24 Feb 2002 19:13:32 +0000 (19:13 +0000)]
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?
cohrs [Sun, 24 Feb 2002 18:04:02 +0000 (18:04 +0000)]
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.
nethack.allison [Sun, 24 Feb 2002 17:23:02 +0000 (17:23 +0000)]
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. :-)
nethack.allison [Sun, 24 Feb 2002 16:16:59 +0000 (16:16 +0000)]
nttty hilite_pet follow-up
I didn't mean to override for any color in the mask. My
earlier patch caused it to make green, blue, or red all
become black (which still looked better than white on
grey).
This gets it right (famous last words), and only makes
the text character's color black if it is actually white
or bright white.
nethack.allison [Sun, 24 Feb 2002 15:45:05 +0000 (15:45 +0000)]
<Someone> reported a poor display result on the win32 tty
when hilite_pet was enabled. After checking into it, the
test was looking for the value:
(FOREGROUND_GREEN|FOREGROUND_BLUE|FOREGROUND_RED)
which signifies a white color on win32 console I/O. The
problem was that in some cases that was OR'd with
something else such as FOREGROUND_INTENSITY.
Fix it by checking only the bits that matter when
turning on the attribute.
nethack.rankin [Sun, 24 Feb 2002 06:12:57 +0000 (06:12 +0000)]
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.
nethack.rankin [Sun, 24 Feb 2002 05:05:11 +0000 (05:05 +0000)]
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.
nethack.rankin [Sun, 24 Feb 2002 00:51:20 +0000 (00:51 +0000)]
"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.
nethack.rankin [Sat, 23 Feb 2002 11:13:41 +0000 (11:13 +0000)]
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.
nethack.rankin [Sat, 23 Feb 2002 10:55:43 +0000 (10:55 +0000)]
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.
nethack.rankin [Fri, 22 Feb 2002 03:51:14 +0000 (03:51 +0000)]
Fire Brand vs sliming
Being hit by Fire Brand now stops the sliming process if you're
being turned into green slime. And throwing an artifact up will give
artifact hit effects when it falls back down, making it possible to
hit yourself with Fire Brand (among other things). Hitting yourself
with Vorpal Blade or the Tsurugi of Muramasa will never behead or
bisect you; hitting yourself with Stormbringer will drain levels.
(I hope the latter doesn't make it too easy for players to manipulate
their experience level.)
This doesn't add artifact_hit() handling to mthrowu. If monsters
ever start throwing artifacts that will need to be added.
kmhugo [Thu, 21 Feb 2002 16:35:58 +0000 (16:35 +0000)]
X marks the spot
Inspired by the new data.base entry for Archaeologists.
Adds some "X marks the spot" engravings on the Arc locate
level. A simple "X" engraving would be more accurate to
the pirate map legend, but players probably wouldn't get the
joke without an explanation.
nethack.allison [Thu, 21 Feb 2002 12:57:56 +0000 (12:57 +0000)]
- added ALT-keys support (except ALT-f and ALT-m which are menu
accelerators).
[...]
- added F4/F5 functionality - same as in MSDOS port
F4 toggles between fitting the tiled display to the screen
and full size (compresses the tiles to fit / uncompresses).
F5 alternates between ascii and tiles.
cohrs [Thu, 21 Feb 2002 07:10:30 +0000 (07:10 +0000)]
fix tty crashes for empty news file
- menu-window code could access a null pointer when there was no data
- menu-window code can't handle empty contents, because there's no place
to position the cursor, so force text mode
- still looked ugly, so added a check to avoid displaying anything if
the file was empty
cohrs [Thu, 21 Feb 2002 03:33:42 +0000 (03:33 +0000)]
add_sound_mapping cleanup
- avoid several buffer overflows
- move use of access() to files.c in new can_read_file() function
- remove extra newlines in raw_print() calls
- get ready for lint, eg sprintf -> Sprintf
- generally make the code look like core code, not Qt code
cohrs [Wed, 20 Feb 2002 02:33:14 +0000 (02:33 +0000)]
avoid you see it hatch
enexto may place monster out of site, even though egg was in sight. use
an(m_monnam(mon)) not a_monnam. Works in this case due to earlier checks.
nethack.allison [Tue, 19 Feb 2002 14:20:21 +0000 (14:20 +0000)]
More BUC
Defer to the validation code from pickup.c for checking
valid categories. This reduces the number of callback
functions required, and allows combinations of BUCX
to be used in traditional menu style.
cohrs [Tue, 19 Feb 2002 05:10:31 +0000 (05:10 +0000)]
permanent inventory window updates
Addresses the follwing missing updates:
- Quest Artifact identification by Quest Leader.
- Rust damage from a rust trap.
- Remove curse as a result of prayer (both fixing TROUBLE_CURSED_* and
the blessed-remove-curse boon.)
- Charging via PYEC
nethack.rankin [Tue, 19 Feb 2002 03:38:31 +0000 (03:38 +0000)]
high-end monster tuning
Strengthen Death by making his "drains your life force"
result take away some max HPs to augment the ordinary damage
it does. The chance for that effect is reduced from 80% to
75% though. Weaken Famine, Pestilence, and Demogorgon by
preventing them from hitting with both of their disease or
hunger attacks on the same turn. When their first attack
hits, the second now gets treated as a stun attack, but if
the first one misses then the second is unchanged and yields
another chance to deliver the disease or hunger effect.
cohrs [Mon, 18 Feb 2002 23:36:46 +0000 (23:36 +0000)]
purple worm digestion
Generally modify the AD_DGST damage type so that:
- players and pets get no AD_DGST nutrition from G_NOCORPSE monsters
- undead no longer convey any nutrition, to either monsters or you-as-monster
I decided on this based on the age typically assigned to undead corpses.
- digestion conveys 50% or normal nutrition, and takes 25% the time to eat.
- all AD_DGST attacks are now subject to gas spore explosions, including player
nethack.allison [Fri, 15 Feb 2002 13:26:27 +0000 (13:26 +0000)]
Includes:
1) Removal of bmp placement in binary directory in NT
2) No use of "intrinsic function" optimization in dsp
3) Compilation of resource file for NT Console
Untested on Borland yet. Tested on console/graphical/ide Microsoft C 6.0
cohrs [Fri, 15 Feb 2002 05:47:57 +0000 (05:47 +0000)]
stone-to-flesh downwards
display the typical "beneath" if you're levitating, not "at".
If over lava, say "blood boils". Also, treat ice & water like waterlevel case.
nethack.allison [Wed, 13 Feb 2002 20:09:52 +0000 (20:09 +0000)]
- added map scrolling:
Ctrl-left_arrow - scroll left
Ctrl-right_arrow - scroll right
Ctrl-up_arrow - scroll up
Ctrl-down_arrow - scroll down
Ctrl-home - scroll to upper left corner
Ctrl-end - scroll to lower right corner
Ctrl-PgUp - scroll one page up (vertical)
Ctrl-PgDown - scroll one page down (vertical)
nethack.rankin [Wed, 13 Feb 2002 06:36:31 +0000 (06:36 +0000)]
#enhance feedback
In the skills list shown by #enhance, add an annotation
for skills that have had enough practive to be advanced but
can't be because there aren't enough slots available or the
role-specific limit has been reached.
cohrs [Wed, 13 Feb 2002 03:26:24 +0000 (03:26 +0000)]
non-moving goal-oriented monsters
Monsters with goals like M3_WANTSBOOK often wouldn't move if another
monster was standing on the the goal object, add code for the missing case
cohrs [Tue, 12 Feb 2002 04:29:17 +0000 (04:29 +0000)]
seduction and "it"
use noit_* functions for monster names after the deed is done, to make
code consistent with the "you have discovered mon's identity" comment
cohrs [Tue, 12 Feb 2002 03:53:05 +0000 (03:53 +0000)]
player eating metal
1) player-as-rust monster should obey same rules for edible metal as monsters.
2) with GOLDOBJ, player-as-xorn couldn't eat gold in inventory
cohrs [Mon, 11 Feb 2002 03:29:11 +0000 (03:29 +0000)]
glyphs for breaking wands
use fire an cold glyphs when breaking the corresponding wands. Other
wands all get EXPL_MAGICAL since there's nothing more specific for them.