Commit Graph

3469 Commits

Author SHA1 Message Date
nethack.allison
3cc5a682c9 comment bit (trunk only)
A comment needed updating following Pat's patch.
2006-10-22 18:22:04 +00:00
nethack.allison
239039499e comment bit (trunk only) 2006-10-22 17:48:11 +00:00
nethack.allison
c1b97d3a1a comment bit (trunk only) 2006-10-22 17:45:12 +00:00
nethack.rankin
054a74d378 yn_function (trunk only)
Explicitly truncate the query prompt string to QBUFSZ-1 characters.
For tty and Amiga, no longer include the choices and default within that
length limit; use a bigger buffer to hold them along with the prompt.
[See cvs log for doc/window.doc for more details.]
2006-10-22 05:59:26 +00:00
nethack.rankin
3dc9791685 yn_function (trunk only)
Explicitly truncate the query prompt string to QBUFSZ-1 characters.
For tty and Amiga, no longer include the choices and default within that
length limit; use a bigger buffer to hold them along with the prompt.
-----

     While trying to eliminate the "Query truncated" entries present in
nethack.alt.org's paniclog, I seem to keep going backwards.  Allowing
<win>_yn_function() to accept a full QBUFSZ worth of characters will
simplify the existing yn_function() in the core and greatly simplify the
revised safe_qbuf() I've been working on.

     Some interfaces don't seem to care how long the prompt string is; I've
left those along.  Several of the others already copied the prompt string
into a BUFSZ sized buffer instead of a QBUFSZ sized one, making them
unlikely to suffer from buffer overflows.  This changes the rest (just tty
and Amiga, I think) to do the same.  Also for all that have any size
constraint, it now truncates the prompt query to QBUFSZ-1 chars as it is
used rather than continue to rely on the caller doing so.  This assumes
that appending the set of acceptable choices and the default response won't
overflow, which is a safe assumption unless/until QBUFSZ gets enlarged til
it's too close to BUFSZ.

     Only tty's topl.c has been tested.  The others should work ok, but
might possibly be bitten by a typo or two.  Qt's implementation of the X11
"slow" method (reusing a persistant one-line window for prompts) has been
handled, but its C++ class-based variant is untouched; NetHackQtYnDialog::
Exec() is completely baffling to me but doesn't appear to have any length
issues.
2006-10-22 05:58:17 +00:00
nethack.rankin
f3a5f4e61d unhiding during summoning
According to a newsgroup followup, a hidden pet summoned via magic
whistle could produce the same effect as the level change case (where
sometimes the glyph for unseen monster would appear unexpectedly).  I was
unable to reproduce this one, but I don't see anything in the code to deal
with the situation, so I suspect that the monster is moving immediately
and being revealed before I have a chance to notice anything odd.

     I assume that other situations where hidden monsters get teleported
are being handled as attacks which expose them.  At least I hope so.
2006-10-22 03:53:50 +00:00
nethack.rankin
6b371a7042 unhiding during level change
From the newsgroup:  if a pet was hiding under an object next to you
when you changed levels, it could arrive hidden at the destination if there
was something available to hide under there too, and sometimes you'd start
the new level with a hidden monster glyph at its location.  I was able to
reproduce that once with current trunk code, but while trying to figure
out what is actually happening I've been unable to make it happen again.
However, it doesn't make sense for a monster to be able to remain in hiding
during the level change in the first place, so this patch prevents that.
(I'd still like to know how/why map_invisible() is sometimes getting called.
[The test character was a level 1 tourist without auto-search capability.]
I'm reasonably sure that it won't happen any more once this fix in place.)

     This also brings adjacent pets out of hiding when they accompany you
