Commit Graph

2158 Commits

Author SHA1 Message Date
nethack.rankin
bc2215268b random level teleport fix
From the newsgroup:  prevent monsters from level teleporting out of
the quest into the main dungeon.  The player can't do that and monsters
weren't supposed to be able to, but from time to time the quest nemesis
has seemingly vanished after reading a cursed scroll of teleportation.
His disappearance was due to ending up on a random level between the
quest entrance and the top of the dungeon.

     This also fixes an obscure bug that I noticed while trying to
reproduce that problem:  uncontrolled level teleports by the player in
the quest had 80% or thereabouts chance of ending up on the quest home
level.  All 12-15 main dungeon levels above quest entrance were included
in the random range of 1 thru current+3, then any choice which tried to
pick one of those was converted to quest level 1.  (Monster destination
wasn't getting that adjustment.)
2003-06-01 14:52:04 +00:00
nethack.allison
1add9289c0 quiet warning
A recent patch triggered a warning about signed/unsigned mismatch in
an assignment.
2003-06-01 14:19:16 +00:00
nethack.rankin
678e05096d some lint cleanup
Mostly `gcc -Wwrite-strings' complaining about passing string
literals to safe_qbuf().  `gcc -Wformat' didn't catch the type mismatch
of formatting the return value of strlen() with %d, presumeably because
size_t is defined as unsigned int on this system and it treats int and
unsigned int as interchangeable as far as printf/scanf checking goes.

     I'm not sure whether the sizeof() values being passed to safe_qbuf()
ought to have casts.  Any system where size_t isn't the same width as
unsigned int is bound to support prototypes, but might possibly warn about
the implicit conversion of unsigned long (or even unsigned long long these
days) to unsigned int.
2003-05-31 07:14:21 +00:00
jwalz
c845548c36 Make enhanced ammo last longer.
Since traps can no longer provide an infinite supply, and people were
complaining that they always ran out of ammo before, make it less likely
to break enchanted and blessed ammo, and more likely to break eroded
ones.
2003-05-28 21:54:37 +00:00
jwalz
be7e8373f4 That one $(LD) needs to be an $(LD). $(CC) will link in the non-shared
C library and cause problems with address space for something NetHack's
size.
2003-05-28 17:33:54 +00:00
warwick
47bbe26073 Unify usage of $(CC) vs. $(LD) for linking to always $(LINK), set
to $(CC) by default.
Necessary for C++ builds where the C++ compiler driver must be used
to link, adding libraries that the C compiler driver does not know
about.
2003-05-28 05:36:57 +00:00
nethack.rankin
ad243c0286 cmdassist bits
If the player gives the 'T' command while not wearing any armor,
don't suggest "use 'R' to remove accessories" unless the character is
actually wearing accessories.  Likewise for 'R' while not wearing any
accessories, don't suggest "use 'T' to take off armor" unless wearing
some.

     Add missing amulet case to the silly_thing() handling for 'W' and
'T'.  Also handle boots, gloves, and lenses as plural in the message
there.  silly_thing() has been simplified a little bit in the process.
2003-05-26 17:34:28 +00:00
nethack.allison
253a9d388b win32gui: prevent male valkyrie (from <Someone>)
>Steps to reproduce problem:
>1) make sure you don't have race, role, gender specified in your
>   defaults.h, then add
>   OPTIONS=role:Valkyrie,race:Human,gender:male,align:lawful
>2) start a new nethackw.exe game
>3) Uncheck "Random" from gender box, now you can select from male
>   or female, not only female.
>4) Select male and click OK.
>5) When game begins press shift+O (Options) and look to gender.
>   Your valkyrie is male.

defaults.nh values were not used the dialog initialization. That's
why both male/female options were available for Valkyries. This is
now fixed.