during ascension or dungeon escape, but it seems that that wasn't actually
necessary.  The end of game disclosure already lists such by name rather
than as "it", contrary to my expectations.  (I had forgotten that end-of-
game forces true names so that blindness and hallucination don't interfere
with disclosure; obviously that ends up handling hidden monsters too.)
2006-10-22 02:53:31 +00:00
nethack.allison
4169a3a308 Remove win32 mapi mail from distribution (trunk only) 2006-10-19 13:26:54 +00:00
nethack.allison
aed3d37e17 more unicode follow up
Set the unicode restriction bit when loading a symset when appropriate,
and a win32 console refinement.
2006-10-18 04:10:43 +00:00
nethack.allison
600697fadf unicode follow up
attr value was only getting one byte allocated instead
of 1 * sizeof(nhwchar), so add required paranthesis.
2006-10-18 03:51:54 +00:00
nethack.allison
c19017a91b botl.c follow up (trunk only) 2006-10-18 00:17:48 +00:00
nethack.allison
24bf14cdb2 add some unicode support (trunk only)
This patch attempts to add some levels of unicode support
to NetHack.

The master on/off switch for any Unicode support is
defining UNICODE_SUPPORT in config.h. Currently
there is code support for two subsets of unicode support:

UNICODE_DRAWING

If UNICODE_DRAWING is defined, then the data
structures used to house drawing symbols are expanded
to the size of wchar_t, big enough to hold unicode characters.
A typdef called `nhsym' is involved and if UNICODE_DRAWING
is defined, it is wchar_t, otherwise it is uchar.

UNICODE_WIDEWINPORT

If UNICODE_WIDEWINPORT is defined, then the data
structures inside the window port are expanded to the size of
wchar_t, big enough to hold unicode characters.  Both map
symbols and text within the window port are expanded, in order
for potential support for displaying multinational characters some
day, but this patch only provides viewing of map symbols.
A typdef called `nhwchar' is involved and if UNICODE_WIDEWINPORT
is defined, it is wchar_t, otherwise it is char.

The only window port with code support for UNICODE_WIDEWINPORT
currently is the TTY port.  Don't enable UNICODE_WIDEWINPORT
unless:
- it is a TTY port
- the underlying platform specific routines can
handle the larger data structures.

Don't enable UNICODE_SUPPORT unless:
- your compiler can handle wchar_t.
- your compiler can accept L'a' characters.
- your compiler can accept L"wide" strings.

Note that if your compiler can handle the above, you could
enable the larger data structures (currently if TTY) even if your
platform can't actually display unicode or UTF-8, by messing
with u_putch() in win/tty/wintty.c to only deal regular chars.
That should be the only function that actually pushes wide characters
out to the display.

If you enable UNICODE_SUPPORT, and your platform is capable
you will need to turn on the unicode run-time option to be able to
load unicode character sets from the symbol file, to be able to
push unicode characters to the display. You'll also want to load
a unicode symbol set once the unicode option is toggled on. In
a config file you would do that via these two lines:
OPTIONS=unicode
OPTIONS=symset:Unicode_non_US

The repository was stamped with NETHACK_PRE_UNICODE
prior to applying this patch, and stamped with
NETHACK_POST_UNICODE afterwards. The code differences
between those two tagged versions are this patch.
2006-10-18 00:09:18 +00:00
nethack.allison
7f0f43e6f9 add some unicode support (trunk only)
This patch attempts to add some levels of unicode support
to NetHack.

The master on/off switch for any Unicode support is
defining UNICODE_SUPPORT in config.h. Currently
there is code support for two subsets of unicode support:

UNICODE_DRAWING

If UNICODE_DRAWING is defined, then the data
structures used to house drawing symbols are expanded
to the size of wchar_t, big enough to hold unicode characters.
A typdef called `nhsym' is involved and if UNICODE_DRAWING
is defined, it is wchar_t, otherwise it is uchar.

UNICODE_WIDEWINPORT

If UNICODE_WIDEWINPORT is defined, then the data
structures inside the window port are expanded to the size of
wchar_t, big enough to hold unicode characters.  Both map
symbols and text within the window port are expanded, in order
for potential support for displaying multinational characters some
day, but this patch only provides viewing of map symbols.
A typdef called `nhwchar' is involved and if UNICODE_WIDEWINPORT
is defined, it is wchar_t, otherwise it is char.

The only window port with code support for UNICODE_WIDEWINPORT
currently is the TTY port.  Don't enable UNICODE_WIDEWINPORT
unless:
- it is a TTY port
- the underlying platform specific routines can
handle the larger data structures.

Don't enable UNICODE_SUPPORT unless:
- your compiler can handle wchar_t.
- your compiler can accept L'a' characters.
- your compiler can accept L"wide" strings.

Note that if your compiler can handle the above, you could
enable the larger data structures (currently if TTY) even if your
platform can't actually display unicode or UTF-8, by messing
with u_putch() in win/tty/wintty.c to only deal regular chars.
That should be the only function that actually pushes wide characters
out to the display.

If you enable UNICODE_SUPPORT, and your platform is capable
you will need to turn on the unicode run-time option to be able to
load unicode character sets from the symbol file, to be able to
push unicode characters to the display. You'll also want to load
a unicode symbol set once the unicode option is toggled on. In
a config file you would do that via these two lines:
OPTIONS=unicode
OPTIONS=symset:Unicode_non_US

The repository was stamped with NETHACK_PRE_UNICODE
prior to applying this patch, and stamped with
NETHACK_POST_UNICODE afterwards. The code differences
between those two tagged versions are this patch.
2006-10-17 23:55:42 +00:00
nethack.allison
3054c1c846 botl.c follow up (trunk only) 2006-10-17 23:52:09 +00:00
nethack.allison
8fc01eb6b1 window port change - putmixed() (trunk only)
Add putmixed() to the window port. It allows map symbols to
be included in the string by encoding them in a unique fashion.
This was done because Unicode symbols, for instance, could be
longer than the size of a char.

The encoding of the map symbols in this patch is done by
prefixing a glyph value with \GXXXX, where XXXX is a
random value for the current game. The reason for the random
prefix is to minimize the possibility that a player can trigger
the escape sequence processing within text under their control
(dog names, etc.) the way they could if the sequence was fixed
in the source code. The random prefix remains the same throughout
the lifetime of a game because message window strings are
saved in the save file.

(There was actually a bug present because of the embedded
character even before the recent symbol changes, because if
someone was using a  different set of characters between games,
the saved messages would reflect the original characters, rather
than the current. That bug was introduced with the ability to
save messages to the savefile.)

A window port does not have to supply an XXX_putmixed() routine,
it can use genl_putmixed() which uses the old behavior of
embedding the sequence as a character within the string
and calling putstr(). genl_putmixed() takes care of the decoding
of the escape sequence.

This also #ifdef's out code in pager.c for converting a glyph
to a character, and uses mapglyph() to do that instead. Does
anyone see a problem with doing that through mapglyph instead
of repeating similar code within pager.c?
2006-10-17 23:06:31 +00:00
nethack.allison
6873e64cf5 symset restrictions (trunk only)
The restricted bits could end up set on non-restricted sets.
This case needs to check that we're in a matching set.
2006-10-17 11:56:31 +00:00
nethack.rankin
624a1b31d9 surviving petrification (trunk only)
From the newsgroup:  if you were wielding a cockatrice corpse without
gloves while polymorphed into something capable of doing that, then were
turned to stone when rehumanizing, you'd be left wielding the untouchable
corpse if life-saving kept the game going.  This causes it to stop being
wielded if you get that far.  Likewise for monsters.
2006-10-13 05:39:16 +00:00
nethack.rankin
93eccebe84 sleeping steeds (trunk only)
From the newsgroup:  it was possible to saddle, mount, and ride on a
sleeping jabberwork without it ever waking up.  Movement was checking for
timed sleep (!mon->mcanmove, set when mon->mfrozen contains a timer count
for either sleep or paralysis) but not indefinite sleep (mon->msleeping).
This moves the checking into its own routine which handles both types.
And it gives monsters a chance to wake up when they get saddled or mounted.
2006-10-13 04:03:36 +00:00
keni
951e0d87fa Pad rumors to improve distribution of delivered rumors. 2006-10-12 00:17:17 +00:00
nethack.rankin
5ee8d49877 comment typo 2006-10-10 05:53:24 +00:00
nethack.rankin
35920f24d5 paniclog prefix (trunk only)
Extend the identifying information used to prefix paniclog entries
from version + date to version + date + time + userid + mode (where mode
is 'D' for wizard mode, 'X' for discover mode, and '-' for normal play).

     hacklib.c ended up getting more of a revision than I intended, but