Also added: checking for consistency of the initial settings and
resetting all incompatible values to ROLE_NONE.
2003-05-26 09:58:15 +00:00
cohrs
f61e3ceefe another grammar bit
My e-mail archive shows this was originally reported as one of several
items in R871.  Clean up a hit message when wielding cream pies.
2003-05-25 23:21:20 +00:00
nethack.allison
01120453f2 Fix B03001
"You can't loot or pick up containers on the floor if you're not
skilled enough to reach them from your saddle, but you can check
for and disarm traps on them; this seems a little odd. (Likewise,
being able to set land mines and beartraps while riding.)"
2003-05-25 22:47:12 +00:00
cohrs
1f712ac626 U303 - starting the game as a male valkyrie
A core fixup if the the port startup code sets an invalid flags.female when
starting a new game.  The old comment regarding being unable to change
flags.female was not completely correct.  The flags.pantheon can be used to
differenciate new games from a restored game.
2003-05-25 20:28:41 +00:00
cohrs
702c373619 untested FreeBSD compilation fix
this particular fix has been sitting around my inbox for a while although
we've had reports of FreeBSD build problems for a long time.  While it's
untested, it certainly looks like the unfixed system.h had a case that
could not be reached.  bsdi seems like it needs to be handled the same way.
2003-05-25 19:03:55 +00:00
cohrs
8fcb235336 golem statue vs stone-to-flesh
move the fixes entry for this from 35.0 to 34.2 since the fix got
inserted into the 3.4.2 source and is not detrimental to the branch.
2003-05-25 17:40:51 +00:00
cohrs
b115b536c1 B03005 - canceling monster redux
Revert the code, but add a comment. The behavior is not obvious to everyone.
2003-05-25 17:21:21 +00:00
cohrs
dde1a1ceec B03006 - Searching trapped chests
When attempting to disarm a trapped chest, wisdom should only be exercised
when not confused.  It stands to reason that even if you manage to find a
trap in a confused/hallucinating state, wisdom shouldn't be exercised.
2003-05-25 05:04:11 +00:00
cohrs
1d2b62de95 B03005 - Canceling monsters
Since monster cancellation sticks, it doesn't makes sense for Magicbane to
cancel a monster more than once.  Tweaked the messages to deal with this fact.
I decided to not make Magicbane's random effect "intelligent", which is what
changing it to use some other attack against a canceled monster would be.
2003-05-25 03:47:31 +00:00
cohrs
dce0e0cb33 use Is_box
While inspecting some code, I noticed that detect.c wasn't using Is_box in
some places it should have been.
2003-05-25 02:35:16 +00:00
nethack.rankin
9a39064b8f more perm_invent handling
Keep permanent inventory window up to date when using charged items.
Also a status line bit for the #tip command.
2003-05-24 04:07:14 +00:00
cohrs
aace75a34d B03004 - candelabrum in bones file
curse the candelabrum, like other similar artifacts
2003-05-24 01:59:11 +00:00
cohrs
4b22aa7bff sitting in lava and other utraptype sit messages
Several cases in the trap block of code in dosit() were caused by utraptype
being set to values not corresponding to an actual trap.  <Someone>
reported back in 12/02 that the "sitting in lava" killer message could not
occur, but the special-case sit messages for TT_INFLOOR and TT_BURIEDBALL
couldn't occur either.
2003-05-23 02:47:45 +00:00
cohrs
73fa09fac7 class genocide by species name
Incorporate a mod submitted by <Someone> to implement the TODO in the
class genocide code by walking thru the species to find a class to genocide
if the user input does not match the class description.
2003-05-23 02:47:42 +00:00
cohrs
82cef26512 sitting in lava and other utraptype sit messages
Several cases in the trap block of code in dosit() were caused by utraptype
being set to values not corresponding to an actual trap.  <Someone>
reported back in 12/02 that the "sitting in lava" killer message could not
occur, but the special-case sit messages for TT_INFLOOR and TT_BURIEDBALL
couldn't occur either.
2003-05-22 01:43:21 +00:00
cohrs
ac3746d055 B03003 - throwing short swords
<Someone> pointed out a disagreement between the comment and code in
throwing_weapon(): comment says daggers & knife can be thrown, but
code also allowed short swords.  Assuming the comment was correct, changed
the code to match.
2003-05-21 22:08:22 +00:00
cohrs
3862424fa7 choking on non-food
<Someone> (also later forwarded by <Someone>) reported that choking
while eating non-food always resulted in calling it a "quick snack".
lesshungry() depends on an occupation to tell if you are actually eatig or
not, but since non-food is eaten in one turn, no occupation was set.  Took
his suggestion of setting the occupation temporarily to cause lesshungry()
call choke() appropriately in this case.
2003-05-21 18:32:40 +00:00
cohrs
e6ed77f634 U464 - picking up items while swallowed in a shop
The bug report referred to greased hands, but that doesn't affect the
behavior.  If you drop an object while swallowed or engulfed in a shop, and
that object had previously been picked up from the shop floor, the object
was treated as costly.  In some cases, this could result in impossible
errors later on.  Perhaps object ox & oy should be modified when in
player/monster inventory, but this fix addresses the specific problem by
not doing the costly check while swallowed.
2003-05-21 17:12:47 +00:00
cohrs
bbaa40993b U472 - untrapping squeaky board with a can of grease
If using a permanent inventory window, the charges weren't updated immediately.
2003-05-21 15:15:27 +00:00
jwalz
902b4e67ef Insert static to match declaration. 2003-05-20 14:10:11 +00:00
nethack.allison
64618b9690 Borland bit 2003-05-20 10:23:52 +00:00
nethack.rankin
1b512c4a49 more "disclose" handling
Even though the in game help now lists the actual disclosure values
instead of "all" as the default value, implement support for "all" (also
for "none") since doing so is trivial.
2003-05-20 08:25:45 +00:00
nethack.rankin
459cee350e poisoning prefix
Fix a recent killer prefix fix....
2003-05-20 07:33:30 +00:00
nethack.rankin
29f3c6486e vms update
Bring a couple of vms-specific instances of nethack's version number
up to date.
2003-05-20 06:24:46 +00:00
nethack.rankin
cf4c262178 vms playground setup
Create an empty paniclog file during playground creation, so that it
starts with the same permissions as other writeable files.  Without this,
it's liable to end up being owned by the first random user who triggers
a panic or impossibility rather than by the playground owner and probably
wouldn't be writable by any other user.
2003-05-20 06:04:04 +00:00
nethack.rankin
b1a6120dce lev_comp parser update (U433) 2003-05-20 04:11:33 +00:00
cohrs
b13c70597d U468 - disclose default
clarify the "disclose" default value in opthelp
2003-05-20 03:39:02 +00:00
cohrs
b4ed1755fe more knight capitalization
Capitalize a bunch of "Us"s.  <Someone> comments that some other "We" and "Our"
actually referred to a group.  I disagree and left them alone.
2003-05-20 03:24:30 +00:00
cohrs
14c12765a0 U433 - infinite loop with place_branch
This solution is mostly a band-aid.  Make sure information set by join_map
that is overlaid by the MAP is cleared out.  This ensures that place_branch
will never consider invalid data.  A new function, remove_rooms(), with a
helper, remove_room(), takes care of this, but only for rooms created by
join_map, which addresses the only known case that causes this problem.
There's a possibility that some other strange behavior, especially in
minetn-6, will be fixed by this as well.  The problem of disconnected caves
on minetn-6 is not yet addressed.

Also, add a check to lev_comp.y to make sure the required fg semantics of
joined levels (fg must be ROOM or CORR) are actually met.  Doesn't affect
any levels currently included in the distro, but might address levels
others are trying to make.
2003-05-20 02:05:45 +00:00
cohrs
619da67425 B02005 - Boulder and vision followup
put back code to remove LAUNCH_UNSEEN from the mask that got lost
when I re-arranged the change.
2003-05-19 13:41:01 +00:00
cohrs
462858bd31 B02005 - Boulder and vision
add another bit to the flags passed to launch_obj so it can print
the initial "rumbling" message at the appropriate time rather than
having the caller print the message, possibly out of order.
2003-05-18 21:04:49 +00:00
nethack.allison
e827a395a1 MinGW and Borland Makefiles
Add build instructions for nhraykey (untested)
2003-05-18 18:53:13 +00:00
cohrs
252460c70a starvation killer message
Write "died of starvation" on the tombstone, not just "starvation".
Suggested by <Someone> a couple weeks ago, although his suggested
prefix was different and didn't work as well for the "exhaustion" case.
2003-05-17 22:03:27 +00:00
cohrs
07a3dabab1 more U429 - tile bits
> While looking at the tiles.bmp file, I've found some more mistakes like
> this : the Wizard of Yendor's shadow is touching Croesus' tile, and one
> of Orcus' wing is touching Yeenoghu's tile.
2003-05-17 21:46:45 +00:00
cohrs
15ad161345 more grammar bits
Reported to the list a while back by <Someone>.  The Knight's quest
messages are inconsistent in the use of royal pronouns.  Capitalize them all.
Another option would have been to remove all royal capitalization (since such
Capitalization didn't come into use until relatively recently).
2003-05-17 21:35:21 +00:00
cohrs
775e4e0345 U442 - scroll of charging
<Someone> suggested a scroll to counteract an unknown scroll of charging
that had negative effects.  Scroll of punishment already costs the same,
so that unknown behavior is already covered.  Plus, a cursed scroll of
charging already has negative effects, except in the case where the player
was confused where no negative effect from reading a cursed scroll of
charging occured.  Added such an effect (since the curse should still cause
something bad, even though the reader is confused), to drain the player's
energy.
2003-05-17 21:12:16 +00:00
cohrs
ddb2f60171 message when eating a stalking
As suggested by <Someone> to the mailing list, display a message
when you eat a stalker and notice that you became invisible.
2003-05-17 20:51:11 +00:00
cohrs
b8e3cc2b77 another README.linux update
Make the instructions a bit more blow-by-blow.  Re-order them so they
correspond to the Install.unx step numbers.  Explicitly refer to
Install.unx and Install.X11 where appropriate.
2003-05-17 20:35:07 +00:00
nethack.allison
c6e4d7ac75 win32tty: The author field should not be left as devteam 2003-05-14 10:56:54 +00:00
nethack.rankin
c4c1b064f7 fix B02004 and other projectile related killer reasons
1) killer reason for scattered land mine shrapnel used "a" or "an" prefix
   even when multiple projectiles hit as a group -- one of various things
   From a bug report.oextra field) --
   noticed while investigating #1 and later From a bug report.4.0 due to an unintentional side-effect of missile killer reason
   handling in 3.4.1 (removal of redundant "poisoned" prefix by m_throw()
   confused the poison handling routine) -- noticed while investigating #3.
2003-05-14 10:25:26 +00:00
nethack.allison
835c0ca499 Field is conditionally defined, code referring to it isn't 2003-05-12 04:49:20 +00:00
nethack.allison
792b684dcc Add <Someone> to dungeoneers list
Proposed by Michael Allison.
Seconded by Pat Rankin.
(it can always be withdrawn if there is a later objection)

-Author of Spanish NetHack
-Author of some NT keyboard internationalization fixes
-Author of "Hell patch"
2003-05-12 03:05:00 +00:00
nethack.allison
a2249a4b0d Some altkeyhandler tweaking 2003-05-12 02:25:08 +00:00