the date/time handling routines now have less clutter.  I hope I didn't
break anything in the process.
2006-10-10 05:47:04 +00:00
nethack.allison
ab947c6b65 squeaky boards (trunk only)
There is a quote in data.base for squeaky board traps:
	A floorboard creaked.  Galder had spent many hours tuning them,
	always a wise precaution with an ambitious assistant who walked
	like a cat.
	D flat.  That meant he was just to the right of the door.
	"Ah, Trymon," he said, without turning, and noted with some
	satisfaction the faint indrawing of breath behind him.  "Good
	of you to come.  Shut the door, will you?"
		[ The Light Fantastic, by Terry Pratchett ]

This patch makes each squeaky board trap on a level produce
a unique sound. If you had visited the trap yourself prior
to hearing a monster on it, you could actually know where
a monster was by the unique pitch of the squeak.

If someone wants further refinement of the roles, this could
be adjusted to only work for musically adept roles/species,
with the others only hearing a generic squeak. As it stands
right now, everyone benefits.  Does anyone thing the
separation by role or species would be good? If so, which
roles/species are musically proficient, and which are not?

Since this patch increments editlevel anyway, it also sneaks in a
context structure change for an upcoming patch.
2006-10-08 21:37:58 +00:00
nethack.allison
2c5d46fbd7 symbol bit (trunk only)
Ensure that the symset struct is defined before
external declaration using it.
2006-10-07 23:06:35 +00:00
nethack.rankin
f49361a3c1 non-rotting food (trunk only)
From a bug report:  if you
attempted to eat a Rider corpse and got the 1/7 chance that non-yet-rotten
food will be treated as rotten, then also got "the world spins and goes
dark" result for rotten food, you would both survive the eating attempt
and also end up with a partly eaten Rider corpse.  This patch treats Rider
corpses like lizard and lichen corpses; they'll never yield rotten food
effects.  That way, they'll always be fatal to eat.  They'll still end up
being partly eaten if you are life-saved, but since they'll immediately
revive, the only way you'll know that is to use probing or stethoscope to
discover that they've revived at less than full health.

     Nearly two years ago, <email deleted>
suggested that lembas wafers and cram rations be treated like fortune
cookies and never yield the rotten food result.  I'm guessing that cookies
are handled that way so that rotten food feedback doesn't override false
rumor delivery when they're cursed, rather than because they're considered
to be rot-proof.  This implements <Someone>'s suggestion, except that cursed
lembas and cram will still behave like rotten food.
2006-10-07 05:41:30 +00:00
cohrs
365440853b U856 - cockatrice and nurses
One from the way-back machine.  A nurse would hit you-as-cockatrice repeatedly
and never turned to stone.  With this change, nurses will turn to stone (and
also don't heal cockatrices, which seems fair).  I considered giving them
gloves, but that seemed like too much effort.  There are other cases where a
monster "hits" but will not petrify.  However, it doesn't seem like passiveum
detects all the specific ways the monster "hit" you so I left them alone.
2006-10-05 06:47:39 +00:00
nethack.allison
4ba3b7da34 win32 palette option tweak
The palette option is supposed to be allowed in the config file
without a value for win32 to trigger a load of a predefined
NetHack palette, but that wasn't working.

This fixes that. To prevent the use of any palette modification
code at all, just leave the palette option out of the config
file entirely.
2006-10-05 03:11:52 +00:00
nethack.rankin
1299e2f3b1 growth feedback
Fido grows up into a large dog.
     The soldier becomes a sargeant.

Similar feedback was previously given only when the monster was going to be
killed off due to its new form having been genocided.
2006-10-03 05:28:54 +00:00
nethack.rankin
5dc9c9e43a Guidebook bit
The shortest extended commands were being formatted differently in
Guidebook.txt than longer ones, looking a little odd.  Force them to seem
longer so that they all end up with similar formatting.

     Untested; based on how short option names are handled.  And I have no
idea whether the TeX version ought to have something similar done; I lack
the means to view it.  (In theory I could format it into Postscript,
transfer the result to a PC [a different one than what I'm using as a
terminal], convert it into PDF there, then use Acrobat to look at it.  In
practice, that's more effort than I care to expend for something so minor.)
2006-10-03 05:07:18 +00:00
cohrs
d04a0f808c H143 - bugles affecting all monsters
<Someone> pointed out that bugles, although noisy, only affect soldiers.
This didn't make sense to me either.  Added code so they will also affect
monsters near the bugler.
2006-10-03 03:32:26 +00:00
cohrs
94cca17049 symset followup
remove a couple unused variables
2006-10-03 03:19:59 +00:00
nethack.allison
0ce424b71a symset restrictions attribute (trunk only)
Pat Rankin wrote:
> I was about to also suggest that there
> be a rogue/non-rogue (with perhaps a third choice meaning "both")
> attribute.  That way we could keep the rogue choices from being
> listed in the "symset" menu and the non-rogue choices from the
> "roguesymset" menu.  Players who deliberately wanted to switch
> over would need to modify the attribute, possibly on a cloned set.
> Or perhaps they could just explicitly set their desired choices
> via NETHACKOPTIONS or .nethackrc and not use the 'O' menues--the
> new attribute doesn't necessary have to block which sets get used
> where, just filter menu entries to display the most applicable
> candidates.
2006-10-03 02:38:40 +00:00
nethack.allison
084dce82d0 symbol preprocessing (trunk only)
Clean up the preprocessing associated with the
loadable symbol stuff.

Base it on new LOADSYMSETS, rather than on the
previously existing ASCIIGRAPH preprocessor define.
2006-10-02 13:15:50 +00:00
nethack.allison
58a1828f18 win32
The new runtime has parameter checking, and this one
would cause NetHack pop up a dialog and die.
2006-10-02 03:43:31 +00:00
nethack.allison
0e5159b6b7 statue patch (trunk only)
Pat wrote:
> <Someone> has a patch (we've added a couple of
> his earlier ones) which changes the statue display from a single
> one size fits all "`" to a gray monster symbol instead.
> But I think the idea is a good one, and along with the
> bouldersym option could make the fairly hard to
> distinguish back-tick character go away.

Sources tagged before applying NETHACK_PRE_STATUE,
and afterwards with NETHACK_POST_STATUE for easy
rollback.
2006-10-01 21:34:54 +00:00
nethack.allison
a0986b1e30 statue patch (trunk only)
Pat wrote:
> <Someone> has a patch (we've added a couple of
> his earlier ones) which changes the statue display from a single
> one size fits all "`" to a gray monster symbol instead.
> But I think the idea is a good one, and along with the
> bouldersym option could make the fairly hard to
> distinguish back-tick character go away.

Sources tagged before applying NETHACK_PRE_STATUE,
and afterwards with NETHACK_POST_STATUE for easy
rollback.
2006-10-01 21:17:38 +00:00
nethack.allison
374e9fbbb4 more symbol stuff (trunk only)
- reduce the number of symbol tables for each graphics
set {PRIMARY, ROGUESET} from three {map, oc, mon}
tables for each of the display symbols, the loadable symbols,
and the rogue symbols, to one continguous table for
each:
showsyms: the current display symbols
l_syms: the loaded, alterable symbols
r_syms: the rogue symbols

- Modify mapglyph so that the index into the symbolt table is
available as a return value (it was a void function), rather than
just the char converted from the glyph.
- That makes it possible for a window port to use the same
index value to extract from another table (perhaps a unicode
table) for a different set of display symbols. The  index
is much more useful than trying to convert the character
into another type of symbol, as some contributed patches
have done.
- It is much easier to load a single alternative flat table to
make substitutions, since the corresponding value just
has to get placed into the same index offset in the
alternative table.

This also fixes a bug I found in botl.c, where you could
go to the rogue level, and the bottom line gold symbol
was not being updated with the new character as it should.
The reason was because the gold value had not changed,
only the field symbol used had changed.

This updates multiple ports to place a (void) cast on
the mapglyph call, now that it returns a value, so this
is going to generate a lot of diff e-mails.
2006-10-01 19:30:08 +00:00
nethack.rankin
fb8261769a locking/unlocking vs traps (trunk only)
About six weeks back, <email deleted> suggested that
bear traps should deal out damage and be escapable via opening magic.
This doesn't do anything about the first part, but it does allow opening
magic (wand of opening, spell of knock, blessed Bell of Opening) to get
the hero out of bear traps and webs if zapped either at self or downwards.
Zaps across the floor which hit monsters will free them from such traps,
with a chance that releasing a hostile monster will pacify it (using
existing #untrap code).  Conversely, if you are at a web or bear trap
location but not currently trapped, closing magic (wand of locking, spell
of wizard lock) will cause the trap to activate; you may or may not become
trapped.  Likewise for zaps at monsters who are at such locations, which
is treated as an attack.

     Opening magic which hits the hero or a monster located at a trap door
or falling rock trap spot will cause the trap to activate; as above, it's
an attack for the monster case.  At the moment, zapping opening magic
downwards at the hero's location (but not zapping at self or at monsters)
will also cause holes, pits, and spiked pits to activate.  (Zapping down
triggers falling rock traps and zapping up doesn't; that'll need to be
changed.)  Zapping opening down while mounted will untrap, if stuck in a
web or bear trap, and will trap, for the falling cases, in precedence over
releasing the saddle and forcibly dismounting.  The latter still occurs
when there is no applicable trap present though.

     Zapping locking magic downwards at a hole location will convert the
hole into a trap door.  Zapping breaking magic (wand of striking, spell of
force bolt) down at a trap door location will convert the trap door into a
hole.  (Neither conversion currently alters the made-by-you flag for the
trap.  However, the rationalization that distinctive style is what makes
made-by-you recognizable suggests that conversion should clear the flag.)
Lastly, the old behavior (which pre-dated bare holes) of destroying trap
doors when zapping down at them with locking magic has been removed--it
didn't seem to fit very well with the new cases.  I'm starting to have
second thoughts about that but am going to commit this before discovery of
some more niggling details drags it out for another six weeks.
2006-10-01 05:24:28 +00:00
nethack.rankin
d526b4f32f fix burned by burning/drowned in a drowning
From a bug report:  you could end up with
gravestone/logfile result of "burned by burning" or "drowned in a drowning".
If you get life-saved when drowning in water or burning in lava, the game
tries to teleport you to safety.  If the teleport fails for some reason--
such as lack of unoccupied non-water or non-lava locations--you drown or
burn again.  But life-saving was resetting the killer reason and the repeat
drowning/burning wasn't setting it up again, so the default got used and
produced a silly result.
2006-09-29 02:54:17 +00:00
nethack.rankin
556226f695 fix burned by burning/drowned in a drowning
From a bug report:  you could end up with
gravestone/logfile result of "burned by burning" or "drowned in a drowning".
If you get life-saved when drowning in water or burning in lava, the game
tries to teleport you to safety.  If the teleport fails for some reason--
such as lack of unoccupied non-water or non-lava locations--you drown or
burn again.  But life-saving was resetting the killer reason and the repeat
drowning/burning wasn't setting it up again, so the default got used and
produced a silly result.
2006-09-29 02:43:27 +00:00
nethack.allison
15d933a07f trouble after applying a wielded cream pie
<Someone> wrote:
> I can' t find this bug in the known bug list. If I missed I do apologize.
> It occurs on the standard windows nethack.exe. Just wield a cream pie
> and then apply it. Press x to switch weapons. Program in disorder.
> s - 1752440940 glorkum 32 26485 101's named ? (alternate weapon; not wielded).
> Greetings, <Someone>

It crashed with an access violation for me.
2006-09-29 00:40:18 +00:00
nethack.allison
c07c48ab01 roll back 3.4.x branch 2006-09-28 22:32:31 +00:00
nethack.rankin
e6f9adcc53 wizard ^G tweaks
Wizard mode's ^G lets you specify "tame <foo>", "peaceful <foo>", or
"hostile <foo>" to override the created monster's default disposition.
Since it also lets you override the restriction against creating unique
monsters and various other special ones like shopkeepers (a post-3.4.3
change), it became possible to produce tame versions of monsters that
ordinarily are impossible to tame.  That's pretty iffy even when it only
applies to debugging, so switch from internal tameness conversion to use
of tamedog() to get the non-tameable cases handled.  (Minor side-effect:
full moon might prevent a request for "tame dog" from starting out tame.)

     Also, for <N>^G, give up before the specified count is reached if
creation fails when creating multiple copies of a specific type of monster,
on the assumption that the level has become filled up.  (When the type is
random, keep trying in case you subsequently get something different which
could survive on water or inside solid rock.)
2006-09-28 03:56:02 +00:00
nethack.rankin
008366c273 fix #h192 - missile which kills engulfer is in limbo when hero gets expelled (trunk only)
More explicit control over the behavior of spoteffects() is probably
the way to go in the long run, but this much simpler fix handles the case
at hand.  I'm not sure what `thrownobj' was intended to be used for in the
first place, but it came in handy here.  (It was being left as a dangling
pointer when thitmonst() reports that the missile has been used up; that's
fixed now.)

    Fix the reported problem of lookhere/autopickup not seeing the missile
which just killed the engulfing monster whose death caused the hero to be
put back onto the map and so look/pickup upon arrival.  Normally the missile
gets placed after damage has been dealt and the throw has finished.  This
overrides that so that the missile is put into the engulfer's inventory as
it is being killed (which will then put that inventory onto the floor prior
to expelling the hero on top of same).  If the monster happens to get
life-saved it just ends up collecting the thrown-from-inside object a little
sooner than usual.

    This wouldn't correctly handle the same case for a kicked object, if
that were possible.  But it isn't possible to kick objects while engulfed,
so that's moot.  Other calls to thitmonst() and hmon() don't appear to have
any objects in transit so shouldn't need any comparable fix (I hope...).
2006-09-28 03:16:59 +00:00
nethack.allison
171a28871c Apply the symbol changes to 3.4.4 tree 2006-09-27 22:13:48 +00:00
cohrs
01ce182b02 fireproof containers catching fire in lava
Recently reported to the list, a fireproof container dropped in lava would
catch fire and burn.  Add the missing check; this looks an oversight when
the idea of fireproof was added, since other fireproof objects get handled
later in the cascading if().
2006-09-24 23:58:39 +00:00
cohrs
7272de6881 H216 - ball and chain movement
<Someone> reported the longstanding behavior that when dragging, the chain
does not always remain directly between the player and the ball.  This occurs
when the player zigzags.  Added a check to the simple drag code to try to
keep the chain directly between the player and the ball.  But, don't do this
if the player is walking thru rock or if it would move the chain into rock.
2006-09-24 22:31:22 +00:00
nethack.allison
bcf68f17da typo fix 2006-09-24 17:42:40 +00:00
nethack.allison
6e1c1dba92 symset properties (trunk only)
Pat Rankin wrote:
> Symbol set definitions need a description attribute, above and
> beyond allowing comments in the file, for inclusion in the 'O'
> command's menu entries for selecting them.
[...]
> mapglyph.c isn't the proper place to decide whether to define
> ROGUE_COLOR.  That may need to become a symbol attribute,
> which we'd then specify on the Epyx rogue set(s).

Implement both of the suggestions above.
2006-09-24 02:45:34 +00:00
cohrs
13559f1ad8 Elbereth on unoccupied locations
Pat recently forwarded a discussion that Elbereth was ignored unless there
was an object on its location.  Mostly.  It was also respected if the hero
was Displaced, no matter where the hero was.  No one commented on his
message, which I took for assent to address this.  Removed the qualifiers, so
now Elbereth is always respected, just like a scroll of scare monster.
2006-09-24 01:36:40 +00:00
cohrs
21eb6adf36 Guidebook sync for symset
Fix a few things in Guidebook.mn especially syntax errors in the new prose
about nethack symbols, and sync it with Guidebook.txt.
2006-09-23 23:23:48 +00:00